1 /* Check that PLT is used to access glob_a. */ 2 /* { dg-do compile { target *-*-linux* } } */ 3 /* { dg-require-effective-target pie_copyreloc } */ 4 /* { dg-options "-O2 -fpie" } */ 5 6 extern int glob_a (void); 7 foo()8int foo () 9 { 10 return glob_a (); 11 } 12 13 /* glob_a should be accessed with a PLT. */ 14 /* { dg-final { scan-assembler "glob_a@PLT" { target { ! ia32 } } } } */ 15