2015-12-10 Vladimir Makarov <vmakarov@redhat.com>
[official-gcc.git] / gcc / testsuite / gcc.target / i386 / pr25196.c
blob6ebdee1748a94bffc3598d10f3ef58093df49f4d
1 /* { dg-do run } */
2 /* { dg-require-effective-target ia32 } */
3 /* { dg-options "-march=i386 -O3 -fomit-frame-pointer" } */
5 /* For this test case, we used to do an invalid load motion after
6 reload, because we missed autoincrements of the stack pointer. */
8 extern void abort (void);
10 static int j;
12 static void __attribute__((noinline))
13 f1 (int a, int b, int c, int d, int e)
15 j = a;
18 int __attribute__((noinline))
19 f2 (int a, int b, int c, int d, int e)
21 if ((b & 0x1111) != 1)
22 f1 (a, b, c, d, e);
23 return 0;
26 int
27 main (void)
29 f2 (123, 0, 0, 0, 0);
30 if (j != 123)
31 abort ();
32 return 0;