summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-04 18:11:52 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-05-04 18:11:52 +0000
commitc75f33e44402f2c74e0f69f064e778cc8b5df3c9 (patch)
tree8d6d6222fbe37e5a99faab51670668a33748c848 /build
parent4f3ec6f508da4371bb291a8c35d0cd13b26a3127 (diff)
downloadchromium_src-c75f33e44402f2c74e0f69f064e778cc8b5df3c9.zip
chromium_src-c75f33e44402f2c74e0f69f064e778cc8b5df3c9.tar.gz
chromium_src-c75f33e44402f2c74e0f69f064e778cc8b5df3c9.tar.bz2
linux: enable safe identical code folding for release builds
This shaves 2.5mb (~5%) off the binary, at the cost of ~1 second (~25%) of linking. In debug builds, the 25% time cost is much larger so we only enable this for Release mode. BUG=76280 Review URL: http://codereview.chromium.org/6931008 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84088 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r--build/common.gypi8
1 files changed, 8 insertions, 0 deletions
diff --git a/build/common.gypi b/build/common.gypi
index 7ce6a47..48787ec 100644
--- a/build/common.gypi
+++ b/build/common.gypi
@@ -1119,6 +1119,14 @@
'-g',
],
}],
+ # At gyp time, we test the linker for ICF support; this flag
+ # is then provided to us by gyp. (Currently only gold supports
+ # an --icf flag.)
+ ['LINKER_SUPPORTS_ICF==1', {
+ 'ldflags': [
+ '-Wl,--icf=safe',
+ ]
+ }],
]
},
},