OLD | NEW |
1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2013 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import("//build/config/android/config.gni") | 5 import("//build/config/android/config.gni") |
6 if (cpu_arch == "arm") { | 6 if (cpu_arch == "arm") { |
7 import("//build/config/arm.gni") | 7 import("//build/config/arm.gni") |
8 } | 8 } |
9 if (is_posix) { | 9 if (is_posix) { |
10 import("//build/config/gcc/gcc_version.gni") | 10 import("//build/config/gcc/gcc_version.gni") |
(...skipping 749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
760 # On Windows, turns up the optimization level. This implies whole program | 760 # On Windows, turns up the optimization level. This implies whole program |
761 # optimization and link-time code generation which is very expensive and should | 761 # optimization and link-time code generation which is very expensive and should |
762 # be used sparingly. For non-Windows, this is the same as "optimize". | 762 # be used sparingly. For non-Windows, this is the same as "optimize". |
763 config("optimize_max") { | 763 config("optimize_max") { |
764 cflags = common_optimize_on_cflags | 764 cflags = common_optimize_on_cflags |
765 ldflags = common_optimize_on_ldflags | 765 ldflags = common_optimize_on_ldflags |
766 if (is_win) { | 766 if (is_win) { |
767 cflags += [ | 767 cflags += [ |
768 "/Ot", # Favor speed over size. | 768 "/Ot", # Favor speed over size. |
769 "/GL", # Whole program optimization. | 769 "/GL", # Whole program optimization. |
| 770 # Disable Warning 4702 ("Unreachable code") for the WPO/PGO builds. |
| 771 # Probably anything that this would catch that wouldn't be caught in a |
| 772 # normal build isn't going to actually be a bug, so the incremental value |
| 773 # of C4702 for PGO builds is likely very small. |
| 774 "/wd4702", |
770 ] | 775 ] |
771 } else { | 776 } else { |
772 cflags += [ | 777 cflags += [ |
773 "-O2", | 778 "-O2", |
774 ] | 779 ] |
775 } | 780 } |
776 } | 781 } |
777 | 782 |
778 # Symbols ---------------------------------------------------------------------- | 783 # Symbols ---------------------------------------------------------------------- |
779 | 784 |
(...skipping 13 matching lines...) Expand all Loading... |
793 } else { | 798 } else { |
794 cflags = [ "-g1" ] | 799 cflags = [ "-g1" ] |
795 } | 800 } |
796 } | 801 } |
797 | 802 |
798 config("no_symbols") { | 803 config("no_symbols") { |
799 if (!is_win) { | 804 if (!is_win) { |
800 cflags = [ "-g0" ] | 805 cflags = [ "-g0" ] |
801 } | 806 } |
802 } | 807 } |
OLD | NEW |