gcc/testsuite/gcc.target/i386/pconfig-1.c
raw| 1 | /* { dg-do compile } */ |
| 2 | /* { dg-options "-O2 -mpconfig" } */ |
| 3 | /* { dg-final { scan-assembler-times {\tpconfig} 2 } } */ |
| 4 | |
| 5 | #include <x86intrin.h> |
| 6 | |
| 7 | extern unsigned int leaf; |
| 8 | |
| 9 | #define PCONFIG_KEY_PROGRAM 0x01 |
| 10 | |
| 11 | int test () |
| 12 | { |
| 13 | size_t D[3] = {1, 2, 3}; |
| 14 | |
| 15 | unsigned int res1 = _pconfig_u32 (leaf, D); |
| 16 | |
| 17 | unsigned int res2 = _pconfig_u32 (PCONFIG_KEY_PROGRAM, D); |
| 18 | |
| 19 | return 0; |
| 20 | } |