Update x86-64 no-PLT tests for x32
authorH.J. Lu <hjl.tools@gmail.com>
Sun, 12 Jun 2016 14:28:58 +0000 (07:28 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Sun, 12 Jun 2016 14:28:58 +0000 (07:28 -0700)
X32 has different output formats for readelf and objdump as well as a
different conversion of load symbol address via GOT.

* testsuite/ld-x86-64/libno-plt-1b.dd: Updated for x32.
* testsuite/ld-x86-64/libno-plt-1b.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1a.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1a.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1b.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1b.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1c.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1c.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1d.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1e.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1e.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1f.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1f.rd: Likewise.
* testsuite/ld-x86-64/no-plt-1g.dd: Likewise.
* testsuite/ld-x86-64/no-plt-1g.rd: Likewise.

16 files changed:
ld/ChangeLog
ld/testsuite/ld-x86-64/libno-plt-1b.dd
ld/testsuite/ld-x86-64/libno-plt-1b.rd
ld/testsuite/ld-x86-64/no-plt-1a.dd
ld/testsuite/ld-x86-64/no-plt-1a.rd
ld/testsuite/ld-x86-64/no-plt-1b.dd
ld/testsuite/ld-x86-64/no-plt-1b.rd
ld/testsuite/ld-x86-64/no-plt-1c.dd
ld/testsuite/ld-x86-64/no-plt-1c.rd
ld/testsuite/ld-x86-64/no-plt-1d.dd
ld/testsuite/ld-x86-64/no-plt-1e.dd
ld/testsuite/ld-x86-64/no-plt-1e.rd
ld/testsuite/ld-x86-64/no-plt-1f.dd
ld/testsuite/ld-x86-64/no-plt-1f.rd
ld/testsuite/ld-x86-64/no-plt-1g.dd
ld/testsuite/ld-x86-64/no-plt-1g.rd

index 4a74c8f..05f490a 100644 (file)
@@ -1,3 +1,21 @@
+2016-06-12  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * testsuite/ld-x86-64/libno-plt-1b.dd: Updated for x32.
+       * testsuite/ld-x86-64/libno-plt-1b.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1a.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1a.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1b.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1b.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1c.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1c.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1d.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1e.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1e.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1f.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1f.rd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1g.dd: Likewise.
+       * testsuite/ld-x86-64/no-plt-1g.rd: Likewise.
+
 2016-06-11  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR ld/20244
index c58ede4..2892ce4 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index fa415fd..954e4a5 100644 (file)
@@ -2,7 +2,7 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ func \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +func \+ 0
 #pass
index 81b62b0..b2721e3 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
@@ -23,7 +23,7 @@ Disassembly of section .text:
  +[a-f0-9]+:   ff 15 ([0-9a-f]{2} ){4}[        ]+callq  \*0x[0-9a-f]+\(%rip\) +# [0-9a-f]+ <_DYNAMIC\+0x[0-9a-f]+>
 #...
 [0-9a-f]+ <get_func>:
- +[a-f0-9]+:   48 c7 c0 ([0-9a-f]{2} ){4}[     ]+mov    \$0x[0-9a-f]+,%rax
+ +[a-f0-9]+:   4(0|8) c7 c0 ([0-9a-f]{2} ){4}[         ]+(rex |)mov +\$0x[0-9a-f]+,%(e|r)ax
  +[a-f0-9]+:   c3                      retq   
 #...
 [0-9a-f]+ <call_func>:
index 78c2a75..7336534 100644 (file)
@@ -2,9 +2,9 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort|puts).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort|puts).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort|puts).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort|puts).* \+ 0
 #pass
index 5662a2f..ccdc489 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index 19833b9..3e6ad0a 100644 (file)
@@ -2,15 +2,15 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #pass
index 197359e..2e09a60 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index ebfea3b..2c9ef0c 100644 (file)
@@ -2,13 +2,13 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #pass
index 375de61..1920a13 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
@@ -24,7 +24,7 @@ Disassembly of section .text:
  +[a-f0-9]+:   67 e8 ([0-9a-f]{2} ){4}[        ]+addr32 callq [0-9a-f]+ <abort>
 #...
 [0-9a-f]+ <get_func>:
- +[a-f0-9]+:   48 c7 c0 ([0-9a-f]{2} ){4}[     ]+mov    \$0x[0-9a-f]+,%rax
+ +[a-f0-9]+:   4(0|8) c7 c0 ([0-9a-f]{2} ){4}[         ]+(rex |)mov +\$0x[0-9a-f]+,%(e|r)ax
  +[a-f0-9]+:   c3                      retq   
 #...
 [0-9a-f]+ <call_func>:
index c4b948d..b0342de 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index 78c2a75..7336534 100644 (file)
@@ -2,9 +2,9 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort|puts).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort|puts).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort|puts).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort|puts).* \+ 0
 #pass
index 5662a2f..ccdc489 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index 19833b9..3e6ad0a 100644 (file)
@@ -2,15 +2,15 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func|func) \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func|func) \+ 0
 #pass
index 00ae97b..0c97097 100644 (file)
@@ -1,7 +1,7 @@
 #objdump: -dwrj.text
 #target: x86_64-*-*
 
-.*: +file format elf64-x86-64.*
+.*: +file format elf.*-x86-64.*
 
 Disassembly of section .text:
 
index ebfea3b..2c9ef0c 100644 (file)
@@ -2,13 +2,13 @@
 #target: x86_64-*-*
 
 Relocation section '.rela.dyn' at offset 0x[0-9a-f]+ contains [0-9]+ entries:
- +Offset +Info +Type +Symbol's Value +Symbol's Name \+ Addend
+ +Offset +Info +Type +Sym.* Value +Symbol's Name \+ Addend
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #...
-[0-9a-f ]+R_X86_64_GLOB_DAT +0+ (abort.*|puts.*|get_func|call_func).* \+ 0
+[0-9a-f ]+R_X86_64_GLOB_DAT +0+ +(abort.*|puts.*|get_func|call_func).* \+ 0
 #pass