Erik:
The build tool genSocketOptionRegistry.exe is always relinked on
Windows at every rebuild. This causes a long chain of unnecessary
rebuilding, completely destroying incremental build performance.
The underlying cause of this is the enabling of debug symbols
everywhere without properly handling the debug symbol flags for
Windows. SetupNativeCompilation in this case thinks debug symbols are
to be generated and sets up dependencies based on that, but the
compile and link command lines are not setup to generate them. Since
they aren't there, the linking is redone each build.
My fix removes -Zi from C*FLAGS_JDKLIB and -debug from LDFLAGS_JDKLIB
and adds them to the *FLAGS_DEBUG_SYMBOLS variables instead, just as
have been done for all other platforms. I also move the .pdb files
generated for object files to a separate sub directory to avoid name
clashes if a source file and the resulting executable/lib has the same
name.
When running a compare build, sawindbg.dll differs on Windows x86
because it historically sets -ZI in CFLAGS, which is now overridden in
this patch. I very much doubt there is any need to use -ZI instead of
-Zi so also removing that flag from sawindb to not cause confusion
about what is actually in effect.
Bug: https://bugs.openjdk.java.net/browse/JDK-8151619
Webrev: http://cr.openjdk.java.net/~erikj/8151619/webrev.01/
Looks good to me.
Tim