This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC 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: [PATCH] Make mergeable read-only sections per-function, if requested.


On 05/07/2015 02:15 AM, Marek Polacek wrote:
On Wed, May 06, 2015 at 03:59:33PM -0700, Segher Boessenkool wrote:
Currently GCC does not put mergeable read-only data in a per-function
section, so the -gc-sections linker option does not do much for such
data.  Fix that.

Dunno if it is a good idea, but...
Why not? In a static build it gives the linker a chance to remove unreferenced data or to reorder the data to be more tlb or dcache friendly. That's the whole purpose behind -f{function,data}-sections.

Jeff



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