User account creation filtered due to spam.

Bug 44236 - Output initializers in .text.init section
Summary: Output initializers in .text.init section
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: unknown
: P3 enhancement
Target Milestone: ---
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-21 23:10 UTC by Taras Glek
Modified: 2011-10-18 15:10 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2010-10-15 01:47:46


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Taras Glek 2010-05-21 23:10:07 UTC
In mozilla there are a lot of page faults caused by paging in C++ global initializers. About 1/3rd of firefox faults are globals.
ie the first part of a prelinked firefox startup is a bunch of faults caused by _GLOBAL__I_nsFtpConnectionThread.cpp, _GLOBAL__I_nsCookieService.cpp, etc.

If these were grouped together large C++ apps would load much faster. Once the initializers are easily identifiable by the linker, the linker needs to lay these out in a continuous chunk in the ordered that they are called.
Comment 1 Jan Hubicka 2010-10-15 01:47:46 UTC
http://gcc.gnu.org/ml/gcc-patches/2010-10/msg01274.html

The patch should probably work with minor updates in 4.5 branch too.
Comment 2 Jan Hubicka 2011-10-18 15:10:40 UTC
This is solved on GCC side. Still gold needs updating to sort the sections accordingly.