]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
x86: Update PR gas/26263 linker tests
authorH.J. Lu <hjl.tools@gmail.com>
Mon, 20 Jul 2020 11:53:58 +0000 (04:53 -0700)
committerH.J. Lu <hjl.tools@gmail.com>
Mon, 20 Jul 2020 12:02:51 +0000 (05:02 -0700)
Update and run PR gas/26263 linker tests for all x86 ELF targets to
accept any program header layout.

PR gas/26263
* testsuite/ld-i386/pr26263.d: Updated.
* testsuite/ld-x86-64/pr26263.d: Likewise.
* testsuite/ld-x86-64/x86-64.exp: Run gas/26263 test for all ELF
targets.

(cherry picked from commit 98b3697bcdedb92739d8feb9b881efdd70fd40d3)

ld/ChangeLog
ld/testsuite/ld-i386/pr26263.d
ld/testsuite/ld-x86-64/pr26263.d
ld/testsuite/ld-x86-64/x86-64.exp

index 3a8becc317d22ae38e6a10d1c79879c6aafb3707..c7afa66cc5d41e61105f2dd444103bf48d9b1868 100644 (file)
@@ -1,3 +1,11 @@
+2020-07-20  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR gas/26263
+       * testsuite/ld-i386/pr26263.d: Updated.
+       * testsuite/ld-x86-64/pr26263.d: Likewise.
+       * testsuite/ld-x86-64/x86-64.exp: Run gas/26263 test for all ELF
+       targets.
+
 2020-07-19  H.J. Lu  <hongjiu.lu@intel.com>
 
        PR gas/26263
index 8cf7c15a66cbb55065bb47f2f8587f6980e11b2e..e6874e25c340a4ce3065fd24d81fe343c9d54f57 100644 (file)
@@ -8,12 +8,12 @@
 
 Disassembly of section .text:
 
-0+1000 <printk>:
+0+[a-f0-9]+ <printk>:
  +[a-f0-9]+:   c3                      ret    
 
 Disassembly of section .init.text:
 
-0+1001 <foo>:
- +[a-f0-9]+:   e8 fa ff ff ff          call   1000 <printk>
- +[a-f0-9]+:   e8 f5 ff ff ff          call   1000 <printk>
+0+[a-f0-9]+ <foo>:
+ +[a-f0-9]+:   e8 ([0-9a-f]{2} ){4}            call   [a-f0-9]+ <printk>
+ +[a-f0-9]+:   e8 ([0-9a-f]{2} ){4}            call   [a-f0-9]+ <printk>
 #pass
index afa96b3a2b18fc15f40f3c7fae3177bd79a2f5a2..e18ef55b621378d3b2236659a6a1fd958281f9fa 100644 (file)
@@ -7,12 +7,12 @@
 
 Disassembly of section .text:
 
-0+1000 <printk>:
+0+[a-f0-9]+ <printk>:
  +[a-f0-9]+:   c3                      retq   
 
 Disassembly of section .init.text:
 
-0+1001 <foo>:
- +[a-f0-9]+:   e8 fa ff ff ff          callq  1000 <printk>
- +[a-f0-9]+:   e8 f5 ff ff ff          callq  1000 <printk>
+0+[a-f0-9]+ <foo>:
+ +[a-f0-9]+:   e8 ([0-9a-f]{2} ){4}            callq  [a-f0-9]+ <printk>
+ +[a-f0-9]+:   e8 ([0-9a-f]{2} ){4}            callq  [a-f0-9]+ <printk>
 #pass
index 21aa6a06effdb87a1a7208cac39b9b23d66c0b35..d836f334963bf55c82ea63ac90edce824ec8cae5 100644 (file)
@@ -431,6 +431,7 @@ run_dump_test "pr25416-2b"
 run_dump_test "pr25416-3"
 run_dump_test "pr25416-4"
 run_dump_test "pr26018"
+run_dump_test "pr26263"
 
 if ![istarget "x86_64-*-linux*"] {
     return
@@ -640,7 +641,6 @@ run_dump_test "pr20253-5b"
 run_dump_test "tlsdesc2"
 run_dump_test "pr22048"
 run_dump_test "pr22929"
-run_dump_test "pr26263"
 
 proc undefined_weak {cflags ldflags} {
     set testname "Undefined weak symbol"