diff options
author | Jan Beulich <jbeulich@novell.com> | 2017-11-23 11:02:30 +0100 |
---|---|---|
committer | Jan Beulich <jbeulich@suse.com> | 2017-11-23 11:02:30 +0100 |
commit | 43083a502b8d658b8d096111e54afcc73b0215a4 (patch) | |
tree | 0695c73e2bf6e60e243e0afcc023c7ef8fb96359 /gas/testsuite | |
parent | 9bb129e82f0506fe78d61670ea2b4140388955dd (diff) | |
download | gdb-43083a502b8d658b8d096111e54afcc73b0215a4.zip gdb-43083a502b8d658b8d096111e54afcc73b0215a4.tar.gz gdb-43083a502b8d658b8d096111e54afcc73b0215a4.tar.bz2 |
x86-64: always use unsigned 32-bit reloc for 32-bit addressing w/o base reg
Except for %eip-relative addressing, where we don't have a suitable
relocation type silently wrapping at the 4G boundary, consistently
force use of R_X86_64_32 (in ELF terms) instead of its sign-extending
counterpart. This wasn't right in case there was no base register in
the addressing expression.
Diffstat (limited to 'gas/testsuite')
-rw-r--r-- | gas/testsuite/gas/i386/reloc64.d | 4 | ||||
-rw-r--r-- | gas/testsuite/gas/i386/reloc64.s | 6 |
2 files changed, 10 insertions, 0 deletions
diff --git a/gas/testsuite/gas/i386/reloc64.d b/gas/testsuite/gas/i386/reloc64.d index ea7f696..a7fd3d6 100644 --- a/gas/testsuite/gas/i386/reloc64.d +++ b/gas/testsuite/gas/i386/reloc64.d @@ -51,6 +51,10 @@ Disassembly of section \.text: .*[ ]+R_X86_64_TPOFF32[ ]+xtrn .*[ ]+R_X86_64_TPOFF32[ ]+xtrn .*[ ]+R_X86_64_GOTPLT64[ ]+xtrn +.*[ ]+R_X86_64_32S[ ]+xtrn +.*[ ]+R_X86_64_32[ ]+xtrn +.*[ ]+R_X86_64_32S[ ]+xtrn +.*[ ]+R_X86_64_32[ ]+xtrn Disassembly of section \.data: #... .*[ ]+R_X86_64_64[ ]+xtrn diff --git a/gas/testsuite/gas/i386/reloc64.s b/gas/testsuite/gas/i386/reloc64.s index ecaaef5..0f9c51e 100644 --- a/gas/testsuite/gas/i386/reloc64.s +++ b/gas/testsuite/gas/i386/reloc64.s @@ -218,3 +218,9 @@ bad call xtrn@gotplt bad .long xtrn@gotplt bad .word xtrn@gotplt bad .byte xtrn@gotplt + + .text + mov xtrn(,%rbx), %eax + mov xtrn(,%ebx), %eax + vgatherdps %xmm2, xtrn(,%xmm1), %xmm0 + addr32 vgatherdps %xmm2, xtrn(,%xmm1), %xmm0 |