Correct ppc64elftests option replacement.
(supports_ppc64): Match elf64lppc too.
* ld-powerpc/relbrlt.d: Update for little-endian.
* ld-powerpc/symtocbase.d: Likewise.
* ld-powerpc/tls.t: Likewise.
* ld-powerpc/tlsexetoc.g: Likewise.
* ld-powerpc/tlsso.d: Likewise.
* ld-powerpc/tlsso.g: Likewise.
* ld-powerpc/tlstoc.t: Likewise.
* ld-powerpc/tlstocso.d: Likewise.
* ld-powerpc/tlstocso.g: Likewise.
* ld-powerpc/tlstocso.t: Likewise.
* ld-powerpc/tocopt.d: Likewise.
* ld-powerpc/tocopt2.d: Likewise.
* ld-powerpc/tocopt3.d: Likewise.
* ld-powerpc/tocopt4.d: Likewise.
* ld-powerpc/tocopt5.d: Likewise.
+2013-08-22 Alan Modra <amodra@gmail.com>
+
+ * ld-powerpc/powerpc.exp: Substitute for le in options_regsub(ld).
+ Correct ppc64elftests option replacement.
+ (supports_ppc64): Match elf64lppc too.
+ * ld-powerpc/relbrlt.d: Update for little-endian.
+ * ld-powerpc/symtocbase.d: Likewise.
+ * ld-powerpc/tls.t: Likewise.
+ * ld-powerpc/tlsexetoc.g: Likewise.
+ * ld-powerpc/tlsso.d: Likewise.
+ * ld-powerpc/tlsso.g: Likewise.
+ * ld-powerpc/tlstoc.t: Likewise.
+ * ld-powerpc/tlstocso.d: Likewise.
+ * ld-powerpc/tlstocso.g: Likewise.
+ * ld-powerpc/tlstocso.t: Likewise.
+ * ld-powerpc/tocopt.d: Likewise.
+ * ld-powerpc/tocopt2.d: Likewise.
+ * ld-powerpc/tocopt3.d: Likewise.
+ * ld-powerpc/tocopt4.d: Likewise.
+ * ld-powerpc/tocopt5.d: Likewise.
+
2013-08-14 Clemens Lang <clemens.lang@fau.de>
* ld-scripts/log2.exp: New: Run the new log2 test.
with regexp.
* ld-aarch64/ifunc-1.d: Likewise.
* ld-aarch64/ifunc-2-local.d: Likewise.
- * ld-aarch64/ifunc-2.d: Likewise.
+ * ld-aarch64/ifunc-2.d: Likewise.
* ld-aarch64/ifunc-3a.d: Likewise.
* ld-aarch64/ifunc-2-local.s: Change not to declare __GI_foo and foo
global.
global ld
catch "exec $ld --help | grep emulations" tmp
- if [ string match "*elf64ppc*" $tmp ] then {
+ if [ regexp "elf64l?ppc" $tmp ] then {
return 1
} else {
return 0
}
if [istarget "powerpc*le*-*-*"] then {
- set options_regsub(ld) {-melf32ppc -melf32lppc}
+ set options_regsub(ld) {{-melf([3264]*)ppc} {-melf\1lppc}}
for {set i 0} {$i < [llength $ppcelftests]} {incr i} {
set line [lindex $ppcelftests $i]
if [ supports_ppc64 ] then {
for {set i 0} {$i < [llength $ppc64elftests]} {incr i} {
- set line [lindex $ppcelftests $i]
+ set line [lindex $ppc64elftests $i]
set ld_options [lindex $line 1]
regsub -all elf64ppc $ld_options elf64lppc ld_options
set line [lreplace $line 1 1 $ld_options]
#ld: -melf64ppc --no-ld-generated-unwind-info --emit-relocs
#objdump: -Dr
-.*: file format elf64-powerpc
+.*
Disassembly of section \.text:
0*100000c0 <_start>:
-[0-9a-f ]*: 49 bf 00 2d bl .*
+[0-9a-f ]*: (49 bf 00 2d|2d 00 bf 49) bl .*
[0-9a-f ]*: R_PPC64_REL24 \.text\+0x37e003c
-[0-9a-f ]*: 60 00 00 00 nop
-[0-9a-f ]*: 49 bf 00 19 bl .*
+[0-9a-f ]*: (60 00 00 00|00 00 00 60) nop
+[0-9a-f ]*: (49 bf 00 19|19 00 bf 49) bl .*
[0-9a-f ]*: R_PPC64_REL24 \.text\+0x3bf0020
-[0-9a-f ]*: 60 00 00 00 nop
-[0-9a-f ]*: 49 bf 00 21 bl .*
+[0-9a-f ]*: (60 00 00 00|00 00 00 60) nop
+[0-9a-f ]*: (49 bf 00 21|21 00 bf 49) bl .*
[0-9a-f ]*: R_PPC64_REL24 \.text\+0x57e0024
-[0-9a-f ]*: 60 00 00 00 nop
+[0-9a-f ]*: (60 00 00 00|00 00 00 60) nop
[0-9a-f ]*: 00 00 00 00 \.long 0x0
-[0-9a-f ]*: 4b ff ff e4 b .* <_start>
+[0-9a-f ]*: (4b ff ff e4|e4 ff ff 4b) b .* <_start>
\.\.\.
[0-9a-f ]*<.*plt_branch.*>:
-[0-9a-f ]*: e9 62 80 00 ld r11,-32768\(r2\)
+[0-9a-f ]*: (e9 62 80 00|00 80 62 e9) ld r11,-32768\(r2\)
[0-9a-f ]*: R_PPC64_TOC16_DS \*ABS\*\+0x157f00e8
-[0-9a-f ]*: 7d 69 03 a6 mtctr r11
-[0-9a-f ]*: 4e 80 04 20 bctr
+[0-9a-f ]*: (7d 69 03 a6|a6 03 69 7d) mtctr r11
+[0-9a-f ]*: (4e 80 04 20|20 04 80 4e) bctr
[0-9a-f ]*<.*long_branch.*>:
-[0-9a-f ]*: 49 bf 00 10 b .* <far>
+[0-9a-f ]*: (49 bf 00 10|10 00 bf 49) b .* <far>
[0-9a-f ]*: R_PPC64_REL24 \*ABS\*\+0x137e00fc
[0-9a-f ]*<.*plt_branch.*>:
-[0-9a-f ]*: e9 62 80 08 ld r11,-32760\(r2\)
+[0-9a-f ]*: (e9 62 80 08|08 80 62 e9) ld r11,-32760\(r2\)
[0-9a-f ]*: R_PPC64_TOC16_DS \*ABS\*\+0x157f00f0
-[0-9a-f ]*: 7d 69 03 a6 mtctr r11
-[0-9a-f ]*: 4e 80 04 20 bctr
+[0-9a-f ]*: (7d 69 03 a6|a6 03 69 7d) mtctr r11
+[0-9a-f ]*: (4e 80 04 20|20 04 80 4e) bctr
\.\.\.
0*137e00fc <far>:
-[0-9a-f ]*: 4e 80 00 20 blr
+[0-9a-f ]*: (4e 80 00 20|20 00 80 4e) blr
\.\.\.
0*13bf00e0 <far2far>:
-[0-9a-f ]*: 4e 80 00 20 blr
+[0-9a-f ]*: (4e 80 00 20|20 00 80 4e) blr
\.\.\.
0*157e00e4 <huge>:
-[0-9a-f ]*: 4e 80 00 20 blr
+[0-9a-f ]*: (4e 80 00 20|20 00 80 4e) blr
Disassembly of section \.branch_lt:
0*157f00e8 .*:
-[0-9a-f ]*: 00 00 00 00 .*
+[0-9a-f ]*: (00 00 00 00|e0 00 bf 13) .*
[0-9a-f ]*: R_PPC64_RELATIVE \*ABS\*\+0x13bf00e0
-[0-9a-f ]*: 13 bf 00 e0 .*
-[0-9a-f ]*: 00 00 00 00 .*
+[0-9a-f ]*: (13 bf 00 e0|00 00 00 00) .*
+[0-9a-f ]*: (00 00 00 00|e4 00 7e 15) .*
[0-9a-f ]*: R_PPC64_RELATIVE \*ABS\*\+0x157e00e4
-[0-9a-f ]*: 15 7e 00 e4 .*
+[0-9a-f ]*: (15 7e 00 e4|00 00 00 00) .*
#source: symtocbase-2.s
#as: -a64
#ld: -shared -melf64ppc
-#objdump: -dj.data
+#objdump: -dj.data -z
#target: powerpc64*-*-*
-.*: file format elf64-powerpc
+.*
Disassembly of section \.data:
.* <i>:
- \.\.\.
-.*: 00 02 80 00 \.long 0x28000
-.*: 00 00 00 00 \.long 0x0
-.*: 00 02 80 00 \.long 0x28000
-.*: 00 00 00 00 \.long 0x0
-.*: 00 03 80 00 \.long 0x38000
-.*: 00 00 00 00 \.long 0x0
-.*: 00 03 80 00 \.long 0x38000
-.*: 00 00 00 00 \.long 0x0
-.*: 00 02 80 00 \.long 0x28000
-.*: 00 00 00 00 \.long 0x0
-.*: 00 03 80 00 \.long 0x38000
+#...
+.* \.long 0x28000
+.* \.long 0x0
+.* \.long 0x28000
+.* \.long 0x0
+.* \.long 0x38000
+.* \.long 0x0
+.* \.long 0x38000
+.* \.long 0x0
+.* \.long 0x28000
+.* \.long 0x0
+.* \.long 0x38000
+#pass
#objdump: -sj.tdata
#target: powerpc64*-*-*
-.*: +file format elf64-powerpc
+.*
Contents of section \.tdata:
.* (12345678|f0debc9a) (9abcdef0|78563412) (23456789|01efcdab) (abcdef01|89674523) .*
#objdump: -sj.got
#target: powerpc64*-*-*
-.*: +file format elf64-powerpc
+.*
Contents of section \.got:
.* (00000000|c0850110) (100185c0|00000000) 00000000 00000000 .*
#objdump: -dr
#target: powerpc64*-*-*
-.*: +file format elf64-powerpc
+.*
Disassembly of section \.text:
#objdump: -sj.got
#target: powerpc64*-*-*
-.*: +file format elf64-powerpc
+.*
Contents of section \.got:
10788 (00000000|88870100) (00018788|00000000) 00000000 00000000 .*
.*
Contents of section \.tdata:
- 10010148 (00c0ffee|eeffc000) 00000000 (12345678|78563412) (9abcdef0|f0debc9a) .*
- 10010158 (23456789|89674523) (abcdef01|01efcdab) (3456789a|9a785634) (bcdef012|12f0debc) .*
- 10010168 (456789ab|ab896745) (cdef0123|2301efcd) (56789abc|bc9a7856) (def01234|3412f0de) .*
- 10010178 (6789abcd|cdab8967) (ef012345|452301ef) (789abcde|debc9a78) (f0123456|563412f0) .*
+ 10010148 (00c0ffee|eeffc000) 00000000 (12345678|f0debc9a) (9abcdef0|78563412) .*
+ 10010158 (23456789|01efcdab) (abcdef01|89674523) (3456789a|12f0debc) (bcdef012|9a785634) .*
+ 10010168 (456789ab|2301efcd) (cdef0123|ab896745) (56789abc|3412f0de) (def01234|bc9a7856) .*
+ 10010178 (6789abcd|452301ef) (ef012345|cdab8967) (789abcde|563412f0) (f0123456|debc9a78) .*
#objdump: -dr
#target: powerpc64*-*-*
-.*: +file format elf64-powerpc
+.*
Disassembly of section \.text:
.*
Contents of section \.got:
- 106c8 00000000 (000186c8|c8860100) 00000000 00000000 .*
+ 106c8 (00000000|c8860100) (000186c8|00000000) 00000000 00000000 .*
.* 00000000 00000000 00000000 00000000 .*
.* 00000000 00000000 00000000 00000000 .*
.* 00000000 00000000 00000000 00000000 .*
.*
Contents of section \.tdata:
-.* (12345678|78563412) (9abcdef0|f0debc9a) (23456789|89674523) (abcdef01|01efcdab) .*
-.* (3456789a|9a785634) (bcdef012|12f0debc) (456789ab|ab896745) (cdef0123|2301efcd) .*
-.* (56789abc|bc9a7856) (def01234|3412f0de) (6789abcd|cdab8967) (ef012345|452301ef) .*
-.* (789abcde|debc9a78) (f0123456|563412f0) .*
+.* (12345678|f0debc9a) (9abcdef0|78563412) (23456789|01efcdab) (abcdef01|89674523) .*
+.* (3456789a|12f0debc) (bcdef012|9a785634) (456789ab|2301efcd) (cdef0123|ab896745) .*
+.* (56789abc|3412f0de) (def01234|bc9a7856) (6789abcd|452301ef) (ef012345|cdab8967) .*
+.* (789abcde|563412f0) (f0123456|debc9a78) .*
.*: file format .*
Contents of section \.text:
- 100000b0 3d220000 e9298018 3c820000 38a48020 .*
- 100000c0 e8c50000 3fa00000 3bbd8028 7c62e82a .*
- 100000d0 3d220000 39298033 3c820000 38a48008 .*
- 100000e0 e8c50000 3fa00000 3bbd8010 7c62e82a .*
+ 100000b0 (3d220000|0000223d) (e9298018|188029e9) (3c820000|0000823c) (38a48020|2080a438) .*
+ 100000c0 (e8c50000|0000c5e8) (3fa00000|0000a03f) (3bbd8028|2880bd3b) (7c62e82a|2ae8627c) .*
+ 100000d0 (3d220000|0000223d) (39298033|33802939) (3c820000|0000823c) (38a48008|0880a438) .*
+ 100000e0 (e8c50000|0000c5e8) (3fa00000|0000a03f) (3bbd8010|1080bd3b) (7c62e82a|2ae8627c) .*
Contents of section \.got:
- 100100f0 00000000 100180f0 00000000 10010124 .*
- 10010100 00000000 10010125 00000000 10010120 .*
- 10010110 00000000 10010121 00000000 10010122 .*
+ 100100f0 (00000000|f0800110) (100180f0|00000000) (00000000|24010110) (10010124|00000000) .*
+ 10010100 (00000000|25010110) (10010125|00000000) (00000000|20010110) (10010120|00000000) .*
+ 10010110 (00000000|21010110) (10010121|00000000) (00000000|22010110) (10010122|00000000) .*
Contents of section \.sdata:
10010120 01020304 0506 .*
.*: file format .*
Contents of section \.text:
- 100000b0 3d22effe 39297f4a .*
+ 100000b0 (3d22effe|feef223d) (39297f4a|4a7f2939) .*
.*: file format .*
Contents of section \.text:
- 100000b0 3d22effe 39297f4a .*
+ 100000b0 (3d22effe|feef223d) (39297f4a|4a7f2939) .*
.*: file format .*
Contents of section \.text:
- 100000b0 e9298000 .*
+ 100000b0 (e9298000|008029e9) .*
Contents of section \.got:
- 100100b8 00000000 00000002 .*
+ 100100b8 (00000000|02000000) (00000002|00000000) .*
.*: file format .*
Contents of section \.text:
- 100000b0 60000000 e9228018 60000000 38a28020 .*
- 100000c0 e8c50000 60000000 3922802b 60000000 .*
- 100000d0 38a28008 e8c50000 .*
+ 100000b0 (60000000|00000060) (e9228018|188022e9) (60000000|00000060) (38a28020|2080a238) .*
+ 100000c0 (e8c50000|0000c5e8) (60000000|00000060) (3922802b|2b802239) (60000000|00000060) .*
+ 100000d0 (38a28008|0880a238) (e8c50000|0000c5e8) .*
Contents of section \.got:
- 100100d8 00000000 100180d8 00000000 10010104 .*
- 100100e8 00000000 10010105 00000000 10010100 .*
- 100100f8 00000000 10010101 .*
+ 100100d8 (00000000|d8800110) (100180d8|00000000) (00000000|04010110) (10010104|00000000) .*
+ 100100e8 (00000000|05010110) (10010105|00000000) (00000000|00010110) (10010100|00000000) .*
+ 100100f8 (00000000|01010110) (10010101|00000000) .*
Contents of section \.sdata:
10010100 01020304 0506 .*