Run more than 34 processes on Win32 if we have 32+ cores.
authorRui Ueyama <ruiu@google.com>
Fri, 17 Apr 2015 21:14:44 +0000 (14:14 -0700)
committerRui Ueyama <ruiu@google.com>
Fri, 17 Apr 2015 21:14:48 +0000 (14:14 -0700)
commit8c8834acffdc0da0d94119725929acc712c9dfad
tree5c1c1e402345ca0391a041ea1922553d1f5db02a
parentce70cde4b17e2b506a824bb4b58bd7c82116514d
Run more than 34 processes on Win32 if we have 32+ cores.

For compatiblity reason, dwNumberOfProcessors in Win32 is capped at 32.
So even if your machine has more than 32 cores, Ninja spawns at most 34
subprocesses. This patch fixes the issue by using GetNativeSystemInfo,
which returns the system info from Wow64 point of view, instead of
GetSystemInfo.
src/util.cc