| .section ".tdata", "awT", @progbits |
| /* Main binary, no PIC. */ |
| addl $_GLOBAL_OFFSET_TABLE_+[.-1b], %edx |
| /* foo can be anywhere in startup TLS. */ |
| subl foo@GOTTPOFF(%edx), %eax |
| /* %eax now contains &foo. */ |
| /* bar only in the main program. */ |
| /* %eax now contains &bar. */ |
| /* baz only in the main program. */ |
| /* Arbitrary instructions in between. */ |
| /* %ecx now contains &baz. */ |
| /* var and var2 only in the main program. */ |
| /* Arbitrary instructions in between. */ |
| leal var@NTPOFF(%ecx), %eax |
| /* Arbitrary instructions in between. */ |
| leal var2@NTPOFF(%ecx), %edx |
| /* foo can be anywhere in startup TLS. */ |
| /* %eax now contains foo. */ |
| /* %eax now contains &foo. */ |