The switch to default of no-common means that we no longer indirect the accesses to 'xxx' in this test. Adjust the scan- assembler tests to reflect this.
tested on x86_64-darwin16, x86_64-linux-gnu applied to mainline, thanks Iain gcc/testsuite/ChangeLog: 2019-11-28 Iain Sandoe <i...@sandoe.co.uk> * gcc.target/i386/pr32219-2.c: Adjust scan-assembler entries for revised common default. diff --git a/gcc/testsuite/gcc.target/i386/pr32219-2.c b/gcc/testsuite/gcc.target/i386/pr32219-2.c index b6212f7..a9c18ba 100644 --- a/gcc/testsuite/gcc.target/i386/pr32219-2.c +++ b/gcc/testsuite/gcc.target/i386/pr32219-2.c @@ -12,13 +12,12 @@ foo () } /* { dg-final { scan-assembler-not "movl\[ \t\]xxx\\(%rip\\), %" { target { ! ia32 } } } } */ -/* For Darwin m64 we are always PIC, but common symbols are indirected, which happens to - match the general "ELF" case. */ -/* { dg-final { scan-assembler "xxx@GOTPCREL" { target { ! ia32 } } } } */ +/* For Darwin m64 PIC we make a direct access to this symbol. */ +/* { dg-final { scan-assembler "xxx@GOTPCREL" { target { { ! ia32 } && { ! *-*-darwin* } } } } } */ /* { dg-final { scan-assembler-not "movl\[ \t\]xxx@GOTOFF\\(%\[^,\]*\\), %" { target { ia32 && { ! *-*-darwin* } } } } } */ /* { dg-final { scan-assembler "movl\[ \t\]xxx@GOT\\(%\[^,\]*\\), %" { target { ia32 && { ! *-*-darwin* } } } } } */ -/* Darwin m32 defaults to PIC but common symbols need to be indirected. */ -/* { dg-final { scan-assembler {movl[ \t][Ll]_xxx\$non_lazy_ptr-L1\$pb\(%eax\),[ \t]%eax} { target { ia32 && *-*-darwin* } } } } */ +/* Darwin m32 PIC requires the picbase adjustment. */ +/* { dg-final { scan-assembler {movl[ \t]_xxx-L1\$pb\(%eax\),[ \t]%eax} { target { ia32 && *-*-darwin* } } } } */