This is the mail archive of the
mailing list for the binutils project.
Re: [PATCH][MIPS] Add linker emulation for N64 ABI with forced 32-bit symbols
On Nov 18, 2012, at 3:41 AM, Richard Sandiford wrote:
> Matt Thomas <email@example.com> writes:
>> On Nov 15, 2012, at 2:08 PM, Richard Sandiford wrote:
>>> Huh. I'm very much against the original change to the n64 TEXT_START_ADDR.
>>> See this previous discussion on the topic:
>>> The justification for changing TEXT_START_ADDR from a 32-bit value to a
>>> larger value was that it would show users if their code was non-portable,
>>> because anything that assumed 32-bit addresses would now fault. But that
>>> seems to me like the tools lecturing to the user. As I said in that thread,
>>> I think users who want to smoke out such portability problems (by making
>>> sure that the lower 4GB aren't mapped) should be the ones who need to do
>>> something special.
>> Gee, should we go back and stop making sure VA 0 is unmapped too? Sure
>> it helps find NULL pointer dereferences but isn't that the tools
>> lecturing to the user as well? Having the TEXT_START_ADDR at 5GB
>> doesn't hurt anyone and will errant catch 32-bit deferences instead of
>> allowing possible silent corruption. Why is that a bad thing?
> It hurts anyone who uses -msym32, or gets given -msym32 archives,
> because we'll silently mislink their code.
That sounds like a bug. Maybe -msym32 objects should use a different reloc table that will emit overflow warnings if linked >= 0x80000000.