Browse Source
bfd/ PR ld/17306 * elf32-i386.c (elf_i386_convert_mov_to_lea): Use bfd_is_abs_section to check discarded input section. * elf64-x86-64.c (elf_x86_64_convert_mov_to_lea): Likewise. ld/testsuite/ PR ld/17306 * ld-i386/i386.exp (i386tests): Add tests for PR ld/17306. * ld-x86-64/x86-64.exp (x86_64tests): Likewise. * ld-i386/pr17306a.s: New file. * ld-i386/pr17306b.s: Likewise. * ld-x86-64/pr17306a.s: Likewise. * ld-x86-64/pr17306b.s: Likewise.binutils-2_25-branch
10 changed files with 50 additions and 2 deletions
@ -0,0 +1,9 @@ |
|||
.data |
|||
.globl foo |
|||
foo: |
|||
.long -1 |
|||
.text |
|||
.globl _start |
|||
.type _start, @function |
|||
_start: |
|||
pushl foo@GOT(%ebx) |
|||
@ -0,0 +1,2 @@ |
|||
.text |
|||
movl foo@GOT(%ebx), %eax |
|||
@ -0,0 +1,9 @@ |
|||
.data |
|||
.globl foo |
|||
foo: |
|||
.quad -1 |
|||
.text |
|||
.globl _start |
|||
.type _start, @function |
|||
_start: |
|||
pushq foo@GOTPCREL(%rip) |
|||
@ -0,0 +1,2 @@ |
|||
.text |
|||
movq foo@GOTPCREL(%rip), %rax |
|||
Loading…
Reference in new issue