| 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 import("//build/config/chrome_build.gni") | 6 import("//build/config/chrome_build.gni") |
| 7 import("//build/config/compiler/compiler.gni") | 7 import("//build/config/compiler/compiler.gni") |
| 8 import("//build/config/nacl/config.gni") | 8 import("//build/config/nacl/config.gni") |
| 9 import("//build/toolchain/cc_wrapper.gni") | 9 import("//build/toolchain/cc_wrapper.gni") |
| 10 import("//build/toolchain/toolchain.gni") | 10 import("//build/toolchain/toolchain.gni") |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 binutils_path = rebase_path("//third_party/binutils/Linux_x64/Release/bin", | 38 binutils_path = rebase_path("//third_party/binutils/Linux_x64/Release/bin", |
| 39 root_build_dir) | 39 root_build_dir) |
| 40 | 40 |
| 41 # Compile in such a way as to make it possible for the profiler to unwind full | 41 # Compile in such a way as to make it possible for the profiler to unwind full |
| 42 # stack frames. Setting this flag has a large effect on the performance of the | 42 # stack frames. Setting this flag has a large effect on the performance of the |
| 43 # generated code than just setting profiling, but gives the profiler more | 43 # generated code than just setting profiling, but gives the profiler more |
| 44 # information to analyze. | 44 # information to analyze. |
| 45 # Requires profiling to be set to true. | 45 # Requires profiling to be set to true. |
| 46 enable_full_stack_frames_for_profiling = false | 46 enable_full_stack_frames_for_profiling = false |
| 47 | 47 |
| 48 # TODO(GYP): We should be using 64-bit gold for linking on both 64-bit Linux | 48 # TODO: We should be using 64-bit gold for linking on both 64-bit Linux |
| 49 # and 32-bit linux; 32-bit Gold runs out of address-space on 32-bit builds. | 49 # and 32-bit linux; 32-bit Gold runs out of address-space on 32-bit builds. |
| 50 # However, something isn't quite working right on the 32-bit builds. | 50 # However, something isn't quite working right on the 32-bit builds. |
| 51 use_gold = | 51 use_gold = |
| 52 is_linux && (current_cpu == "x64" || current_cpu == "arm") && !use_lld | 52 is_linux && (current_cpu == "x64" || current_cpu == "arm") && !use_lld |
| 53 | 53 |
| 54 # When we are going to use gold we need to find it. | 54 # When we are going to use gold we need to find it. |
| 55 # This is initialized below, after use_gold might have been overridden. | 55 # This is initialized below, after use_gold might have been overridden. |
| 56 gold_path = false | 56 gold_path = false |
| 57 | 57 |
| 58 # use_debug_fission: whether to use split DWARF debug info | 58 # use_debug_fission: whether to use split DWARF debug info |
| (...skipping 1262 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1321 configs = [ "//build/config/nacl:irt_optimize" ] | 1321 configs = [ "//build/config/nacl:irt_optimize" ] |
| 1322 } else { | 1322 } else { |
| 1323 ldflags = common_optimize_on_ldflags | 1323 ldflags = common_optimize_on_ldflags |
| 1324 if (is_win) { | 1324 if (is_win) { |
| 1325 # Favor speed over size, /O2 must be before the common flags. The GYP | 1325 # Favor speed over size, /O2 must be before the common flags. The GYP |
| 1326 # build also specifies /Ot, /Oi, and /GF, but these are implied by /O2. | 1326 # build also specifies /Ot, /Oi, and /GF, but these are implied by /O2. |
| 1327 cflags = [ "/O2" ] + common_optimize_on_cflags | 1327 cflags = [ "/O2" ] + common_optimize_on_cflags |
| 1328 | 1328 |
| 1329 # TODO(thakis): Remove is_clang here, https://crbug.com/598772 | 1329 # TODO(thakis): Remove is_clang here, https://crbug.com/598772 |
| 1330 if (is_official_build && !is_clang) { | 1330 if (is_official_build && !is_clang) { |
| 1331 # TODO(GYP): TODO(dpranke): Should these only be on in an official | |
| 1332 # build, or on all the time? For now we'll require official build so | |
| 1333 # that the compile is clean. | |
| 1334 cflags += [ | 1331 cflags += [ |
| 1335 "/GL", # Whole program optimization. | 1332 "/GL", # Whole program optimization. |
| 1336 | 1333 |
| 1337 # Disable Warning 4702 ("Unreachable code") for the WPO/PGO builds. | 1334 # Disable Warning 4702 ("Unreachable code") for the WPO/PGO builds. |
| 1338 # Probably anything that this would catch that wouldn't be caught in a | 1335 # Probably anything that this would catch that wouldn't be caught in a |
| 1339 # normal build isn't going to actually be a bug, so the incremental | 1336 # normal build isn't going to actually be a bug, so the incremental |
| 1340 # value of C4702 for PGO builds is likely very small. | 1337 # value of C4702 for PGO builds is likely very small. |
| 1341 "/wd4702", | 1338 "/wd4702", |
| 1342 ] | 1339 ] |
| 1343 } | 1340 } |
| (...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1449 | 1446 |
| 1450 if (is_ios || is_mac) { | 1447 if (is_ios || is_mac) { |
| 1451 # On Mac and iOS, this enables support for ARC (automatic ref-counting). | 1448 # On Mac and iOS, this enables support for ARC (automatic ref-counting). |
| 1452 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. | 1449 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. |
| 1453 config("enable_arc") { | 1450 config("enable_arc") { |
| 1454 common_flags = [ "-fobjc-arc" ] | 1451 common_flags = [ "-fobjc-arc" ] |
| 1455 cflags_objc = common_flags | 1452 cflags_objc = common_flags |
| 1456 cflags_objcc = common_flags | 1453 cflags_objcc = common_flags |
| 1457 } | 1454 } |
| 1458 } | 1455 } |
| OLD | NEW |