1 # Expect script for various ARM ELF tests. 2 # Copyright (C) 2002-2014 Free Software Foundation, Inc. 3 # 4 # This file is part of the GNU Binutils. 5 # 6 # This program is free software; you can redistribute it and/or modify 7 # it under the terms of the GNU General Public License as published by 8 # the Free Software Foundation; either version 3 of the License, or 9 # (at your option) any later version. 10 # 11 # This program is distributed in the hope that it will be useful, 12 # but WITHOUT ANY WARRANTY; without even the implied warranty of 13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 # GNU General Public License for more details. 15 # 16 # You should have received a copy of the GNU General Public License 17 # along with this program; if not, write to the Free Software 18 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, 19 # MA 02110-1301, USA. 20 # 21 22 if {[istarget "arm-*-vxworks"]} { 23 set armvxworkstests { 24 {"VxWorks shared library test 1" "-shared -Tvxworks1.ld" "" 25 "" {vxworks1-lib.s} 26 {{readelf --relocs vxworks1-lib.rd} {objdump -dr vxworks1-lib.dd} 27 {readelf --symbols vxworks1-lib.nd} {readelf -d vxworks1-lib.td}} 28 "libvxworks1.so"} 29 {"VxWorks executable test 1 (dynamic)" \ 30 "tmpdir/libvxworks1.so -Tvxworks1.ld -q --force-dynamic" "" 31 "" {vxworks1.s} 32 {{readelf --relocs vxworks1.rd} {objdump -dr vxworks1.dd}} 33 "vxworks1"} 34 {"VxWorks executable test 2 (dynamic)" \ 35 "-Tvxworks1.ld -q --force-dynamic" "" 36 "" {vxworks2.s} 37 {{readelf --segments vxworks2.sd}} 38 "vxworks2"} 39 {"VxWorks executable test 2 (static)" 40 "-Tvxworks1.ld" "" 41 "" {vxworks2.s} 42 {{readelf --segments vxworks2-static.sd}} 43 "vxworks2"} 44 } 45 run_ld_link_tests $armvxworkstests 46 run_dump_test "vxworks1-static" 47 run_dump_test "emit-relocs1-vxworks" 48 } 49 50 if { [istarget "arm*-*-symbianelf*"] } { 51 run_dump_test "symbian-seg1" 52 } 53 54 # Exclude non-ARM-ELF targets. 55 56 if { ![is_elf_format] || ![istarget "arm*-*-*"] } { 57 return 58 } 59 60 # List contains test-items with 3 items followed by 2 lists and one more item: 61 # 0:name 1:ld early options 2:ld late options 3:assembler options 62 # 4:filenames of assembler files 5: action and options. 6: name of output file 63 64 # Actions: 65 # objdump: Apply objdump options on result. Compare with regex (last arg). 66 # nm: Apply nm options on result. Compare with regex (last arg). 67 # readelf: Apply readelf options on result. Compare with regex (last arg). 68 69 set armelftests_common { 70 {"Group relocations" "-Ttext 0x8000 -Tdata 0x3000000 --section-start alpha=0xeef0 --section-start beta=0xffeef0" "" "" {group-relocs.s} 71 {{objdump -dr group-relocs.d}} 72 "group-relocs"} 73 {"Indirect cross-library function reference (set-up)" 74 "-shared" "" "" {arm-lib-plt-2a.s} 75 {} 76 "arm-lib-plt-2a.so"} 77 {"Indirect cross-library function reference" 78 "-shared tmpdir/arm-lib-plt-2a.so" "" "" {arm-lib-plt-2b.s} 79 {{objdump -dr arm-lib-plt-2.dd} {readelf --relocs arm-lib-plt-2.rd}} 80 "arm-lib-plt-2b.so"} 81 {"Simple static application" "" "" "" {arm-static-app.s} 82 {{objdump -fdw arm-static-app.d} {objdump -rw arm-static-app.r}} 83 "arm-static-app"} 84 {"target1-abs" "-static --target1-abs -T arm.ld" "" "" {arm-target1.s} 85 {{objdump -s arm-target1-abs.d}} 86 "arm-target1-abs"} 87 {"target1-rel" "-static --target1-rel -T arm.ld" "" "" {arm-target1.s} 88 {{objdump -s arm-target1-rel.d}} 89 "arm-target1-rel"} 90 {"target2-rel" "-static --target2=rel -T arm.ld" "" "" {arm-target2.s} 91 {{objdump -s arm-target2-rel.d}} 92 "arm-target2-rel"} 93 {"target2-abs" "-static --target2=abs -T arm.ld" "" "" {arm-target2.s} 94 {{objdump -s arm-target2-abs.d}} 95 "arm-target2-abs"} 96 {"target2-got-rel" "-static --target2=got-rel -T arm.ld" "" "" {arm-target2.s} 97 {{objdump -s arm-target2-got-rel.d}} 98 "arm-target2-got-rel"} 99 {"arm-rel31" "-static -T arm.ld" "" "" {arm-rel31.s} 100 {{objdump -s arm-rel31.d}} 101 "arm-rel31"} 102 {"arm-rel32" "-shared -T arm-dyn.ld" "" "" {arm-rel32.s} 103 {{objdump -Rsj.data arm-rel32.d}} 104 "arm-rel32"} 105 {"arm-call" "--no-fix-arm1176 -static -T arm.ld" "" "-meabi=4" {arm-call1.s arm-call2.s} 106 {{objdump -d arm-call.d}} 107 "arm-call"} 108 {"TLS shared library" "-shared -T arm-lib.ld" "" "" {tls-lib.s} 109 {{objdump -fdw tls-lib.d} {objdump -Rw tls-lib.r}} 110 "tls-lib.so"} 111 {"TLS dynamic application" "-T arm-dyn.ld tmpdir/tls-lib.so" "" "" {tls-app.s} 112 {{objdump -fdw tls-app.d} {objdump -Rw tls-app.r}} 113 "tls-app"} 114 {"TLS gnu shared library got" "-shared -T arm-dyn.ld" "" "" {tls-gdesc-got.s} 115 {{objdump "-fDR -j .got" tls-gdesc-got.d}} 116 "tls-lib2-got.so"} 117 {"TLS gnu GD to IE relaxation" "-static -T arm-dyn.ld" "" "" {tls-gdierelax.s} 118 {{objdump -fdw tls-gdierelax.d}} 119 "tls-app-rel-ie"} 120 {"TLS gnu GD to IE shared relaxation" "--no-fix-arm1176 -shared -T arm-dyn.ld" "" "" {tls-gdierelax2.s} 121 {{objdump -fdw tls-gdierelax2.d}} 122 "tls-app-rel-ie2"} 123 {"TLS gnu GD to LE relaxation" "-T arm-dyn.ld" "" "" {tls-gdlerelax.s} 124 {{objdump -fdw tls-gdlerelax.d}} 125 "tls-app-rel-le"} 126 {"TLS mixed models shared lib" "-shared -T arm-dyn.ld" "" "" {tls-mixed.s} 127 {{objdump -Rw tls-mixed.r}} 128 "tls-mixed.so"} 129 {"TLS descseq relaxation" "-T arm-dyn.ld" "" "" {tls-descrelax.s} 130 {{objdump -fdw tls-descrelax.d}} 131 "tls-descrelax"} 132 {"TLS descseq relaxation v7" "-T arm-dyn.ld" "" "" {tls-descrelax-v7.s} 133 {{objdump -fdw tls-descrelax-v7.d}} 134 "tls-descrelax-v7"} 135 {"TLS descseq relaxation BE8" "-T arm-dyn.ld -EB --be8" "" "-mbig-endian" {tls-descrelax-be8.s} 136 {{objdump -fdw tls-descrelax-be8.d}} 137 "tls-descrelax-be8"} 138 {"TLS descseq relaxation BE32" "-T arm-dyn.ld -EB" "" "-mbig-endian" {tls-descrelax-be32.s} 139 {{objdump -fdw tls-descrelax-be32.d}} 140 "tls-descrelax-be32"} 141 {"TLS local PIC symbol static link" "-T arm.ld" "" "" {tls-local-static.s} 142 {{objdump -fdw tls-local-static.d}} 143 "tls-local-static"} 144 {"MOVW/MOVT" "-static -T arm.ld" "" "" {arm-movwt.s} 145 {{objdump -dw arm-movwt.d}} 146 "arm-movwt"} 147 {"BE8 Mapping Symbols" "-static -T arm.ld -EB --be8" "" "-EB" {arm-be8.s} 148 {{objdump -d arm-be8.d}} 149 "arm-be8"} 150 {"VFP11 denorm erratum fix, scalar operation" 151 "-EL --vfp11-denorm-fix=scalar -Ttext=0x8000" "" "-EL -mfpu=vfpxd" {vfp11-fix-scalar.s} 152 {{objdump -dr vfp11-fix-scalar.d}} 153 "vfp11-fix-scalar"} 154 {"VFP11 denorm erratum fix, vector operation" 155 "-EB --vfp11-denorm-fix=vector -Ttext=0x8000" "" "-EB -mfpu=vfpxd" {vfp11-fix-vector.s} 156 {{objdump -dr vfp11-fix-vector.d}} 157 "vfp11-fix-vector"} 158 {"VFP11 denorm erratum fix, embedded code-like data" 159 "-EL --vfp11-denorm-fix=scalar -Ttext=0x8000" "" "-EL -mfpu=vfpxd" {vfp11-fix-none.s} 160 {{objdump -dr vfp11-fix-none.d}} 161 "vfp11-fix-none"} 162 {"Unwinding and -gc-sections" "-gc-sections" "" "" {gc-unwind.s} 163 {{objdump -sj.data gc-unwind.d}} 164 "gc-unwind"} 165 {"script-type" "-static -T script-type.ld" "" "" {script-type.s} 166 {{readelf -s script-type.sym}} 167 "script-type"} 168 {"callweak" "-static -T arm.ld" "" "" {callweak.s} 169 {{objdump -dr callweak.d}} 170 "callweak"} 171 {"Relocation boundaries" "-defsym x=0 -defsym y=0 -defsym _start=0" "" "" {reloc-boundaries.s} 172 {{objdump -s reloc-boundaries.d}} 173 "reloc-boundaries"} 174 {"Data only mapping symbols" "-T data-only-map.ld -Map map" "" "" {data-only-map.s} 175 {{objdump -dr data-only-map.d}} 176 "data-only-map"} 177 {"Data only mapping symbols for merged sections" "-T rodata-merge-map.ld" "" "" {rodata-merge-map1.s rodata-merge-map2.s rodata-merge-map3.s} 178 {{readelf -s rodata-merge-map.sym}} 179 "rodata-merge-map"} 180 {"GOT relocations in executables (setup)" "-shared" "" 181 "" {exec-got-1a.s} 182 {} 183 "exec-got-1.so"} 184 {"GOT relocations in executables" "tmpdir/exec-got-1.so" "" 185 "" {exec-got-1b.s} 186 {{readelf --relocs exec-got-1.d}} 187 "exec-got-1"} 188 {"Simple non-PIC shared library (no PLT check)" "-shared" "" "" {arm-lib.s} 189 {{objdump -Rw arm-lib.r}} 190 "arm-lib.so"} 191 {"EABI soft-float ET_EXEC ABI flag" "-T arm.ld" "" "-mfloat-abi=soft -meabi=5" {eabi-soft-float.s} 192 {{readelf -h eabi-soft-float.d}} 193 "eabi-soft-float"} 194 {"EABI hard-float ET_EXEC ABI flag" "-T arm.ld" "" "-mfloat-abi=hard -meabi=5" {eabi-hard-float.s} 195 {{readelf -h eabi-hard-float.d}} 196 "eabi-hard-float"} 197 {"EABI hard-float ET_DYN ABI flag" "-shared" "" "-mfloat-abi=hard -meabi=5" {eabi-hard-float.s} 198 {{readelf -h eabi-hard-float.d}} 199 "eabi-hard-float.so"} 200 {"EABI ABI flags wrong ABI version" "-T arm.ld" "" "-mfloat-abi=soft -meabi=4" {eabi-soft-float.s} 201 {{readelf -h eabi-soft-float-ABI4.d}} 202 "eabi-soft-float-no-flags"} 203 {"EABI ABI flags ld -r" "-r" "" "-mfloat-abi=soft -meabi=5" {eabi-soft-float.s} 204 {{readelf -h eabi-soft-float-r.d}} 205 "eabi-soft-float-r.o"} 206 {"PC-relative in -shared" "-shared" "" 207 "" {pcrel-shared.s} 208 {{readelf -dr pcrel-shared.rd}} 209 "pcrel-shared.so"} 210 } 211 212 set armelftests_nonacl { 213 {"Thumb-1 BL" "-Ttext 0x1000 --section-start .foo=0x401000" "" "" {thumb1-bl.s} 214 {{objdump -dr thumb1-bl.d}} 215 "thumb1-bl"} 216 {"Thumb entry point" "-T arm.ld" "" "" {thumb-entry.s} 217 {{readelf -h thumb-entry.d}} 218 "thumb-entry"} 219 {"thumb-rel32" "-static -T arm.ld" "" "" {thumb-rel32.s} 220 {{objdump -s thumb-rel32.d}} 221 "thumb-rel32"} 222 {"jump19" "-static -T arm.ld" "" "" {jump19.s} 223 {{objdump -dr jump19.d}} 224 "jump19"} 225 {"Thumb and -gc-sections" "-shared -T arm-dyn.ld" "" "" {gc-thumb-lib.s} 226 {} 227 "gc-thumb-lib.so"} 228 {"Thumb and -gc-sections" "-pie -T arm.ld -gc-sections tmpdir/gc-thumb-lib.so" "" "" {gc-thumb.s} 229 {{readelf --relocs gc-thumb.d}} 230 "gc-thumb"} 231 232 {"Simple non-PIC shared library" "-shared" "" "" {arm-lib.s} 233 {{objdump -fdw arm-lib.d} {objdump -Rw arm-lib.r}} 234 "arm-lib.so"} 235 {"Simple PIC shared library" "-shared" "" "" {arm-lib-plt32.s} 236 {{objdump -fdw arm-lib-plt32.d} {objdump -Rw arm-lib-plt32.r}} 237 "arm-lib-plt32.so"} 238 {"Simple dynamic application" "tmpdir/arm-lib.so" "" "" {arm-app.s} 239 {{objdump -fdw arm-app.d} {objdump -Rw arm-app.r}} 240 "arm-app"} 241 {"Simple static application without .rel.plt in linker script" 242 "-T arm-no-rel-plt.ld" "" "" {arm-static-app.s} 243 {{objdump -fdw arm-static-app.d} {objdump -rw arm-static-app.r}} 244 "arm-static-app"} 245 {"Simple dynamic application without .rel.plt in linker script" 246 "tmpdir/arm-lib.so -T arm-no-rel-plt.ld" "" "" {arm-app.s} 247 {{ld arm-no-rel-plt.out}} 248 "arm-app"} 249 {"Non-pcrel function reference" "tmpdir/arm-lib.so" "" "" {arm-app-abs32.s} 250 {{objdump -fdw arm-app-abs32.d} {objdump -Rw arm-app-abs32.r}} 251 "arm-app-abs32"} 252 {"Thumb shared library with ARM entry points" "-shared -T arm-lib.ld" "" "-mthumb-interwork" 253 {mixed-lib.s} 254 {{objdump -fdw armthumb-lib.d} {readelf -Ds armthumb-lib.sym}} 255 "armthumb-lib.so"} 256 {"Mixed ARM/Thumb shared library" "-shared -T arm-lib.ld -use-blx" "" "" 257 {mixed-lib.s} 258 {{objdump -fdw mixed-lib.d} {objdump -Rw mixed-lib.r} 259 {readelf -Ds mixed-lib.sym}} 260 "mixed-lib.so"} 261 {"Mixed ARM/Thumb dynamic application" "tmpdir/mixed-lib.so -T arm-dyn.ld" "" "" 262 {mixed-app.s} 263 {{objdump -fdw mixed-app.d} {objdump -Rw mixed-app.r} 264 {readelf -Ds mixed-app.sym}} 265 "mixed-app"} 266 {"Mixed ARM/Thumb arch5 dynamic application" "tmpdir/mixed-lib.so -T arm-dyn.ld --use-blx" "" "" 267 {mixed-app.s} 268 {{objdump -fdw mixed-app-v5.d} {objdump -Rw mixed-app.r} 269 {readelf -Ds mixed-app.sym}} 270 "mixed-app-v5"} 271 {"Using Thumb lib by another lib" "-shared tmpdir/mixed-lib.so" "" "" {use-thumb-lib.s} 272 {{readelf -Ds use-thumb-lib.sym}} 273 "use-thumb-lib.so"} 274 {"TLS gnu shared library inlined trampoline" "--no-fix-arm1176 -shared -T arm-dyn.ld" "" "" {tls-descseq.s} 275 {{objdump -fdw tls-descseq.d} {objdump -Rw tls-descseq.r}} 276 "tls-lib2inline.so"} 277 {"TLS shared library gdesc local" "--no-fix-arm1176 -shared -T arm-dyn.ld" "" "" {tls-lib-loc.s} 278 {{objdump -fdw tls-lib-loc.d} {objdump -Rw tls-lib-loc.r}} 279 "tls-lib-loc.so"} 280 } 281 282 run_ld_link_tests $armelftests_common 283 if { ![istarget "arm*-*-nacl*"] } { 284 run_ld_link_tests $armelftests_nonacl 285 } 286 287 run_dump_test "group-relocs-alu-bad" 288 run_dump_test "group-relocs-alu-bad-2" 289 run_dump_test "group-relocs-ldr-bad" 290 run_dump_test "group-relocs-ldr-bad-2" 291 run_dump_test "group-relocs-ldrs-bad" 292 run_dump_test "group-relocs-ldrs-bad-2" 293 run_dump_test "group-relocs-ldc-bad" 294 run_dump_test "group-relocs-ldc-bad-2" 295 run_dump_test "thumb2-bl-undefweak" 296 run_dump_test "thumb2-bl-undefweak1" 297 run_dump_test "emit-relocs1" 298 run_dump_test "movw-shared-1" 299 run_dump_test "movw-shared-2" 300 run_dump_test "movw-shared-3" 301 run_dump_test "movw-shared-4" 302 303 # Exclude non-ARM-EABI targets. 304 305 if { ![istarget "arm*-*-*eabi*"] && ![istarget "arm*-*-nacl*"] } { 306 # Special variants of these tests, as a different farcall stub is 307 # generated for a non-ARM-EABI target: indeed in such a case, 308 # there are no attributes to indicate that blx can be used. 309 310 set arm_noeabi_tests { 311 {"Thumb-2-as-Thumb-1 BL" "-Ttext 0x1000 --section-start .foo=0x100100c" "" "" {thumb2-bl-as-thumb1-bad.s} 312 {{objdump -d thumb2-bl-as-thumb1-bad-noeabi.d}} 313 "thumb2-bl-as-thumb1-bad"} 314 {"Thumb-2 BL bad" "-Ttext 0x1000 --section-start .foo=0x100100c" "" "" {thumb2-bl-bad.s} 315 {{objdump -d thumb2-bl-bad-noeabi.d}} 316 "thumb2-bl-bad"} 317 } 318 run_ld_link_tests $arm_noeabi_tests 319 320 return 321 } 322 323 # Farcalls stubs are fully supported for ARM-EABI only. 324 # This list is massaged below into run_ld_link_tests standard format. 325 # The source list is almost that same format. The one difference is 326 # that each "action" (elements of element 5) might have four elements 327 # instead of three; in that case, the fourth element is the name of 328 # the dump file to use for arm*-*nacl* targets instead of the canonical 329 # dump file (the third element). 330 set armeabitests_common { 331 {"EABI attribute merging" "-r" "" "" {attr-merge.s attr-merge.s} 332 {{readelf -A attr-merge.attr}} 333 "attr-merge"} 334 {"EABI attribute merging 2" "-r" "" "" {attr-merge-2a.s attr-merge-2b.s} 335 {{readelf -A attr-merge-2.attr}} 336 "attr-merge-2"} 337 {"EABI attribute merging 3" "-r" "" "" {attr-merge-3a.s attr-merge-3b.s} 338 {{readelf -A attr-merge-3.attr}} 339 "attr-merge-3"} 340 {"EABI attribute merging 4" "-r" "" "" {attr-merge-4a.s attr-merge-4b.s} 341 {{readelf -A attr-merge-4.attr}} 342 "attr-merge-4"} 343 {"EABI attribute merging 5" "-r" "" "" {attr-merge-5.s attr-merge-5.s} 344 {{readelf -A attr-merge-5.attr}} 345 "attr-merge-5"} 346 {"EABI attribute merging 6" "-r" "" "" {attr-merge-6a.s attr-merge-6b.s} 347 {{readelf -A attr-merge-6.attr}} 348 "attr-merge-6"} 349 {"EABI attribute merging 6 reversed" "-r" "" "" {attr-merge-6b.s attr-merge-6a.s} 350 {{readelf -A attr-merge-6.attr}} 351 "attr-merge-6r"} 352 {"EABI attribute merging 7" "-r" "" "" {attr-merge-7a.s attr-merge-7b.s} 353 {{readelf -A attr-merge-7.attr}} 354 "attr-merge-7"} 355 {"EABI attribute arch merging 1" "-r" "" "" {arch-v6k.s arch-v6t2.s} 356 {{readelf -A attr-merge-arch-1.attr}} 357 "attr-merge-arch-1"} 358 {"EABI attribute arch merging 1 reversed" "-r" "" "" {arch-v6t2.s arch-v6k.s} 359 {{readelf -A attr-merge-arch-1.attr}} 360 "attr-merge-arch-1r"} 361 {"EABI attribute arch merging 2" "-r" "" "" {arch-v6k.s arch-v6.s} 362 {{readelf -A attr-merge-arch-2.attr}} 363 "attr-merge-arch-2"} 364 {"EABI attribute arch merging 2 reversed" "-r" "" "" {arch-v6.s arch-v6k.s} 365 {{readelf -A attr-merge-arch-2.attr}} 366 "attr-merge-arch-2r"} 367 {"MOVW/MOVT and merged sections" "-T arm.ld" "" "" {movw-merge.s} 368 {{objdump -dw movw-merge.d}} 369 "movw-merge"} 370 {"MOVW/MOVT against shared libraries" "tmpdir/arm-lib.so" "" "" {arm-app-movw.s} 371 {{objdump -Rw arm-app.r}} 372 "arm-app-movw"} 373 374 {"ARM-ARM farcall" "-Ttext 0x1000 --section-start .foo=0x2001020" "" "" {farcall-arm-arm.s} 375 {{objdump -d farcall-arm-arm.d farcall-arm-nacl.d}} 376 "farcall-arm-arm"} 377 {"ARM-ARM farcall (PIC veneer)" "-Ttext 0x1000 --section-start .foo=0x2001020 --pic-veneer" "" "" {farcall-arm-arm.s} 378 {{objdump -d farcall-arm-arm-pic-veneer.d farcall-arm-nacl-pic.d}} 379 "farcall-arm-arm-pic-veneer"} 380 {"ARM-ARM farcall (BE8)" "-Ttext 0x1000 --section-start .foo=0x2001020 -EB --be8" "" "-EB" {farcall-arm-arm.s} 381 {{objdump -d farcall-arm-arm.d farcall-arm-nacl.d}} 382 "farcall-arm-arm-be8"} 383 {"ARM-ARM farcall (BE)" "-Ttext 0x1000 --section-start .foo=0x2001020 -EB" "" "-EB" {farcall-arm-arm.s} 384 {{objdump -d farcall-arm-arm.d farcall-arm-nacl.d}} 385 "farcall-arm-arm-be"} 386 387 {"Long branch with mixed text and data" "-T arm.ld" "" "" {farcall-data.s} 388 {{objdump -dr farcall-data.d farcall-data-nacl.d}} 389 "farcall-data"} 390 {"callweak-2" "-static -T arm.ld" "" "" {callweak-2.s} 391 {{objdump -dr callweak-2.d}} 392 "callweak-2"} 393 {"abs call" "-T arm.ld" "" "" {abs-call-1.s} 394 {{objdump -d abs-call-1.d}} 395 "abs-call-1"} 396 } 397 398 set armeabitests_nonacl { 399 {"ARM-Thumb farcall" "-Ttext 0x1000 --section-start .foo=0x2001014" "" "" {farcall-arm-thumb.s} 400 {{objdump -d farcall-arm-thumb.d}} 401 "farcall-arm-thumb"} 402 {"ARM-Thumb farcall with BLX" "--no-fix-arm1176 -Ttext 0x1000 --section-start .foo=0x2001014" "" "-march=armv5t" {farcall-arm-thumb.s} 403 {{objdump -d farcall-arm-thumb-blx.d}} 404 "farcall-arm-thumb-blx"} 405 {"ARM-Thumb farcall (PIC veneer)" "-Ttext 0x1000 --section-start .foo=0x2001014 --pic-veneer" "" "" {farcall-arm-thumb.s} 406 {{objdump -d farcall-arm-thumb-pic-veneer.d}} 407 "farcall-arm-thumb-pic-veneer"} 408 {"ARM-Thumb farcall with BLX (PIC veneer)" "-Ttext 0x1000 --section-start .foo=0x2001014 --pic-veneer" "" "-march=armv5t" {farcall-arm-thumb.s} 409 {{objdump -d farcall-arm-thumb-blx-pic-veneer.d}} 410 "farcall-arm-thumb-blx-pic-veneer"} 411 412 {"Thumb-Thumb farcall with BLX" "--no-fix-arm1176 -Ttext 0x1000 --section-start .foo=0x2001014" "" "-march=armv5t" {farcall-thumb-thumb.s} 413 {{objdump -d farcall-thumb-thumb-blx.d}} 414 "farcall-thumb-thumb-blx"} 415 {"Thumb-Thumb farcall M profile" "-Ttext 0x1000 --section-start .foo=0x2001014" "" "-march=armv7-m" {farcall-thumb-thumb.s} 416 {{objdump -d farcall-thumb-thumb-m.d}} 417 "farcall-thumb-thumb-m"} 418 {"Thumb-Thumb farcall v6-M" "-Ttext 0x1000 --section-start .foo=0x2001014" "" "-march=armv6-m" {farcall-thumb-thumb.s} 419 {{objdump -d farcall-thumb-thumb-m.d}} 420 "farcall-thumb-thumb-v6-m"} 421 {"Thumb-Thumb farcall" "-Ttext 0x1000 --section-start .foo=0x2001014" "" "-march=armv4t" {farcall-thumb-thumb.s} 422 {{objdump -d farcall-thumb-thumb.d}} 423 "farcall-thumb-thumb"} 424 {"Thumb-Thumb farcall with BLX (PIC veneer)" "--no-fix-arm1176 -Ttext 0x1000 --section-start .foo=0x2001014 --pic-veneer" "" "-march=armv5t" {farcall-thumb-thumb.s} 425 {{objdump -d farcall-thumb-thumb-blx-pic-veneer.d}} 426 "farcall-thumb-thumb-blx-pic-veneer"} 427 {"Thumb-Thumb farcall M profile (PIC veneer)" "-Ttext 0x1000 --section-start .foo=0x2001014 --pic-veneer" "" "-march=armv7-m" {farcall-thumb-thumb.s} 428 {{objdump -d farcall-thumb-thumb-m-pic-veneer.d}} 429 "farcall-thumb-thumb-m-pic-veneer"} 430 {"Thumb-Thumb farcall (PIC veneer)" "-Ttext 0x1000 --section-start .foo=0x2001014 --pic-veneer" "" "-march=armv4t" {farcall-thumb-thumb.s} 431 {{objdump -d farcall-thumb-thumb-pic-veneer.d}} 432 "farcall-thumb-thumb-pic-veneer"} 433 434 {"Thumb-ARM farcall" "-Ttext 0x1c01010 --section-start .foo=0x2001014" "" "-W" {farcall-thumb-arm.s} 435 {{objdump -d farcall-thumb-arm.d}} 436 "farcall-thumb-arm"} 437 {"Thumb-ARM farcall (BE8)" "-Ttext 0x1c01010 --section-start .foo=0x2001014 -EB --be8" "" "-W -EB" {farcall-thumb-arm.s} 438 {{objdump -d farcall-thumb-arm.d}} 439 "farcall-thumb-arm-be8"} 440 {"Thumb-ARM farcall (BE)" "-Ttext 0x1c01010 --section-start .foo=0x2001014 -EB" "" "-W -EB" {farcall-thumb-arm.s} 441 {{objdump -d farcall-thumb-arm.d}} 442 "farcall-thumb-arm-be"} 443 {"Thumb-ARM (short) call" "-Ttext 0x1000 --section-start .foo=0x0002014" "" "-W" {farcall-thumb-arm-short.s} 444 {{objdump -d farcall-thumb-arm-short.d}} 445 "farcall-thumb-arm-short"} 446 {"Thumb-ARM farcall with BLX" "--no-fix-arm1176 -Ttext 0x1c01010 --section-start .foo=0x2001014" "" "-W -march=armv5t" {farcall-thumb-arm.s} 447 {{objdump -d farcall-thumb-arm-blx.d}} 448 "farcall-thumb-arm-blx"} 449 {"Thumb-ARM farcall with BLX (PIC veneer)" "--no-fix-arm1176 -Ttext 0x1c01010 --section-start .foo=0x2001014 --pic-veneer" "" "-W -march=armv5t" {farcall-thumb-arm.s} 450 {{objdump -d farcall-thumb-arm-blx-pic-veneer.d}} 451 "farcall-thumb-arm-blx-pic-veneer"} 452 {"Thumb-ARM farcall (PIC veneer)" "-Ttext 0x1c01010 --section-start .foo=0x2001014 --pic-veneer" "" "-W" {farcall-thumb-arm.s} 453 {{objdump -d farcall-thumb-arm-pic-veneer.d}} 454 "farcall-thumb-arm-pic-veneer"} 455 456 {"Thumb-ARM farcall cond" "-Ttext 0x8000 --section-start .foo=0x118000" "" "-W" {farcall-cond-thumb-arm.s} 457 {{objdump -d farcall-cond-thumb-arm.d}} 458 "farcall-cond-thumb-arm"} 459 {"Thumb-ARM farcall cond (BE8)" "-Ttext 0x8000 --section-start .foo=0x118000 -EB --be8" "" "-W -EB" {farcall-cond-thumb-arm.s} 460 {{objdump -d farcall-cond-thumb-arm.d}} 461 "farcall-cond-thumb-arm-be8"} 462 {"Thumb-ARM farcall cond (BE)" "-Ttext 0x8000 --section-start .foo=0x118000 -EB" "" "-W -EB" {farcall-cond-thumb-arm.s} 463 {{objdump -d farcall-cond-thumb-arm.d}} 464 "farcall-cond-thumb-arm-be"} 465 466 {"Multiple farcalls" "-Ttext 0x1000 --section-start .foo=0x2002020" "" "" {farcall-mix.s} 467 {{objdump -d farcall-mix.d}} 468 "farcall-mix"} 469 {"Multiple farcalls from several sections" "-Ttext 0x1000 --section-start .mytext=0x2000 --section-start .foo=0x2003020" "" "" {farcall-mix2.s} 470 {{objdump -d farcall-mix2.d}} 471 "farcall-mix2"} 472 473 {"Mixed ARM/Thumb dynamic application with farcalls" "tmpdir/mixed-lib.so -T arm-dyn.ld --section-start .far_arm=0x2100000 --section-start .far_thumb=0x2200000" "" "" 474 {farcall-mixed-app.s} 475 {{objdump -fdw farcall-mixed-app.d} {objdump -Rw farcall-mixed-app.r} 476 {readelf -Ds farcall-mixed-app.sym}} 477 "farcall-mixed-app"} 478 {"Mixed ARM/Thumb arch5 dynamic application with farcalls" "tmpdir/mixed-lib.so -T arm-dyn.ld --use-blx --section-start .far_arm=0x2100000 --section-start .far_thumb=0x2200000" "" "" 479 {farcall-mixed-app.s} 480 {{objdump -fdw farcall-mixed-app-v5.d} {objdump -Rw farcall-mixed-app.r} 481 {readelf -Ds farcall-mixed-app.sym}} 482 "farcall-mixed-app-v5"} 483 484 {"Mixed ARM/Thumb shared library with long branches (v4t)" "-shared -T arm-lib.ld" "" "-march=armv4t" 485 {farcall-mixed-lib1.s farcall-mixed-lib2.s} 486 {{objdump -fdw farcall-mixed-lib-v4t.d}} 487 "farcall-mixed-lib.so"} 488 489 {"Mixed ARM/Thumb shared library with long branches (v5t)" "--no-fix-arm1176 -shared -T arm-lib.ld" "" "-march=armv5t" 490 {farcall-mixed-lib1.s farcall-mixed-lib2.s} 491 {{objdump -fdw farcall-mixed-lib.d}} 492 "farcall-mixed-lib.so"} 493 494 {"Thumb-2-as-Thumb-1 BL" "--no-fix-arm1176 -Ttext 0x1000 --section-start .foo=0x100100c" "" "" {thumb2-bl-as-thumb1-bad.s} 495 {{objdump -d thumb2-bl-as-thumb1-bad.d}} 496 "thumb2-bl-as-thumb1-bad"} 497 {"Thumb-2 BL" "-Ttext 0x1000 --section-start .foo=0x100100c" "" "" {thumb2-bl-bad.s} 498 {{objdump -d thumb2-bl-bad.d}} 499 "thumb2-bl-bad"} 500 {"Branch to linker script symbol with BL for thumb-only target" "-T branch-lks-sym.ld" "" "" {thumb-bl-lks-sym.s} 501 {{objdump -d thumb-bl-lks-sym.d}} 502 "thumb-bl-lks-sym"} 503 {"Branch to linker script symbol with B for thumb-only target" "-T branch-lks-sym.ld" "" "" {thumb-b-lks-sym.s} 504 {{objdump -d thumb-b-lks-sym.d}} 505 "thumb-b-lks-sym"} 506 507 {"erratum 760522 fix (default for v6z)" "--section-start=.foo=0x2001014" "" 508 "-march=armv6z" {fix-arm1176.s} 509 {{objdump -d fix-arm1176-on.d}} 510 "fix-arm1176-1"} 511 {"erratum 760522 fix (explicitly on at v6z)" "--section-start=.foo=0x2001014 --fix-arm1176" "" 512 "-march=armv6z" {fix-arm1176.s} 513 {{objdump -d fix-arm1176-on.d}} 514 "fix-arm1176-2"} 515 {"erratum 760522 fix (explicitly off at v6z)" "--section-start=.foo=0x2001014 --no-fix-arm1176" "" 516 "-march=armv6z" {fix-arm1176.s} 517 {{objdump -d fix-arm1176-off.d}} 518 "fix-arm1176-3"} 519 {"erratum 760522 fix (default for v5)" "--section-start=.foo=0x2001014 " "" 520 "-march=armv5te" {fix-arm1176.s} 521 {{objdump -d fix-arm1176-on.d}} 522 "fix-arm1176-4"} 523 {"erratum 760522 fix (default for v7-a)" "--section-start=.foo=0x2001014 " "" 524 "-march=armv7-a" {fix-arm1176.s} 525 {{objdump -d fix-arm1176-off.d}} 526 "fix-arm1176-5"} 527 {"erratum 760522 fix (default for ARM1156)" "--section-start=.foo=0x2001014 " "" 528 "-mcpu=arm1156t2f-s" {fix-arm1176.s} 529 {{objdump -d fix-arm1176-off.d}} 530 "fix-arm1176-6"} 531 532 {"Thumb-2 BL" "-Ttext 0x1000 --section-start .foo=0x1001000" "" "" {thumb2-bl.s} 533 {{objdump -dr thumb2-bl.d}} 534 "thumb2-bl"} 535 {"Thumb-2 Interworked branch" "-T arm.ld" "" "" {thumb2-b-interwork.s} 536 {{objdump -dr thumb2-b-interwork.d}} 537 "thumb2-b-interwork"} 538 {"BL/BLX interworking" "-T arm.ld" "" "" {thumb2-bl-blx-interwork.s} 539 {{objdump -dr thumb2-bl-blx-interwork.d}} 540 "thumb2-bl-blx-interwork"} 541 {"ARMv4 interworking" "-static -T arm.ld --fix-v4bx-interworking" "" "--fix-v4bx -meabi=4" {armv4-bx.s} 542 {{objdump -d armv4-bx.d}} 543 "armv4-bx"} 544 545 {"R_ARM_THM_JUMP24 Relocation veneers: Short 1" 546 "--no-fix-arm1176 --section-start destsect=0x00009000 --section-start .text=0x8000" "" 547 "-march=armv7-a -mthumb" 548 {jump-reloc-veneers.s} 549 {{objdump -d jump-reloc-veneers-short1.d}} 550 "jump-reloc-veneers-short1"} 551 {"R_ARM_THM_JUMP24 Relocation veneers: Short 2" 552 "--no-fix-arm1176 --section-start destsect=0x00900000 --section-start .text=0x8000" "" 553 "-march=armv7-a -mthumb" 554 {jump-reloc-veneers.s} 555 {{objdump -d jump-reloc-veneers-short2.d}} 556 "jump-reloc-veneers-short2"} 557 {"R_ARM_THM_JUMP24 Relocation veneers: Long" 558 "--no-fix-arm1176 --section-start destsect=0x09000000 --section-start .text=0x8000" "" 559 "-march=armv7-a -mthumb" 560 {jump-reloc-veneers.s} 561 {{objdump -d jump-reloc-veneers-long.d}} 562 "jump-reloc-veneers-long"} 563 564 {"R_ARM_THM_JUMP19 Relocation veneers: Short" 565 "--section-start destsect=0x000108002 --section-start .text=0x8000" "" 566 "-march=armv7-m -mthumb" 567 {jump-reloc-veneers-cond.s} 568 {{objdump -d jump-reloc-veneers-cond-short.d}} 569 "jump-reloc-veneers-cond-short"} 570 {"R_ARM_THM_JUMP19 Relocation veneers: Long" 571 "--section-start destsect=0x00108004 --section-start .text=0x8000" "" 572 "-march=armv7-m -mthumb" 573 {jump-reloc-veneers-cond.s} 574 {{objdump -d jump-reloc-veneers-cond-long.d}} 575 "jump-reloc-veneers-cond-long"} 576 {"R_ARM_THM_JUMP19 Relocation veneers: Short backward" 577 "--section-start destsect=0x8004 --section-start .text=0x108000" "" 578 "-march=armv7-m -mthumb" 579 {jump-reloc-veneers-cond.s} 580 {{objdump -d jump-reloc-veneers-cond-short-backward.d}} 581 "jump-reloc-veneers-cond-short-backward"} 582 {"R_ARM_THM_JUMP19 Relocation veneers: Long backward" 583 "--section-start destsect=0x8002 --section-start .text=0x108000" "" 584 "-march=armv7-m -mthumb" 585 {jump-reloc-veneers-cond.s} 586 {{objdump -d jump-reloc-veneers-cond-long-backward.d}} 587 "jump-reloc-veneers-cond-long-backward"} 588 589 {"Default group size" "-Ttext 0x1000 --section-start .foo=0x2003020" "" "" {farcall-group.s farcall-group2.s} 590 {{objdump -d farcall-group.d}} 591 "farcall-group-default"} 592 {"Group size=2" "-Ttext 0x1000 --section-start .foo=0x2003020 --stub-group-size=2" "" "" {farcall-group.s farcall-group2.s} 593 {{objdump -d farcall-group-size2.d}} 594 "farcall-group-size2"} 595 {"Group size limit" "-Ttext 0x1000 --section-start .far=0x2003020" "" "" {farcall-group3.s farcall-group4.s} 596 {{objdump -d farcall-group-limit.d}} 597 "farcall-group-limit"} 598 599 {"TLS gnu shared library" "--no-fix-arm1176 -shared -T arm-dyn.ld" "" "" {tls-gdesc.s} 600 {{objdump -fdw tls-gdesc.d} {objdump -Rw tls-gdesc.r}} 601 "tls-lib2.so"} 602 {"TLS gnu shared library non-lazy" "-z now -shared -T arm-dyn.ld" "" "" {tls-gdesc.s} 603 {{readelf "-x .got" tls-gdesc-nlazy.g}} 604 "tls-lib2-nlazy.so"} 605 {"TLS long plt library" "-shared -T arm-dyn.ld --section-start .foo=0x4001000" "" "" {tls-longplt-lib.s} 606 {{objdump -fdw tls-longplt-lib.d}} 607 "tls-longplt-lib.so"} 608 {"TLS long plt" "-T arm-dyn.ld --section-start .foo=0x4001000 tmpdir/tls-longplt-lib.so" "" "" {tls-longplt.s} 609 {{objdump -fdw tls-longplt.d}} 610 "tls-longplt"} 611 {"TLS thumb1" "-shared -T arm-dyn.ld --section-start .foo=0x4001000" "" "" {tls-thumb1.s} 612 {{objdump -fdw tls-thumb1.d}} 613 "tls-thumb1"} 614 {"Cortex-A8 erratum fix, b.w" 615 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-fix-b.s} 616 {{objdump -dr cortex-a8-fix-b.d}} 617 "cortex-a8-fix-b"} 618 {"Cortex-A8 erratum fix, bl.w" 619 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-fix-bl.s} 620 {{objdump -dr cortex-a8-fix-bl.d}} 621 "cortex-a8-fix-bl"} 622 {"Cortex-A8 erratum fix, bcc.w" 623 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-fix-bcc.s} 624 {{objdump -dr cortex-a8-fix-bcc.d}} 625 "cortex-a8-fix-bcc"} 626 {"Cortex-A8 erratum fix, blx.w" 627 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-fix-blx.s} 628 {{objdump -dr cortex-a8-fix-blx.d}} 629 "cortex-a8-fix-blx"} 630 {"Cortex-A8 erratum fix, relocate b.w to ARM" 631 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-arm-target.s cortex-a8-fix-b-rel.s} 632 {{objdump -dr cortex-a8-fix-b-rel-arm.d}} 633 "cortex-a8-fix-b-rel-arm"} 634 {"Cortex-A8 erratum fix, relocate b.w to Thumb" 635 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-thumb-target.s cortex-a8-fix-b-rel.s} 636 {{objdump -dr cortex-a8-fix-b-rel-thumb.d}} 637 "cortex-a8-fix-b-rel-thumb"} 638 {"Cortex-A8 erratum fix, relocate bl.w to ARM" 639 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-arm-target.s cortex-a8-fix-bl-rel.s} 640 {{objdump -dr cortex-a8-fix-bl-rel-arm.d}} 641 "cortex-a8-fix-bl-rel-arm"} 642 {"Cortex-A8 erratum fix, relocate bl.w to Thumb" 643 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-thumb-target.s cortex-a8-fix-bl-rel.s} 644 {{objdump -dr cortex-a8-fix-bl-rel-thumb.d}} 645 "cortex-a8-fix-bl-rel-thumb"} 646 {"Cortex-A8 erratum fix, relocate b<cond>.w to Thumb" 647 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-thumb-target.s cortex-a8-fix-bcc-rel.s} 648 {{objdump -dr cortex-a8-fix-bcc-rel-thumb.d}} 649 "cortex-a8-fix-bcc-rel-thumb"} 650 {"Cortex-A8 erratum fix, relocate blx.w to ARM" 651 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-arm-target.s cortex-a8-fix-blx-rel.s} 652 {{objdump -dr cortex-a8-fix-blx-rel-arm.d}} 653 "cortex-a8-fix-blx-rel-arm"} 654 {"Cortex-A8 erratum fix, relocate blx.w to Thumb" 655 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-thumb-target.s cortex-a8-fix-blx-rel.s} 656 {{objdump -dr cortex-a8-fix-blx-rel-thumb.d}} 657 "cortex-a8-fix-blx-rel-thumb"} 658 {"Cortex-A8 erratum fix, relocate bl.w and far call" 659 "-EL -Ttext=0x00 --fix-cortex-a8 --defsym _start=0" "" 660 "-EL -mcpu=cortex-a8" {cortex-a8-far-1.s cortex-a8-far-2.s cortex-a8-far-3.s} 661 {{objdump -dr cortex-a8-far.d}} 662 "cortex-a8-far"} 663 {"Cortex-A8 erratum fix, headers" 664 "-EL --fix-cortex-a8 -T cortex-a8-fix-hdr.t" "" 665 "-EL -mcpu=cortex-a8" {cortex-a8-fix-hdr.s} 666 {{objdump -dr cortex-a8-fix-hdr.d}} 667 "cortex-a8-fix-hdr"} 668 {"Cortex-A8 erratum fix, blx.w and b<cond>.w together" 669 "-EL -Ttext=0x8f00 --fix-cortex-a8" "" "-EL" {cortex-a8-fix-blx-bcond.s} 670 {{objdump -dr cortex-a8-fix-blx-bcond.d}} 671 "cortex-a8-fix-blx-bcond"} 672 {"Cortex-A8 erratum fix, b.w to PLT" 673 "-EL -Tcortex-a8-fix-plt.ld --fix-cortex-a8 -shared" "" "-EL" 674 {cortex-a8-fix-b-plt.s} 675 {{objdump -dr cortex-a8-fix-b-plt.d}} 676 "cortex-a8-fix-b-plt"} 677 {"Cortex-A8 erratum fix, bl.w to PLT" 678 "-EL -Tcortex-a8-fix-plt.ld --fix-cortex-a8 -shared" "" "-EL" 679 {cortex-a8-fix-bl-plt.s} 680 {{objdump -dr cortex-a8-fix-bl-plt.d}} 681 "cortex-a8-fix-bl-plt"} 682 {"Cortex-A8 erratum fix, bcc.w to PLT" 683 "-EL -Tcortex-a8-fix-plt.ld --fix-cortex-a8 -shared" "" "-EL" 684 {cortex-a8-fix-bcc-plt.s} 685 {{objdump -dr cortex-a8-fix-bcc-plt.d}} 686 "cortex-a8-fix-bcc-plt"} 687 {"Cortex-A8 erratum fix, blx.w to PLT" 688 "-EL -Tcortex-a8-fix-plt.ld --fix-cortex-a8 -shared" "" "-EL" 689 {cortex-a8-fix-blx-plt.s} 690 {{objdump -dr cortex-a8-fix-blx-plt.d}} 691 "cortex-a8-fix-blx-plt"} 692 {"Cortex-A8 erratum fix, relocate bl.w to PLT" 693 "-EL --section-start=.plt=0x8e00 -Ttext=0x8f00 --fix-cortex-a8 -shared" "" 694 "-EL" {cortex-a8-thumb-target.s cortex-a8-fix-bl-rel.s} 695 {{objdump -dr cortex-a8-fix-bl-rel-plt.d}} 696 "cortex-a8-fix-bl-rel-thumb"} 697 {"IFUNC test 1" "-T ifunc-static.ld" "" "" {ifunc-1.s} 698 {{objdump -d ifunc-1.dd} 699 {objdump {-s -j.data -j.got} ifunc-1.gd} 700 {readelf -dr ifunc-1.rd}} 701 "ifunc-1"} 702 {"IFUNC test 2" "-T ifunc-static.ld" "" "" {ifunc-2.s} 703 {{objdump -d ifunc-2.dd} 704 {objdump {-s -j.data -j.got} ifunc-2.gd} 705 {readelf -dr ifunc-2.rd}} 706 "ifunc-2"} 707 {"IFUNC test 3" "-T ifunc-dynamic.ld -shared" "" "" {ifunc-3.s} 708 {{objdump -d ifunc-3.dd} 709 {objdump {-s -j.data -j.got} ifunc-3.gd} 710 {readelf -r ifunc-3.rd}} 711 "ifunc-3.so"} 712 {"IFUNC test 4" "-T ifunc-dynamic.ld -shared" "" "" {ifunc-4.s} 713 {{objdump -d ifunc-4.dd} 714 {objdump {-s -j.data -j.got} ifunc-4.gd} 715 {readelf -r ifunc-4.rd}} 716 "ifunc-4.so"} 717 {"IFUNC test 5" "-T ifunc-static.ld" "" "" {ifunc-5.s} 718 {{objdump -d ifunc-5.dd} 719 {objdump {-s -j.data -j.got} ifunc-5.gd} 720 {readelf -dr ifunc-5.rd}} 721 "ifunc-5"} 722 {"IFUNC test 6" "-T ifunc-static.ld" "" "" {ifunc-6.s} 723 {{objdump -d ifunc-6.dd} 724 {objdump {-s -j.data -j.got} ifunc-6.gd} 725 {readelf -dr ifunc-6.rd}} 726 "ifunc-6"} 727 {"IFUNC test 7" "-T ifunc-dynamic.ld tmpdir/ifunc-3.so -shared" "" 728 "" {ifunc-7.s} 729 {{objdump -d ifunc-7.dd} 730 {objdump {-s -j.data -j.got} ifunc-7.gd} 731 {readelf -r ifunc-7.rd}} 732 "ifunc-7.so"} 733 {"IFUNC test 8" "-T ifunc-dynamic.ld tmpdir/ifunc-4.so -shared" "" 734 "" {ifunc-8.s} 735 {{objdump -d ifunc-8.dd} 736 {objdump {-s -j.data -j.got} ifunc-8.gd} 737 {readelf -r ifunc-8.rd}} 738 "ifunc-8.so"} 739 {"IFUNC test 9" "-T ifunc-dynamic.ld tmpdir/ifunc-3.so" "" "" {ifunc-9.s} 740 {{objdump -d ifunc-9.dd} 741 {objdump {-s -j.data -j.got} ifunc-9.gd} 742 {readelf -r ifunc-9.rd}} 743 "ifunc-9"} 744 {"IFUNC test 10" "-T ifunc-dynamic.ld tmpdir/ifunc-4.so" "" "" {ifunc-10.s} 745 {{objdump -d ifunc-10.dd} 746 {objdump {-s -j.data -j.got} ifunc-10.gd} 747 {readelf -r ifunc-10.rd}} 748 "ifunc-10"} 749 {"IFUNC test 11" "-T ifunc-static.ld" "" "" {ifunc-11.s} 750 {{objdump -d ifunc-11.dd} 751 {objdump {-s -j.data -j.got} ifunc-11.gd} 752 {readelf -dr ifunc-11.rd}} 753 "ifunc-11"} 754 {"IFUNC test 12" "-T ifunc-dynamic.ld -shared" "" "" {ifunc-12.s} 755 {{objdump -d ifunc-12.dd} 756 {objdump {-s -j.data -j.got} ifunc-12.gd} 757 {readelf -r ifunc-12.rd}} 758 "ifunc-12.so"} 759 {"IFUNC test 13" "-T ifunc-dynamic.ld tmpdir/ifunc-12.so" "" "" {ifunc-13.s} 760 {{objdump -d ifunc-13.dd} 761 {objdump {-s -j.data -j.got} ifunc-13.gd} 762 {readelf -r ifunc-13.rd}} 763 "ifunc-13"} 764 {"IFUNC test 14" "-T ifunc-dynamic.ld tmpdir/ifunc-12.so" "" "" {ifunc-14.s} 765 {{objdump -d ifunc-14.dd} 766 {objdump {-s -j.data -j.got} ifunc-14.gd} 767 {readelf -r ifunc-14.rd}} 768 "ifunc-14"} 769 {"IFUNC test 15" "-T ifunc-dynamic.ld tmpdir/ifunc-12.so" "" "" {ifunc-15.s} 770 {{objdump -d ifunc-15.dd} 771 {objdump {-s -j.data -j.got} ifunc-15.gd} 772 {readelf -r ifunc-15.rd}} 773 "ifunc-15"} 774 {"IFUNC test 16" "-T ifunc-dynamic.ld tmpdir/ifunc-12.so" "" "" {ifunc-16.s} 775 {{objdump -d ifunc-16.dd} 776 {objdump {-s -j.data -j.got} ifunc-16.gd} 777 {readelf -r ifunc-16.rd}} 778 "ifunc-16"} 779 {"IFUNC test 17" "-T ifunc-static.ld" "" "" {ifunc-17.s} 780 {{objdump -d ifunc-17.dd} 781 {objdump {-s -j.data -j.got} ifunc-17.gd} 782 {readelf -r ifunc-17.rd}} 783 "ifunc-17"} 784 {"Long PLT entries in executables" "--long-plt -shared --section-start=.plt=0x1000 --section-start=.got=0xf0001100" "" 785 "" {long-plt-format.s} 786 {{objdump "-d -j .plt" long-plt-format.d}} 787 "long-plt-format"} 788 {"IFUNC and TLS descriptor shared library" "-shared -T arm-lib.ld --version-script=ifunc-gdesc.ver" "" "" {ifunc-gdesc.s} 789 {{objdump "-Rw" ifunc-gdesc.r}} 790 "ifunc-gdesc.so"} 791 {"arm-pic-veneer" "-static -T arm.ld --pic-veneer" "" "" {arm-pic-veneer.s} 792 {{objdump -d arm-pic-veneer.d}} 793 "arm-pic-veneer"} 794 {"Preempt Thumb symbol" "tmpdir/mixed-lib.so -T arm-dyn.ld --use-blx" "" "" 795 {preempt-app.s} 796 {{readelf -Ds preempt-app.sym}} 797 "preempt-app"} 798 } 799 800 # Massage the $armeabitests_common list into run_ld_link_tests standard form. 801 # See the comment before 'set armeabitests_common', above. 802 set elide_action_elt 3 803 set is_nacl [istarget "arm*-*-nacl*"] 804 if {$is_nacl} { 805 set elide_action_elt 2 806 } 807 set neabi_common [llength $armeabitests_common] 808 for {set i 0} {$i < $neabi_common} {incr i} { 809 set case [lindex $armeabitests_common $i] 810 set actions [lindex $case 5] 811 set nactions [llength $actions] 812 for {set j 0} {$j < $nactions} {incr j} { 813 set action [lindex $actions $j] 814 if {[llength $action] == 4} { 815 set action [lreplace $action $elide_action_elt $elide_action_elt] 816 lset armeabitests_common $i 5 $j $action 817 } 818 } 819 } 820 821 run_ld_link_tests $armeabitests_common 822 if { !$is_nacl } { 823 run_ld_link_tests $armeabitests_nonacl 824 } 825 826 run_dump_test "attr-merge-div-00" 827 run_dump_test "attr-merge-div-01" 828 run_dump_test "attr-merge-div-10" 829 run_dump_test "attr-merge-div-01-m3" 830 run_dump_test "attr-merge-div-10-m3" 831 run_dump_test "attr-merge-div-11" 832 run_dump_test "attr-merge-div-12" 833 run_dump_test "attr-merge-div-120" 834 run_dump_test "attr-merge-div-21" 835 run_dump_test "attr-merge-div-22" 836 run_dump_test "attr-merge-div-02" 837 run_dump_test "attr-merge-div-20" 838 run_dump_test "attr-merge-wchar-00" 839 run_dump_test "attr-merge-wchar-02" 840 run_dump_test "attr-merge-wchar-04" 841 run_dump_test "attr-merge-wchar-20" 842 run_dump_test "attr-merge-wchar-22" 843 run_dump_test "attr-merge-wchar-24" 844 run_dump_test "attr-merge-wchar-40" 845 run_dump_test "attr-merge-wchar-42" 846 run_dump_test "attr-merge-wchar-44" 847 run_dump_test "attr-merge-wchar-00-nowarn" 848 run_dump_test "attr-merge-wchar-02-nowarn" 849 run_dump_test "attr-merge-wchar-04-nowarn" 850 run_dump_test "attr-merge-wchar-20-nowarn" 851 run_dump_test "attr-merge-wchar-22-nowarn" 852 run_dump_test "attr-merge-wchar-24-nowarn" 853 run_dump_test "attr-merge-wchar-40-nowarn" 854 run_dump_test "attr-merge-wchar-42-nowarn" 855 run_dump_test "attr-merge-wchar-44-nowarn" 856 run_dump_test "farcall-section" 857 run_dump_test "attr-merge-unknown-1" 858 run_dump_test "attr-merge-unknown-2" 859 run_dump_test "attr-merge-unknown-2r" 860 run_dump_test "attr-merge-unknown-3" 861 run_dump_test "unwind-1" 862 run_dump_test "unwind-2" 863 run_dump_test "unwind-3" 864 run_dump_test "unwind-4" 865 run_dump_test "unwind-5" 866 run_dump_test "attr-merge-vfp-1" 867 run_dump_test "attr-merge-vfp-1r" 868 run_dump_test "attr-merge-vfp-2" 869 run_dump_test "attr-merge-vfp-2r" 870 run_dump_test "attr-merge-vfp-3" 871 run_dump_test "attr-merge-vfp-3r" 872 run_dump_test "attr-merge-vfp-4" 873 run_dump_test "attr-merge-vfp-4r" 874 run_dump_test "attr-merge-vfp-5" 875 run_dump_test "attr-merge-vfp-5r" 876 run_dump_test "attr-merge-vfp-6" 877 run_dump_test "attr-merge-vfp-6r" 878 run_dump_test "attr-merge-vfp-7" 879 run_dump_test "attr-merge-vfp-7r" 880 run_dump_test "attr-merge-incompatible" 881 run_dump_test "attr-merge-arch-2" 882 run_dump_test "unresolved-1" 883 if { ![istarget "arm*-*-nacl*"] } { 884 run_dump_test "unresolved-1-dyn" 885 } 886 run_dump_test "unresolved-2" 887 run_dump_test "gc-hidden-1" 888