Try /Z7 on Windows builds.
Right now /FS and /Zi together serialize debug information
into .pdb files through another process.
I tried just dropping /FS, so that each cl.exe instance
writes to the .pdb file directly, but the bots don't like that.
Instead, let's try switching /Zi to /Z7, to embed debug information
directly into the object file instead of alongside in a .pdb.
This is all about trying to improve build times.
https://docs.microsoft.com/en-us/cpp/build/reference/z7-zi-zi-debug-information-format
https://docs.microsoft.com/en-us/cpp/build/reference/fs-force-synchronous-pdb-writes
Change-Id: If636f8fa21c639eff81d9c335c5223908c0fdcea
Reviewed-on: https://skia-review.googlesource.com/85661
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Mike Klein <mtklein@chromium.org>
diff --git a/gn/BUILD.gn b/gn/BUILD.gn
index 4d6ada7..28b1aec 100644
--- a/gn/BUILD.gn
+++ b/gn/BUILD.gn
@@ -39,7 +39,6 @@
if (is_win) {
cflags += [
- "/FS", # Preserve previous PDB behavior.
"/bigobj", # Some of our files are bigger than the regular limits.
"/WX", # Treat warnings as errors.
"/utf-8", # Set Source and Executable character sets to UTF-8.
@@ -381,7 +380,7 @@
"-funwind-tables", # Helps make in-process backtraces fuller.
]
} else if (is_win) {
- cflags = [ "/Zi" ]
+ cflags = [ "/Z7" ]
ldflags = [ "/DEBUG" ]
} else {
cflags = [ "-g" ]