repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
[AArch64/arm] PR testsuite/85326 Avoid C++ tests when C++ compiler not present
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.target
/
i386
/
rtm-check.h
blob
bdb5a6dc0bf74cc76c163fd83575e19ed0b19aa9
1
#include <stdlib.h>
2
#include
"cpuid.h"
3
4
static void
rtm_test
(
void
);
5
6
static void
__attribute__
((
noinline
))
do_test
(
void
)
7
{
8
rtm_test
();
9
}
10
11
int
12
main
()
13
{
14
unsigned int
eax
,
ebx
,
ecx
,
edx
;
15
16
if
(!
__get_cpuid_count
(
7
,
0
, &
eax
, &
ebx
, &
ecx
, &
edx
))
17
return
0
;
18
19
/* Run RTM test only if host has RTM support. */
20
if
(
ebx
&
bit_RTM
)
21
{
22
do_test
();
23
#ifdef DEBUG
24
printf
(
"PASSED
\n
"
);
25
#endif
26
return
0
;
27
}
28
29
#ifdef DEBUG
30
printf
(
"SKIPPED
\n
"
);
31
#endif
32
return
0
;
33
}