1 |
38 |
julius |
#source: tlsbinpic_64.s
|
2 |
|
|
#source: tlsbin_64.s
|
3 |
|
|
#as: -m64 -Aesame
|
4 |
|
|
#ld: -shared -melf64_s390
|
5 |
|
|
#objdump: -dzrj.text
|
6 |
|
|
#target: s390x-*-*
|
7 |
|
|
|
8 |
|
|
# PT_TLS layout is:
|
9 |
|
|
# Offset from Offset from Name
|
10 |
|
|
# TCB base TCB end
|
11 |
|
|
# 0x00 -0xa0 sg1..sg2
|
12 |
|
|
# 0x20 -0x80 sl1..sl2
|
13 |
|
|
# 0x40 -0x60 sh1..sh2
|
14 |
|
|
# 0x60 -0x40 bg1..bg2
|
15 |
|
|
# 0x80 -0x20 bl1..bl2
|
16 |
|
|
|
17 |
|
|
.*: +file format elf64-s390
|
18 |
|
|
|
19 |
|
|
Disassembly of section .text:
|
20 |
|
|
|
21 |
|
|
0+[0-9a-f]+ :
|
22 |
|
|
# function prolog
|
23 |
|
|
+[0-9a-f]+: eb 6e f0 30 00 24 stmg %r6,%r14,48\(%r15\)
|
24 |
|
|
+[0-9a-f]+: a7 d5 00 3e bras %r13,[0-9a-f]+
|
25 |
|
|
# sG1@tlsgd
|
26 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
27 |
|
|
+[0-9a-f]+: 00 00 00 60 .long 0x00000060
|
28 |
|
|
# sG2@tlsgd
|
29 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
30 |
|
|
+[0-9a-f]+: 00 00 00 48 .long 0x00000048
|
31 |
|
|
# sg1@tlsgd
|
32 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
33 |
|
|
+[0-9a-f]+: ff ff ff 60 .long 0xffffff60
|
34 |
|
|
# sl1@tlsgd
|
35 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
36 |
|
|
+[0-9a-f]+: ff ff ff 80 .long 0xffffff80
|
37 |
|
|
# sh1@tlsgd
|
38 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
39 |
|
|
+[0-9a-f]+: ff ff ff a0 .long 0xffffffa0
|
40 |
|
|
# sl1@tlsldm
|
41 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
42 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
43 |
|
|
# sl1@dtpoff
|
44 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
45 |
|
|
+[0-9a-f]+: ff ff ff 80 .long 0xffffff80
|
46 |
|
|
# sl2@dtpoff
|
47 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
48 |
|
|
+[0-9a-f]+: ff ff ff 84 .long 0xffffff84
|
49 |
|
|
# sh1@tlsldm
|
50 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
51 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
52 |
|
|
# sh1@dtpoff
|
53 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
54 |
|
|
+[0-9a-f]+: ff ff ff a0 .long 0xffffffa0
|
55 |
|
|
# sh2@dtpoff
|
56 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
57 |
|
|
+[0-9a-f]+: ff ff ff a4 .long 0xffffffa4
|
58 |
|
|
# sG2@gotntpoff
|
59 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
60 |
|
|
+[0-9a-f]+: 00 00 00 48 .long 0x00000048
|
61 |
|
|
# sg1@gotntpoff
|
62 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
63 |
|
|
+[0-9a-f]+: ff ff ff 60 .long 0xffffff60
|
64 |
|
|
# sl1@gotntpoff
|
65 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
66 |
|
|
+[0-9a-f]+: ff ff ff 80 .long 0xffffff80
|
67 |
|
|
# sh1@gotntpoff
|
68 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
69 |
|
|
+[0-9a-f]+: ff ff ff a0 .long 0xffffffa0
|
70 |
|
|
# function prolog
|
71 |
|
|
+[0-9a-f]+: b9 04 00 ef lgr %r14,%r15
|
72 |
|
|
+[0-9a-f]+: a7 fb ff 60 aghi %r15,-160
|
73 |
|
|
+[0-9a-f]+: c0 c0 [0-9a-f ]+ larl %r12,[0-9a-f]+ <_GLOBAL_OFFSET_TABLE_>
|
74 |
|
|
+[0-9a-f]+: e3 e0 e0 00 00 24 stg %r14,0\(%r14\)
|
75 |
|
|
# extract TCB
|
76 |
|
|
+[0-9a-f]+: b2 4f 00 90 ear %r9,%a0
|
77 |
|
|
+[0-9a-f]+: eb 94 00 20 00 0d sllg %r9,%r4,32
|
78 |
|
|
+[0-9a-f]+: b2 4f 00 91 ear %r9,%a1
|
79 |
|
|
# GD -> IE because variable is not defined in executable
|
80 |
|
|
+[0-9a-f]+: e3 c0 d0 00 00 04 lg %r12,0\(%r13\)
|
81 |
|
|
+[0-9a-f]+: e3 22 c0 00 00 04 lg %r2,0\(%r2,%r12\)
|
82 |
|
|
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
83 |
|
|
# GD -> IE because variable is not defined in executable where
|
84 |
|
|
# the variable is referenced through IE too
|
85 |
|
|
+[0-9a-f]+: e3 20 d0 08 00 04 lg %r2,8\(%r13\)
|
86 |
|
|
+[0-9a-f]+: e3 22 c0 00 00 04 lg %r2,0\(%r2,%r12\)
|
87 |
|
|
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
88 |
|
|
# GD -> LE with global variable defined in executable
|
89 |
|
|
+[0-9a-f]+: e3 20 d0 10 00 04 lg %r2,16\(%r13\)
|
90 |
|
|
+[0-9a-f]+: c0 04 00 00 00 00 brcl 0,[0-9a-f]+
|
91 |
|
|
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
92 |
|
|
# GD -> LE with local variable defined in executable
|
93 |
|
|
+[0-9a-f]+: e3 20 d0 18 00 04 lg %r2,24\(%r13\)
|
94 |
|
|
+[0-9a-f]+: c0 04 00 00 00 00 brcl 0,[0-9a-f]+
|
95 |
|
|
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
96 |
|
|
# GD -> LE with hidden variable defined in executable
|
97 |
|
|
+[0-9a-f]+: e3 20 d0 20 00 04 lg %r2,32\(%r13\)
|
98 |
|
|
+[0-9a-f]+: c0 04 00 00 00 00 brcl 0,[0-9a-f]+
|
99 |
|
|
+[0-9a-f]+: 41 22 90 00 la %r2,0\(%r2,%r9\)
|
100 |
|
|
# LD -> LE
|
101 |
|
|
+[0-9a-f]+: e3 20 d0 28 00 04 lg %r2,40\(%r13\)
|
102 |
|
|
+[0-9a-f]+: c0 04 00 00 00 00 brcl 0,[0-9a-f]+
|
103 |
|
|
+[0-9a-f]+: 41 32 90 00 la %r3,0\(%r2,%r9\)
|
104 |
|
|
+[0-9a-f]+: e3 40 d0 30 00 04 lg %r4,48\(%r13\)
|
105 |
|
|
+[0-9a-f]+: 41 54 30 00 la %r5,0\(%r4,%r3\)
|
106 |
|
|
+[0-9a-f]+: e3 40 d0 38 00 04 lg %r4,56\(%r13\)
|
107 |
|
|
+[0-9a-f]+: 41 54 30 00 la %r5,0\(%r4,%r3\)
|
108 |
|
|
+[0-9a-f]+: e3 20 d0 40 00 04 lg %r2,64\(%r13\)
|
109 |
|
|
+[0-9a-f]+: c0 04 00 00 00 00 brcl 0,[0-9a-f]+
|
110 |
|
|
+[0-9a-f]+: 41 32 90 00 la %r3,0\(%r2,%r9\)
|
111 |
|
|
+[0-9a-f]+: e3 40 d0 48 00 04 lg %r4,72\(%r13\)
|
112 |
|
|
+[0-9a-f]+: 41 54 30 00 la %r5,0\(%r4,%r3\)
|
113 |
|
|
+[0-9a-f]+: e3 40 d0 50 00 04 lg %r4,80\(%r13\)
|
114 |
|
|
+[0-9a-f]+: 41 54 30 00 la %r5,0\(%r4,%r3\)
|
115 |
|
|
# IE against global var
|
116 |
|
|
+[0-9a-f]+: e3 30 d0 58 00 04 lg %r3,88\(%r13\)
|
117 |
|
|
+[0-9a-f]+: e3 33 c0 00 00 04 lg %r3,0\(%r3,%r12\)
|
118 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
119 |
|
|
# IE -> LE against global var defined in exec
|
120 |
|
|
+[0-9a-f]+: e3 30 d0 60 00 04 lg %r3,96\(%r13\)
|
121 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
122 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
123 |
|
|
# IE -> LE against local var
|
124 |
|
|
+[0-9a-f]+: e3 30 d0 68 00 04 lg %r3,104\(%r13\)
|
125 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
126 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
127 |
|
|
# IE -> LE against hidden var
|
128 |
|
|
+[0-9a-f]+: e3 30 d0 70 00 04 lg %r3,112\(%r13\)
|
129 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
130 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
131 |
|
|
# IE against global var with larl got access
|
132 |
|
|
+[0-9a-f]+: c0 30 [0-9a-f ]+ larl %r3,[0-9a-f]+ <_GLOBAL_OFFSET_TABLE_\+0x28>
|
133 |
|
|
+[0-9a-f]+: e3 33 c0 00 00 04 lg %r3,0\(%r3,%r12\)
|
134 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
135 |
|
|
# IE against global var defined in exec with larl got access
|
136 |
|
|
+[0-9a-f]+: c0 30 [0-9a-f ]+ larl %r3,[0-9a-f]+ <_GLOBAL_OFFSET_TABLE_\+0x38>
|
137 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
138 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
139 |
|
|
# IE against local var with larl got access
|
140 |
|
|
+[0-9a-f]+: c0 30 [0-9a-f ]+ larl %r3,[0-9a-f]+ <_GLOBAL_OFFSET_TABLE_\+0x20>
|
141 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
142 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
143 |
|
|
# IE against hidden var with larl got access
|
144 |
|
|
+[0-9a-f]+: c0 30 [0-9a-f ]+ larl %r3,[0-9a-f]+ <_GLOBAL_OFFSET_TABLE_\+0x40>
|
145 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
146 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
147 |
|
|
# IE against global var with small got access (no optimization)
|
148 |
|
|
+[0-9a-f]+: e3 30 c0 28 00 04 lg %r3,40\(%r12\)
|
149 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
150 |
|
|
# IE against global var defined in exec with small got access
|
151 |
|
|
# (no optimization)
|
152 |
|
|
+[0-9a-f]+: e3 30 c0 38 00 04 lg %r3,56\(%r12\)
|
153 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
154 |
|
|
# IE against local var with small got access (no optimization)
|
155 |
|
|
+[0-9a-f]+: e3 30 c0 20 00 04 lg %r3,32\(%r12\)
|
156 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
157 |
|
|
# IE against hidden var with small got access (no optimization)
|
158 |
|
|
+[0-9a-f]+: e3 30 c0 40 00 04 lg %r3,64\(%r12\)
|
159 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
160 |
|
|
# function epilog
|
161 |
|
|
+[0-9a-f]+: eb 6e f0 d0 00 04 lmg %r6,%r14,208\(%r15\)
|
162 |
|
|
+[0-9a-f]+: 07 fe br %r14
|
163 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
164 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
165 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
166 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
167 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
168 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
169 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
170 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
171 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
172 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|
173 |
|
|
|
174 |
|
|
0+[0-9a-f]+ <_start>:
|
175 |
|
|
# function prolog
|
176 |
|
|
+[0-9a-f]+: 90 6e f0 18 stm %r6,%r14,24\(%r15\)
|
177 |
|
|
+[0-9a-f]+: a7 d5 00 16 bras %r13,[0-9a-f]+ <_start\+0x30>
|
178 |
|
|
# sG6@indntpoff
|
179 |
|
|
+[0-9a-f]+: 00 00 00 00 .long 0x00000000
|
180 |
|
|
+[0-9a-f]+: 80 00 [0-9a-f ]+ ssm [0-9]+\(%r1\)
|
181 |
|
|
# bg6@indntpoff
|
182 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
183 |
|
|
+[0-9a-f]+: ff ff ff d4 .long 0xffffffd4
|
184 |
|
|
# bl6@indntpoff
|
185 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
186 |
|
|
+[0-9a-f]+: ff ff ff f4 .long 0xfffffff4
|
187 |
|
|
# sh6@indntpoff
|
188 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
189 |
|
|
+[0-9a-f]+: ff ff ff b4 .long 0xffffffb4
|
190 |
|
|
# sg3@indntpoff
|
191 |
|
|
+[0-9a-f]+: ff ff ff ff .long 0xffffffff
|
192 |
|
|
+[0-9a-f]+: ff ff ff 68 .long 0xffffff68
|
193 |
|
|
# function prolog
|
194 |
|
|
+[0-9a-f]+: b9 04 00 ef lgr %r14,%r15
|
195 |
|
|
+[0-9a-f]+: a7 fb ff 60 aghi %r15,-160
|
196 |
|
|
+[0-9a-f]+: e3 e0 e0 00 00 24 stg %r14,0\(%r14\)
|
197 |
|
|
# extract TCB
|
198 |
|
|
+[0-9a-f]+: b2 4f 00 90 ear %r9,%a0
|
199 |
|
|
+[0-9a-f]+: eb 94 00 20 00 0d sllg %r9,%r4,32
|
200 |
|
|
+[0-9a-f]+: b2 4f 00 91 ear %r9,%a1
|
201 |
|
|
# IE against global var
|
202 |
|
|
+[0-9a-f]+: e3 30 d0 00 00 04 lg %r3,0\(%r13\)
|
203 |
|
|
+[0-9a-f]+: e3 33 c0 00 00 04 lg %r3,0\(%r3,%r12\)
|
204 |
|
|
+[0-9a-f]+: 41 33 90 00 la %r3,0\(%r3,%r9\)
|
205 |
|
|
# IE -> LE against global var defined in exec
|
206 |
|
|
+[0-9a-f]+: e3 30 d0 08 00 04 lg %r3,8\(%r13\)
|
207 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
208 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
209 |
|
|
# IE -> LE against local var
|
210 |
|
|
+[0-9a-f]+: e3 30 d0 10 00 04 lg %r3,16\(%r13\)
|
211 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
212 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
213 |
|
|
# IE -> LE against hidden but not local var
|
214 |
|
|
+[0-9a-f]+: e3 30 d0 18 00 04 lg %r3,24\(%r13\)
|
215 |
|
|
+[0-9a-f]+: eb 43 00 00 00 0d sllg %r4,%r3,0
|
216 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
217 |
|
|
# LE, global var defined in exec
|
218 |
|
|
+[0-9a-f]+: e3 40 d0 20 00 04 lg %r4,32\(%r13\)
|
219 |
|
|
+[0-9a-f]+: 41 54 90 00 la %r5,0\(%r4,%r9\)
|
220 |
|
|
# function epilog
|
221 |
|
|
+[0-9a-f]+: eb 6e f0 d0 00 04 lmg %r6,%r14,208\(%r15\)
|
222 |
|
|
+[0-9a-f]+: 07 fe br %r14
|
223 |
|
|
+[0-9a-f]+: 07 07 bcr 0,%r7
|