OSDN Git Service

PR c++/34774
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / g++.dg / opt / life1.C
1 // This testcase did not set up the pic register on IA-32 due
2 // to bug in calculate_global_regs_live EH edge handling.
3 // { dg-do compile { target i?86-*-linux* x86_64-*-linux* } }
4 // { dg-require-effective-target ilp32 }
5 // { dg-require-effective-target fpic }
6 // { dg-options "-O2 -fPIC" }
7
8 struct A { };
9
10 void foo (A (*fn)())
11 {
12   try {
13     A a = fn ();
14   } catch (...) {
15   }
16 }
17
18 // { dg-final { scan-assembler "GLOBAL_OFFSET_TABLE" } }