diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.target/i386/intrinsics_3.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gcc.target/i386/intrinsics_3.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.target/i386/intrinsics_3.c b/gcc-4.9/gcc/testsuite/gcc.target/i386/intrinsics_3.c new file mode 100644 index 000000000..e5ea8a967 --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gcc.target/i386/intrinsics_3.c @@ -0,0 +1,15 @@ +/* Test case to check if intrinsics and function specific target + optimizations work together. Check if the POPCNT specific intrinsics + in included with popcntintrin.h get enabled by directly including + popcntintrin.h */ + +/* { dg-do compile } */ +/* { dg-options "-O2 -msse -mno-sse4.1 -mno-sse4.2 -mno-popcnt" } */ + +#include <popcntintrin.h> + +__attribute__((target("popcnt"))) +long long foo(unsigned long long X) +{ + return _mm_popcnt_u64 (X); +} |