[PATCH] x86: adjust relocation overflow complaint types

Andreas Schwab schwab@suse.de
Mon Aug 1 18:48:00 GMT 2005

Ian Lance Taylor <ian@airs.com> writes:

> I think that by that argument we also shouldn't use BFD_RELOC_32_PCREL
> for the 32-bit PC relative relocation, because it also doesn't use
> complain_overflow_signed.

IMHO in the context of a 32 bit format this is ok, but would be wrong in a
64 bit format.

> I'm not actually sure the internal reloc number used by BFD makes any
> difference, but if it does, then perhaps it should indeed be changed.

At least it should be consistent.  For example, the m68k equivalent for
BFD_RELOC_16_PCREL (R_68K_PC16) doesn't have such a weird semantics and
letting it wrap in 16 bits would be a bug.  But maybe the semantics of the
generic relocations is supposed to be completely target defined.

In any case it would be nice to document the proper semantics of the
relocations, especially the GNU extensions that are not defined elsewhere.


Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."

More information about the Binutils mailing list