Add win_compiler_timing switch
Change-Id: I32097bc02654e74251e309dbd550e916203215a9 Reviewed-on: https://chromium-review.googlesource.com/734296 Reviewed-by: Nico Weber <thakis@chromium.org> Commit-Queue: Bruce Dawson <brucedawson@chromium.org> Cr-Commit-Position: refs/heads/master@{#511525}
This commit is contained in:
@ -19,6 +19,9 @@ declare_args() {
|
|||||||
|
|
||||||
# Turn this on to have the linker output extra timing information.
|
# Turn this on to have the linker output extra timing information.
|
||||||
win_linker_timing = false
|
win_linker_timing = false
|
||||||
|
|
||||||
|
# Turn this on to have the compiler output extra timing information.
|
||||||
|
win_compiler_timing = false
|
||||||
}
|
}
|
||||||
|
|
||||||
# This is included by reference in the //build/config/compiler config that
|
# This is included by reference in the //build/config/compiler config that
|
||||||
@ -120,6 +123,21 @@ config("compiler") {
|
|||||||
# the source file is a no-op.
|
# the source file is a no-op.
|
||||||
"/ignore:4221",
|
"/ignore:4221",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
if (win_compiler_timing) {
|
||||||
|
if (is_clang) {
|
||||||
|
cflags += [
|
||||||
|
"-Xclang",
|
||||||
|
"-ftime-report",
|
||||||
|
]
|
||||||
|
} else {
|
||||||
|
cflags += [
|
||||||
|
# "Documented" here:
|
||||||
|
# http://aras-p.info/blog/2017/10/23/Best-unknown-MSVC-flag-d2cgsummary/
|
||||||
|
"/d2cgsummary",
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
config("vs_code_analysis") {
|
config("vs_code_analysis") {
|
||||||
|
@ -209,8 +209,6 @@ support incremental linking for more targets. Note that if you set this but
|
|||||||
don't' set enable_nacl = false then build times may get worse.
|
don't' set enable_nacl = false then build times may get worse.
|
||||||
* `remove_webcore_debug_symbols = true` - turn off source-level debugging for
|
* `remove_webcore_debug_symbols = true` - turn off source-level debugging for
|
||||||
blink to reduce build times, appropriate if you don't plan to debug blink.
|
blink to reduce build times, appropriate if you don't plan to debug blink.
|
||||||
* `win_linker_timing = true` - this should not generally be set but can be
|
|
||||||
helpful when trying to understand build times or incremental linking failures.
|
|
||||||
|
|
||||||
In addition, Google employees should consider using goma, a distributed
|
In addition, Google employees should consider using goma, a distributed
|
||||||
compilation system. Detailed information is available internally but the
|
compilation system. Detailed information is available internally but the
|
||||||
|
Reference in New Issue
Block a user