1 .text 2 .global __tls_get_addr 3 .align 2 4 .global foo 5 .type foo, @function 6foo: 7 push lr, gb 8 lrw t1, .L2@GOTPC 9 grs gb, .L2 10.L2: 11 addu gb, gb, t1 12 grs a2, .LTLS0 13 lrw a3, __tls_get_addr@PLT 14.LTLS0: 15 lrw a0, var@TLSGD32 16 ldr.w a3, (gb, a3 << 0) 17 addu a0, a0, a2 18 jsr a3 19 ld.w a0, (a0, 0) 20 pop lr, gb 21