aboutsummaryrefslogtreecommitdiff
path: root/gas/testsuite
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2020-07-19 06:51:19 -0700
committerH.J. Lu <hjl.tools@gmail.com>2020-07-19 06:51:32 -0700
commit2585b7a5ce5830e60a089aa2316a329558902f0c (patch)
tree6ff218fb5b0fe5ad80a2cdabd0aa909416e0a6a2 /gas/testsuite
parent4609ada49f559880e85aecc2f37f377e5bff8696 (diff)
downloadgdb-2585b7a5ce5830e60a089aa2316a329558902f0c.zip
gdb-2585b7a5ce5830e60a089aa2316a329558902f0c.tar.gz
gdb-2585b7a5ce5830e60a089aa2316a329558902f0c.tar.bz2
x86: Change PLT32 reloc against section to PC32
Commit 292676c1 resolved PLT32 reloc aganst local symbol to section. Since PLT32 relocation must be against symbols, turn such PLT32 relocation into PC32 relocation. gas/ PR gas/26263 * config/tc-i386.c (i386_validate_fix): Change PLT32 reloc against section to PC32 reloc. * testsuite/gas/i386/relax-5.d: Updated. * testsuite/gas/i386/x86-64-relax-4.d: Likewise. ld/ PR gas/26263 * testsuite/ld-i386/i386.exp: Run PR gas/26263 test. * testsuite/ld-x86-64/x86-64.exp: Likewise. * testsuite/ld-i386/pr26263.d: New file. * testsuite/ld-x86-64/pr26263.d: Likewise. * testsuite/ld-x86-64/pr26263.s: Likewise.
Diffstat (limited to 'gas/testsuite')
-rw-r--r--gas/testsuite/gas/i386/relax-5.d2
-rw-r--r--gas/testsuite/gas/i386/x86-64-relax-4.d2
2 files changed, 2 insertions, 2 deletions
diff --git a/gas/testsuite/gas/i386/relax-5.d b/gas/testsuite/gas/i386/relax-5.d
index bccfe68..c377133 100644
--- a/gas/testsuite/gas/i386/relax-5.d
+++ b/gas/testsuite/gas/i386/relax-5.d
@@ -10,6 +10,6 @@ Disassembly of section .text:
Disassembly of section .init.text:
0+ <foo>:
- +[a-f0-9]+: e8 fb ff ff ff call 0 <foo> 1: R_386_PLT32 .text
+ +[a-f0-9]+: e8 fc ff ff ff call 1 <foo\+0x1> 1: R_386_PC32 .text
+[a-f0-9]+: e8 fc ff ff ff call 6 <foo\+0x6> 6: R_386_PC32 .text
#pass
diff --git a/gas/testsuite/gas/i386/x86-64-relax-4.d b/gas/testsuite/gas/i386/x86-64-relax-4.d
index 594f95a..ca12c03 100644
--- a/gas/testsuite/gas/i386/x86-64-relax-4.d
+++ b/gas/testsuite/gas/i386/x86-64-relax-4.d
@@ -12,6 +12,6 @@ Disassembly of section .text:
Disassembly of section .init.text:
0+ <foo>:
- +[a-f0-9]+: e8 00 00 00 00 call 5 <foo\+0x5> 1: R_X86_64_PLT32 .text-0x4
+ +[a-f0-9]+: e8 00 00 00 00 call 5 <foo\+0x5> 1: R_X86_64_PC32 .text-0x4
+[a-f0-9]+: 48 8d 05 00 00 00 00 lea 0x0\(%rip\),%rax # c <foo\+0xc> 8: R_X86_64_PC32 .text-0x4
#pass