This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC PATCH] Readonly .eh_frame and .gcc_except_table


On Mon, Nov 25, 2002 at 09:33:19PM +0100, Jakub Jelinek wrote:
> On Mon, Nov 25, 2002 at 10:58:00AM +1030, Alan Modra wrote:
> >   I'm thinking a more generally useful linker script enhancement might
> > be better, and should be easy to implement.  How about an AUTO_PLACE
> > keyword for an output section?  Allows KEEP and other input section
> > flags + ordering etc., but placement relative to other output sections
> > is chosen automatically by the linker.
> 
> And teach place_orphan where exactly to autoplace .eh_frame and
> .gcc_except_table if they are read-only and if they are read-write?

No, not place_orphan as that operates on input sections.  A new
function something similar to place_orphan that twiddles output
section ordering.

> If read-only, those two sections should be placed right as the last two
> sections in the read-only segment, so that if no exceptions happen,
> programs/libs will require less paging.
> Similarly, if they are to be present in read-write segment, they should IMHO
> stay together, not with some random other orphan rw section in between.

Yes, and the beauty of this scheme is that you could arrange to place
.eh_frame after any orphans.  Currently, similar type orphan sections
will go after sections specified in the script.

-- 
Alan Modra
IBM OzLabs - Linux Technology Centre


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]