mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-19 16:46:30 +08:00
Retire cpu_count()
Set threads number always to 1 at startup and let the user explicitly to chose the number of threads. Also preserve the useful behavior of automatically set "Min Split Depth" according to the requested threads, indeed this parameter is too technical for a casual user, so, when left to zero, we set it on a sensible value. No functional change
This commit is contained in:
committed by
Marco Costalba
parent
408e6ee9b6
commit
a16ba5bbd1
@@ -217,6 +217,13 @@ void ThreadPool::read_uci_options() {
|
||||
|
||||
assert(requested > 0);
|
||||
|
||||
// Value 0 has a special meaning: We determine the optimal minimum split depth
|
||||
// automatically. Anyhow the minimumSplitDepth should never be under 4 plies.
|
||||
if (!minimumSplitDepth)
|
||||
minimumSplitDepth = (requested < 8 ? 4 : 7) * ONE_PLY;
|
||||
else
|
||||
minimumSplitDepth = std::max(4 * ONE_PLY, minimumSplitDepth);
|
||||
|
||||
while (size() < requested)
|
||||
push_back(new_thread<Thread>());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user