2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / g++.dg / eh / omit-frame-pointer2.C
blob9ddf2edfbc769ef54da0cfd8e127b616e9ffbc58
1 // Reduced from PR c++/5246, PR c++/2447
2 // { dg-options "-O -fomit-frame-pointer" }
3 // { dg-options "-O -fomit-frame-pointer -mno-accumulate-outgoing-args" { target i?86-*-* } }
4 // { dg-do run }
6 void step (int)
8   void *sp = __builtin_alloca (0);
11 void f2 (void)
13   step (2);
14   throw int();
17 void f1 (void)
19   try
20     {
21       step (1);
22       f2 ();
23       step (-1);
24     }
25   catch (int)
26     {
27       step (3);
28     }
31 int main ()
33   f1 ();
34   return 0;