This is the mail archive of the 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] pad out code segment for NaCl targets

On Fri, Aug 16, 2013 at 3:21 AM, Alan Modra <> wrote:
> Ah, yes, you need to somehow page align any following sections before
> assign_file_positions_for_{non_,}load_sections is called.  That could
> be done in the linker script without a new padding section.

Sorry, I don't follow.  The next section in the address space is already
page-aligned (and far away).  I don't see how that helps.  The partial page
I'm concerned with is at the end of the code segment.  Because of the
machinations in bfd/elf-nacl.c, that is at the end of the file (despite not
being the highest-addressed segment).  What I need is for that segment to
extend to the next page boundary in the file, so that the non-allocated
sections (and shdrs) that follow start on the page boundary.

Perhaps I can have the modify_segment_map hook synthesize a fake section
that isn't really there or something.  I'll play with that while I wait for
a better suggestion.


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