| 1 |
// https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110406 |
| 2 |
// { dg-do compile { target i?86-*-* x86_64-*-* } } |
| 3 |
// { dg-options "-fno-moduleinfo -fdump-tree-optimized" } |
| 4 |
struct cpuid_abcd_t |
| 5 |
{ |
| 6 |
uint eax; |
| 7 |
uint ebx; |
| 8 |
uint ecx; |
| 9 |
uint edx; |
| 10 |
}; |
| 11 |
|
| 12 |
cpuid_abcd_t cpuid_insn(const uint in_eax) |
| 13 |
{ |
| 14 |
cpuid_abcd_t ret = void; |
| 15 |
asm { "cpuid" |
| 16 |
: "=a" (ret.eax), |
| 17 |
"=b" (ret.ebx), |
| 18 |
"=c" (ret.ecx), |
| 19 |
"=d" (ret.edx) |
| 20 |
: "a" (in_eax) |
| 21 |
:; |
| 22 |
} |
| 23 |
return ret; |
| 24 |
} |
| 25 |
// { dg-final { scan-tree-dump-not "MEM <vector\\(4\\) uint>" "optimized" } } |