elf: Don't use .set for alpha target
authorH.J. Lu <hjl.tools@gmail.com>
Sat, 18 Apr 2020 18:23:09 +0000 (11:23 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Sat, 18 Apr 2020 18:23:09 +0000 (11:23 -0700)
Since the .set directive of ELF/alpha target is different, define NO_SET
to 1 to use "=" for ELF/alpha target.

* testsuite/ld-elf/elf.exp (ASFLAGS): Add "--defsym NO_SET=1" for
alpha target.
* testsuite/ld-elf/pr19789.s: Use "=" if NO_SET is defined.

ld/ChangeLog
ld/testsuite/ld-elf/elf.exp
ld/testsuite/ld-elf/pr19789.s

index 5b5ba5229d1d3a0e76c6043a6f46b0014bcf0804..a87cb77cdc09455c132e26e33cbe2290723e2c33 100644 (file)
@@ -1,3 +1,9 @@
+2020-04-18  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * testsuite/ld-elf/elf.exp (ASFLAGS): Add "--defsym NO_SET=1" for
+       alpha target.
+       * testsuite/ld-elf/pr19789.s: Use "=" if NO_SET is defined.
+
 2020-04-16  Stephen Casner  <casner@acm.org>
 
        PR 18963
index 7b8e8f6f3cfa7a52c0fbe898ec464893a8def9c1..096b8af4f99a0fec7a50f31b0b32b3de072aab68 100644 (file)
@@ -43,6 +43,7 @@ if { [istarget alpha*-*-* ] } {
     # executable down into the low address space to match.
     # ??? How can we adjust just the one testcase?
     set LDFLAGS "$LDFLAGS -Ttext-segment 0x1000000"
+    set ASFLAGS "$ASFLAGS --defsym NO_SET=1"
 }
 
 if { [istarget "*-*-nacl*"] } {
index 31be1b04579c61112f08111bd54e76209253bef8..3655d08f74d08207e336f731cce3424dbcde98e8 100644 (file)
@@ -4,6 +4,10 @@
 __foo:
        .byte 0
        .globl  __foo1
+       .ifdef NO_SET
+       __foo1 = __foo
+       .else
        .set __foo1, __foo
+       .endif
        .symver __foo,foo@@VERS.2
        .symver __foo1,foo@VERS.1
This page took 0.025816 seconds and 4 git commands to generate.