To reduce the amount of headers included by windows.h, it's possible to define WIN32_LEAN_AND_MEAN before including it [1]. This also makes it possible to access definitions in winsock2.h which otherwise would conflict with the older winsock.h that windows.h pulls in.
Quick testing didn't see any significant build time improvements (15 seconds faster building hotspot on my machine, the pch file shrinks from 120mb to 112mb) but access to winsock2.h would be useful for JFR.
[1] https://msdn.microsoft.com/en-us/library/windows/desktop/aa383745%28v=vs.85%29.aspx#faster_builds_with_smaller_header_files
Quick testing didn't see any significant build time improvements (15 seconds faster building hotspot on my machine, the pch file shrinks from 120mb to 112mb) but access to winsock2.h would be useful for JFR.
[1] https://msdn.microsoft.com/en-us/library/windows/desktop/aa383745%28v=vs.85%29.aspx#faster_builds_with_smaller_header_files
- relates to
-
JDK-8199619 Building HotSpot on Windows should define NOMINMAX
-
- Closed
-