blob: 533f1d2ddb4f9cf7beb31101f0d6db44696154ae [file] [log] [blame]
/* { dg-do compile { target *-*-linux* } } */
/* { dg-options "-O2 -fpic -mno-direct-extern-access" } */
/* Common symbol with -fpic. */
__attribute__((visibility("protected")))
int xxx;
int
foo ()
{
return xxx;
}
/* { dg-final { scan-assembler "xxx\\(%rip\\)" { target { ! ia32 } } } } */
/* { dg-final { scan-assembler-not "xxx@GOTPCREL" { target { ! ia32 } } } } */
/* { dg-final { scan-assembler "xxx@GOTOFF" { target ia32 } } } */
/* { dg-final { scan-assembler-not "xxx@GOT\\(" { target ia32 } } } */
/* { dg-final { scan-assembler "\.section\[ \t]+.note.gnu.property," } } */
/* { dg-final { scan-assembler "\.long\[ \t]+0xb0008000" } } */