86038de0d8
These all were odd in that they used r13 as the GOT pointer. That didn't matter for the purpose of testing, but would never occur in practice. Also, the tlsopt5 tests could have their global dynamic sequences optimized to initial exec, so link with -shared. * testsuite/ld-powerpc/powerpc.exp: Add -shared to tlsop5 tests. * testsuite/ld-powerpc/tlsopt5.d: Adjust. * testsuite/ld-powerpc/tlsopt1_32.s: Use r30 as GOT pointer. * testsuite/ld-powerpc/tlsopt2_32.s: Likewise. * testsuite/ld-powerpc/tlsopt3_32.s: Likewise. * testsuite/ld-powerpc/tlsopt4_32.s: Likewise. * testsuite/ld-powerpc/tlsopt5_32.s: Rewrite. * testsuite/ld-powerpc/tlsopt1_32.d: Adjust. * testsuite/ld-powerpc/tlsopt2_32.d: Adjust. * testsuite/ld-powerpc/tlsopt3_32.d: Adjust. * testsuite/ld-powerpc/tlsopt5_32.d: Adjust.
19 lines
292 B
ArmAsm
19 lines
292 B
ArmAsm
.globl _start
|
|
_start:
|
|
stwu 1,-16(1)
|
|
mflr 0
|
|
bcl 20,31,.L2
|
|
.L2:
|
|
stw 30,8(1)
|
|
mflr 30
|
|
addis 30,30,_GLOBAL_OFFSET_TABLE_-.L2@ha
|
|
stw 0,20(1)
|
|
addi 30,30,_GLOBAL_OFFSET_TABLE_-.L2@l
|
|
addi 3,30,gd@got@tlsgd
|
|
bl __tls_get_addr(gd@tlsgd)@plt
|
|
lwz 0,20(1)
|
|
lwz 30,8(1)
|
|
mtlr 0
|
|
addi 1,1,16
|
|
blr
|