1 /* PR rtl-optimization/9771 */
3 /* { dg-require-effective-target ia32 } */
4 /* { dg-options "-O2 -fomit-frame-pointer -ffixed-ebp" } */
6 extern void abort(void);
9 register long *B
asm ("ebp");
31 /* This must not be inlined because main() requires the frame pointer
32 for stack alignment. */
33 void test(void) __attribute__((noinline
));
40 if (x
!= 10 || y
!= 20)
43 /* We can't return, as our caller may assume %ebp is preserved! */
44 /* We could save/restore it (like foo), but its easier to exit. */
48 /* main usually performs dynamic realignment of the stack in case
49 _start would fail to properly align the stack, but for dynamic
50 stack realignment we need frame pointer which is incompatible
51 with -ffixed-ebp and the global register var. So, cheat here
52 and hide from the compiler that main is really main. */
53 #define ASMNAME(cname) ASMNAME2 (__USER_LABEL_PREFIX__, cname)
54 #define ASMNAME2(prefix, cname) STRING (prefix) cname
56 int real_main() __asm (ASMNAME ("main"));