https://sourceware.org/bugzilla/show_bug.cgi?id=22791
H.J. Lu <hjl.tools at gmail dot com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Target| |x86-64
Status|UNCONFIRMED |NEW
Last reconfirmed| |2018-02-07
Component|gold |gas
Version|unspecified |2.31 (HEAD)
Assignee|ccoutant at gmail dot com |unassigned at
sourceware dot org
Summary|Don't error when a -pie |PLT32 should be used for
|executable uses a shared |32-bit PC-relative branches
|function without PIC/PIE |
|relocation |
Ever confirmed|0 |1
--- Comment #15 from H.J. Lu <hjl.tools at gmail dot com> ---
On i386, there are 2 types of PLTs, PIC and non-PIC. PIE and shared objects
must use PIC PLT. To use PIC PLT, you need to load _GLOBAL_OFFSET_TABLE_
into EBX first. There is no need for that on x86-64 since x86-64 uses
PC-relative PLT.
For 32-bit PC-relative branches, we can generate PLT32 relocation, instead of
PC32 relocation, which can also be used as a marker for 32-bit PC-relative
branches. Linker can always reduce PLT32 relocation to PC32 if function is
defined locally. Local functions should use PC32 relocation.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
bug-binutils mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/bug-binutils