arm: avoid conditional branch to PLT in sigsetjmp
authorAndre McCurdy <armccurdy@gmail.com>
Wed, 18 Sep 2019 06:04:05 +0000 (23:04 -0700)
committerRich Felker <dalias@aerifal.cx>
Sat, 7 Dec 2019 18:02:05 +0000 (13:02 -0500)
The R_ARM_THM_JUMP19 relocation type generated for the original code
when targeting Thumb 2 is not supported by the gold linker.

src/signal/arm/sigsetjmp.s

index 318addba0a12c29760a371c2253e15f275a2ba0b..69ebbf4993fda165c027768ca08db23454320b08 100644 (file)
@@ -6,9 +6,10 @@
 sigsetjmp:
 __sigsetjmp:
        tst r1,r1
-       beq setjmp
+       bne 1f
+       b setjmp
 
-       str lr,[r0,#256]
+1:     str lr,[r0,#256]
        str r4,[r0,#260+8]
        mov r4,r0