Chromium Code Reviews| Index: build/config/compiler/BUILD.gn |
| diff --git a/build/config/compiler/BUILD.gn b/build/config/compiler/BUILD.gn |
| index fe18ee16877522c098231823f7a60e062fda3d00..9a113e6de81eccf0453ea4f406a2ee08be13cde1 100644 |
| --- a/build/config/compiler/BUILD.gn |
| +++ b/build/config/compiler/BUILD.gn |
| @@ -913,15 +913,28 @@ config("optimize_max") { |
| cflags = common_optimize_on_cflags |
| ldflags = common_optimize_on_ldflags |
| if (is_win) { |
| + cflags -= [ |
| + "/Os", |
| + ] |
| cflags += [ |
| "/Ot", # Favor speed over size. |
| - "/GL", # Whole program optimization. |
| - # Disable Warning 4702 ("Unreachable code") for the WPO/PGO builds. |
| - # Probably anything that this would catch that wouldn't be caught in a |
| - # normal build isn't going to actually be a bug, so the incremental value |
| - # of C4702 for PGO builds is likely very small. |
| - "/wd4702", |
| ] |
| + if (is_official_build) { |
| + # TODO(GYP): TODO(dpranke): Should these only be on in an official |
| + # build, or on all the time? For now we'll require official build so |
|
scottmg
2014/11/07 03:38:11
https://code.google.com/p/chromium/codesearch#chro
Dirk Pranke
2014/11/07 03:43:26
There seemed to be a few other places that explici
|
| + # that the compile is clean. |
| + cflags += [ |
| + "/GL", # Whole program optimization. |
| + # Disable Warning 4702 ("Unreachable code") for the WPO/PGO builds. |
| + # Probably anything that this would catch that wouldn't be caught in a |
| + # normal build isn't going to actually be a bug, so the incremental |
| + # value of C4702 for PGO builds is likely very small. |
| + "/wd4702", |
| + ] |
| + ldflags += [ |
| + "/LTCG", |
| + ] |
| + } |
| } else { |
| cflags += [ |
| "-O2", |