|
6 | 6 |
|
7 | 7 | // CHECK-64: {{.*}} call { i32, i32, i32, i32 } asm " xchgq %rbx,${1:q}\0A cpuid\0A xchgq %rbx,${1:q}", "={ax},=r,={cx},={dx},0,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}})
|
8 | 8 | // CHECK-64: {{.*}} call { i32, i32, i32, i32 } asm " xchgq %rbx,${1:q}\0A cpuid\0A xchgq %rbx,${1:q}", "={ax},=r,={cx},={dx},0,2,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}}, i32 %{{[a-z0-9]+}})
|
| 9 | +// CHECK-64: {{.*}} call { i32, i32, i32, i32 } asm " xchgq %rbx,${1:q}\0A cpuid\0A xchgq %rbx,${1:q}", "={ax},=r,={cx},={dx},0,2,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}}, i32 %{{[a-z0-9]+}}) |
9 | 10 |
|
10 | 11 | // CHECK-32: {{.*}} call { i32, i32, i32, i32 } asm "cpuid", "={ax},={bx},={cx},={dx},0,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}})
|
11 | 12 | // CHECK-32: {{.*}} call { i32, i32, i32, i32 } asm "cpuid", "={ax},={bx},={cx},={dx},0,2,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}}, i32 %{{[a-z0-9]+}})
|
| 13 | +// CHECK-32: {{.*}} call { i32, i32, i32, i32 } asm "cpuid", "={ax},={bx},={cx},={dx},0,2,~{dirflag},~{fpsr},~{flags}"(i32 %{{[a-z0-9]+}}, i32 %{{[a-z0-9]+}}) |
12 | 14 |
|
13 | 15 | unsigned eax0, ebx0, ecx0, edx0;
|
14 | 16 | unsigned eax1, ebx1, ecx1, edx1;
|
15 | 17 |
|
| 18 | +int cpuid_info[4]; |
| 19 | + |
16 | 20 | void test_cpuid(unsigned level, unsigned count) {
|
17 | 21 | __cpuid(level, eax1, ebx1, ecx1, edx1);
|
18 | 22 | __cpuid_count(level, count, eax0, ebx0, ecx0, edx0);
|
| 23 | + __cpuidex(cpuid_info, level, count); |
19 | 24 | }
|
0 commit comments