From be7628ca507fe36b49c5a82b39db68b98c2ba1b4 Mon Sep 17 00:00:00 2001 From: Mikael Pettersson Date: Wed, 16 Sep 2020 16:20:51 +0100 Subject: [PATCH] Add -Av9 to AFLAGS_PIC and AFLAGS_PIE in the ld test suite on SPARC. * testsuite/ld-elf/shared.exp: Add -Av9 to AFLAGS_PIE on sparc. * testsuite/ld-elf/tls.exp: Add -Av9 to AFLAGS_PIC on sparc. --- ld/ChangeLog | 5 +++++ ld/testsuite/ld-elf/shared.exp | 3 +++ ld/testsuite/ld-elf/tls.exp | 2 +- 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/ld/ChangeLog b/ld/ChangeLog index 81ad2a5ed2c..cffb271598d 100644 --- a/ld/ChangeLog +++ b/ld/ChangeLog @@ -1,3 +1,8 @@ +2020-09-16 Mikael Pettersson + + * testsuite/ld-elf/shared.exp: Add -Av9 to AFLAGS_PIE on sparc. + * testsuite/ld-elf/tls.exp: Add -Av9 to AFLAGS_PIC on sparc. + 2020-09-16 H.J. Lu PR ld/26583 diff --git a/ld/testsuite/ld-elf/shared.exp b/ld/testsuite/ld-elf/shared.exp index bc68bb8435c..7b1f8985f61 100644 --- a/ld/testsuite/ld-elf/shared.exp +++ b/ld/testsuite/ld-elf/shared.exp @@ -1610,6 +1610,9 @@ if { [istarget "i?86-*-*"] || [istarget "x86_64-*-*"] } { set AFLAGS_PIE "-mrelax-relocations=yes" } +if [istarget "sparc*-*-*"] { + set AFLAGS_PIE "-Av9" +} if { ([istarget "*-*-linux*"] || [istarget "*-*-nacl*"] diff --git a/ld/testsuite/ld-elf/tls.exp b/ld/testsuite/ld-elf/tls.exp index 45d2a84b8b7..c876f654859 100644 --- a/ld/testsuite/ld-elf/tls.exp +++ b/ld/testsuite/ld-elf/tls.exp @@ -36,7 +36,7 @@ if { ![check_compiler_available] } { # This target requires extra GAS options when building PIC/PIE code. set AFLAGS_PIC "" if [istarget "sparc*-*-*"] { - append AFLAGS_PIC " -K PIC" + append AFLAGS_PIC " -K PIC -Av9" } run_ld_link_tests [list \ -- 2.30.2