2018-05-17 Richard Biener <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / pr67609-2.c
blob7d3fcba3be7faaedf6c12b68619bbcdff66eb84c
1 /* { dg-do run } */
2 /* { dg-options "-O2 -msse2" } */
3 /* { dg-require-effective-target sse2 } */
5 #include "sse2-check.h"
7 #include <emmintrin.h>
9 __m128d reg = { 2.0, 4.0 };
11 void
12 __attribute__((noinline))
13 set_lower (double b)
15 double v[2];
16 _mm_store_pd(v, reg);
17 v[0] = b;
18 reg = _mm_load_pd(v);
21 static void
22 sse2_test (void)
24 set_lower (6.0);
26 if (reg[1] != 4.0)
27 __builtin_abort ();