diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2017-10-17 12:12:49 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2017-10-17 12:14:22 +0200 |
commit | 3bf169720b147bd5322e190469e134d99ff424d6 (patch) | |
tree | 291335bd4dda08cb845b3643404cd14d7f0719d3 /build2/scheduler.cxx | |
parent | b3eaf577762078b097f5e68904aa15c4655c80df (diff) |
Adjust max-threads multiplier for 32-bit because of stack size increase
Diffstat (limited to 'build2/scheduler.cxx')
-rw-r--r-- | build2/scheduler.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/build2/scheduler.cxx b/build2/scheduler.cxx index 6ffbdc4..f7b10e9 100644 --- a/build2/scheduler.cxx +++ b/build2/scheduler.cxx @@ -243,11 +243,12 @@ namespace build2 // lock l (mutex_); - // Use 16x max_active on 32-bit and 32x max_active on 64-bit. Unless we + // Use 8x max_active on 32-bit and 32x max_active on 64-bit. Unless we // were asked to run serially. // if (max_threads == 0) - max_threads = max_active * (max_active == 1 ? 1 : sizeof (void*) * 4); + max_threads = (max_active == 1 ? 1 : + sizeof (void*) < 8 ? 8 : 32) * max_active; assert (shutdown_ && init_active != 0 && |