Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4382)

Unified Diff: build/common.gypi

Issue 1289623006: build: On Android, disable LTO for specific targets only when targeting GCC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Clarify comment in build/common.gypi; add TODO to use -lto_library Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/increase_size_for_speed.gypi ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/common.gypi
diff --git a/build/common.gypi b/build/common.gypi
index 5806a63ca39c442c671c1bc0f6e91e01776b663c..3f84193703ef60547fc72ce9ada1abf9f6299946 100644
--- a/build/common.gypi
+++ b/build/common.gypi
@@ -684,10 +684,10 @@
'host_clang%': 1,
# Variables to control Link-Time Optimization (LTO).
- # On Android, the variable use_lto enables LTO on code compiled with -Os,
- # and use_lto_o2 enables LTO on code compiled with -O2. On other
- # platforms, use_lto enables LTO in all translation units, and use_lto_o2
- # has no effect.
+ # On Android, when using GCC LTO, the variable use_lto enables LTO on code
+ # compiled with -Os, and use_lto_o2 enables LTO on code compiled with -O2.
+ # On other platforms (including Android with Clang), use_lto enables LTO
+ # in all translation units, and use_lto_o2 has no effect.
#
# On Linux and Android, when using LLVM LTO, the script
# build/download_gold_plugin.py must be run to download a linker plugin.
@@ -695,8 +695,10 @@
# tools/clang/scripts/update.py and the absolute path to
# third_party/llvm-build/Release+Asserts/lib must be added to
# $DYLD_LIBRARY_PATH to pick up the right version of the linker plugin.
+ # TODO(pcc): Teach build system to use -lto_library flag to specify path
+ # to linker plugin on Mac.
#
- # On Android, the variables must *not* be enabled at the same time.
+ # On Android/GCC, the variables must *not* be enabled at the same time.
# In this case LTO would 'merge' the optimization flags at link-time
# which would lead to all code be optimized with -O2. See crbug.com/407544
'use_lto%': 0,
« no previous file with comments | « build/android/increase_size_for_speed.gypi ('k') | chrome/chrome_browser.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698