[Bug ld/23189] bad symbol index: ffffffff

2018-05-21 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

H.J. Lu  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED
   Target Milestone|--- |2.31

--- Comment #7 from H.J. Lu  ---
Fixed for 2.31 and on 2.30 branch.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-21 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

--- Comment #6 from cvs-commit at gcc dot gnu.org  ---
The binutils-2_30-branch branch has been updated by H.J. Lu
:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=19dd615652084b2bfd81a0497864e193608037a0

commit 19dd615652084b2bfd81a0497864e193608037a0
Author: H.J. Lu 
Date:   Fri May 18 06:43:19 2018 -0700

x86: Don't set eh->local_ref to 1 for linker defined symbols

Since symbols created by HIDDEN and PROVIDE_HIDDEN assignments in
linker script may be marked as defined, but not hidden, we can't
set eh->local_ref to 1 in _bfd_x86_elf_link_symbol_references_local.

Also R_386_GOT32X should be handled as just like R_386_GOT32 when
relocating a section.  The input R_386_GOT32X relocations, which
can be relaxed, should have been converted to R_386_PC32, R_386_32
or R_386_GOTOFF.

bfd/

PR ld/23189
* elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
like R_386_GOT32.
* elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
set eh->local_ref to 1 for linker defined symbols.

ld/

PR ld/23189
* testsuite/ld-i386/i386.exp: Run pr23189.
* testsuite/ld-x86-64/x86-64.exp: Likewise.
* testsuite/ld-i386/pr23189.d: New file.
* testsuite/ld-i386/pr23189.s: Likewise.
* testsuite/ld-i386/pr23189.t: Likewise.
* testsuite/ld-x86-64/pr23189.d: Likewise.
* testsuite/ld-x86-64/pr23189.s: Likewise.
* testsuite/ld-x86-64/pr23189.t: Likewise.

(cherry picked from commit 011b32fd4270fb7111ee1f63695ccd44562ee7df)

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-18 Thread cvs-commit at gcc dot gnu.org
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

--- Comment #5 from cvs-commit at gcc dot gnu.org  ---
The master branch has been updated by H.J. Lu :

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=011b32fd4270fb7111ee1f63695ccd44562ee7df

commit 011b32fd4270fb7111ee1f63695ccd44562ee7df
Author: H.J. Lu 
Date:   Fri May 18 06:43:19 2018 -0700

x86: Don't set eh->local_ref to 1 for linker defined symbols

Since symbols created by HIDDEN and PROVIDE_HIDDEN assignments in
linker script may be marked as defined, but not hidden, we can't
set eh->local_ref to 1 in _bfd_x86_elf_link_symbol_references_local.

Also R_386_GOT32X should be handled as just like R_386_GOT32 when
relocating a section.  The input R_386_GOT32X relocations, which
can be relaxed, should have been converted to R_386_PC32, R_386_32
or R_386_GOTOFF.

bfd/

PR ld/23189
* elf32-i386.c (elf_i386_relocate_section): Handle R_386_GOT32X
like R_386_GOT32.
* elfxx-x86.c (_bfd_x86_elf_link_symbol_references_local): Don't
set eh->local_ref to 1 for linker defined symbols.

ld/

PR ld/23189
* testsuite/ld-i386/i386.exp: Run pr23189.
* testsuite/ld-x86-64/x86-64.exp: Likewise.
* testsuite/ld-i386/pr23189.d: New file.
* testsuite/ld-i386/pr23189.s: Likewise.
* testsuite/ld-i386/pr23189.t: Likewise.
* testsuite/ld-x86-64/pr23189.d: Likewise.
* testsuite/ld-x86-64/pr23189.s: Likewise.
* testsuite/ld-x86-64/pr23189.t: Likewise.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-17 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

--- Comment #4 from H.J. Lu  ---
A patch is posted at

https://sourceware.org/ml/binutils/2018-05/msg00182.html

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-17 Thread hjl.tools at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

H.J. Lu  changed:

   What|Removed |Added

 Status|UNCONFIRMED |ASSIGNED
   Last reconfirmed||2018-05-17
   Assignee|unassigned at sourceware dot org   |hjl.tools at gmail dot 
com
 Ever confirmed|0   |1

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-17 Thread pangbw at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

--- Comment #3 from Baoshan  ---
I checked a little bit of the code, what I see for this issue the difference
between 2.29 and 2.30 is that:
For 2.29 the checking if a symbol is hidden is before the calling of function
elf_x86_64_convert_load_reloc, but in 2.30 they are in opposite order.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-17 Thread pangbw at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

--- Comment #2 from Baoshan  ---
(In reply to Nick Clifton from comment #1)
> Hi Baoshan,
> 
>   I cannot reproduce this problem using today's mainline development
>   sources.  Please could you check and see if the problem still exists
>   for you ?
> 
> Cheers
>   Nick

Hi Nick,

I don't see any difference with the mainline development sources, I am using
the code from: git://sourceware.org/git/binutils-gdb.git

Can you reproduce the issue with 2.30?

Thanks,
Baoshan

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-17 Thread nickc at redhat dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

Nick Clifton  changed:

   What|Removed |Added

 CC||nickc at redhat dot com

--- Comment #1 from Nick Clifton  ---
Hi Baoshan,

  I cannot reproduce this problem using today's mainline development
  sources.  Please could you check and see if the problem still exists
  for you ?

Cheers
  Nick

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils


[Bug ld/23189] bad symbol index: ffffffff

2018-05-16 Thread pangbw at gmail dot com
https://sourceware.org/bugzilla/show_bug.cgi?id=23189

Baoshan  changed:

   What|Removed |Added

 CC||pangbw at gmail dot com

-- 
You are receiving this mail because:
You are on the CC list for the bug.
___
bug-binutils mailing list
bug-binutils@gnu.org
https://lists.gnu.org/mailman/listinfo/bug-binutils