Bug 10961 - Map file generated too late
Summary: Map file generated too late
Status: RESOLVED WONTFIX
Alias: None
Product: binutils
Classification: Unclassified
Component: ld (show other bugs)
Version: 2.21
: P2 minor
Target Milestone: ---
Assignee: unassigned
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-14 17:37 UTC by Richard Henderson
Modified: 2022-07-28 08:31 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments
Implement --no-relax as a generic linker option (3.23 KB, patch)
2009-11-20 19:09 UTC, Nick Clifton
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Henderson 2009-11-14 17:37:37 UTC
The output of -Map is produced at the end of linking,
and is *not* produced if relocation errors occur.

This lack of map file can make it very difficult to
understand why a relocation was out of range.
Comment 1 Nick Clifton 2009-11-20 19:09:01 UTC
Created attachment 4404 [details]
Implement --no-relax as a generic linker option
Comment 2 Nick Clifton 2009-11-20 19:09:38 UTC
Hi Richard,

  Something like the uploaded patch perhaps ?

Cheers
  Nick
Comment 3 rth@redhat.com 2009-11-20 21:10:07 UTC
Subject: Re:  Map file generated too late

On 11/20/2009 11:09 AM, nickc at redhat dot com wrote:
>    Something like the uploaded patch perhaps ?

Wrong PR, Nick.

And that 150 thing is *really* gross.  Wouldn't it be
better to change command_line.relax to be a tri-state
thingy, so that the backend can tell if it's unset?


r~
Comment 4 Nick Clifton 2009-11-23 11:09:14 UTC
Hi Richard,

Doh!  Bogus patch obsoleted.

I'll rework the patch as you suggested and upload it to the proper PR.

Cheers
  Nick

Comment 5 Alan Modra 2022-07-28 08:31:33 UTC
Map output can't be produced until late in linking.  --noinhibit-exec helps in some cases.