summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg/pr90756.c
blob: 3507aa29e70b1114c3929258d54f3f6f6663dc42 (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
/* PR rtl-optimization/90756 */
/* { dg-do compile } */
/* { dg-options "-O2 -Wno-psabi" } */
/* { dg-additional-options "-mno-sse" { target ia32 } } */

typedef float B __attribute__((vector_size(4 * sizeof (float))));
typedef unsigned long long C __attribute__((vector_size(4 * sizeof (long long))));
typedef short D __attribute__((vector_size(4 * sizeof (short))));
B z;
void foo (C);
C bar (D);
B baz ();
D qux (B);

void
quux (int x)
{
  B n = z, b = z;
  while (1)
    switch (x)
      {
      case 0: n = baz (); /* FALLTHRU */
      case 1: { B o = n; n = b; b = o; } /* FALLTHRU */
      case 2: { D u = qux (b); C v = bar (u); foo (v); }
      }
}