aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.target/i386/pr48335-1.c
blob: 08c5284ea80ddb4e90927d499b1d433cf34c0b3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
/* PR middle-end/48335 */
/* { dg-do compile } */
/* { dg-options "-O2 -fno-tree-sra -msse2" } */

#include <emmintrin.h>

typedef __float128 T __attribute__((may_alias));

struct S
{
  _Complex double d __attribute__((aligned (16)));
};

void bar (struct S);

void
f1 (T x)
{
  struct S s;
  *(T *) &s.d = x;
  __real__ s.d *= 7.0;
  bar (s);
}

void
f2 (__m128d x)
{
  struct S s;
  _mm_store_pd ((double *) &s.d, x);
  __real__ s.d *= 7.0;
  bar (s);
}