aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.apple/i386-ssetype-6.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.apple/i386-ssetype-6.c')
-rw-r--r--gcc/testsuite/gcc.apple/i386-ssetype-6.c24
1 files changed, 24 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.apple/i386-ssetype-6.c b/gcc/testsuite/gcc.apple/i386-ssetype-6.c
new file mode 100644
index 00000000000..ed517d648bf
--- /dev/null
+++ b/gcc/testsuite/gcc.apple/i386-ssetype-6.c
@@ -0,0 +1,24 @@
+/* APPLE LOCAL file 4099020 */
+/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O2 -msse2 -march=pentium4" } */
+/* { dg-final { scan-assembler-times "movq\[^\\n\]*" 3} } */
+
+/* Verify that we generate proper instruction with memory operand. */
+
+#include <emmintrin.h>
+
+__m128i
+t1(__m128i *p)
+{
+ return _mm_loadl_epi64(p); /* 64-bit, zero-extended result in %xmm. */
+}
+void
+t2(__m128i *p, __m128i a)
+{
+ _mm_storel_epi64(p, a); /* 64-bit store from %xmm. */
+}
+__m128i
+t3(__m128i a)
+{
+ return _mm_move_epi64(a); /* 64-bit move between %xmm registers. */
+}