PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / pr46716.c
blob29c5e1e4920f1c4e97a084d2f751972637553a0c
1 /* { dg-do run } */
2 /* { dg-options "-O2 -msse -mno-sse2" } */
3 /* { dg-require-effective-target sse } */
5 #include "sse-check.h"
7 typedef double V __attribute__ ((__vector_size__ (16), __may_alias__));
8 typedef union
10 V x;
11 double a[2];
12 } u;
14 #define EMM_FLT8(a) ((double *)&(a))
16 void __attribute__ ((noinline))
17 test (V s1, V s2)
19 if (EMM_FLT8(s1)[0] != EMM_FLT8(s2)[0]
20 || EMM_FLT8(s1)[1] != EMM_FLT8(s2)[1])
21 abort ();
24 static void
25 sse_test (void)
27 u s1;
29 s1.a[0] = 1.0;
30 s1.a[1] = 2.0;
32 test (s1.x, s1.x);