On Tue, Apr 16, 2019 at 11:33 AM Florian Weimer <fwei...@redhat.com> wrote:
>
> * Segher Boessenkool:
>
> > On Mon, Apr 15, 2019 at 01:54:11PM +0200, Florian Weimer wrote:
> >> * Richard Biener:
> >>
> >> > Of course adding sth like a .robss section would be nice.
> >>
> >> I think this is strictly a link editor issue because a read-only PT_LOAD
> >> directive with a memory size larger than the file size already produces
> >> read-only zero pages, without requiring a file allocation.
> >
> > But .rodata normally is not the last thing in its segment (the .eh*
> > things are after it, and those are usually not all zero).
>
> If you don't mind the proliferation of load segments (we've add many of
> them in recent years), placement does not matter.

Btw, besides being a link editor issue the issue also shows in object
file size.  Not sure if a similar trick exists for those (.rodata with NOBITS?)

Richard.

> Thanks,
> Florian

Reply via email to