middle-end: Fix ifcvt predicate generation for masked function calls
[official-gcc.git] / gcc / testsuite / g++.dg / torture / pr43784.C
bloba83a6f374d77cbcc0a05ea8004712d76b3d320e7
1 /* { dg-do run } */
2 /* { dg-options "-fno-tree-sra" } */
4 struct S {int x, y, makemelarge[5];};
5 S __attribute__((noinline)) f (S &s) {
6     S r;
7     r.x = s.y;
8     r.y = s.x;
9     return r;
11 int __attribute__((noinline)) glob (int a, int b)
13   S local = { a, b };
14   local = f (local);
15   return local.y;
17 extern "C" void abort (void);
18 int main (void)
20   if (glob (1, 3) != 1)
21     abort ();
22   return 0;