mirror of
https://github.com/official-stockfish/Stockfish.git
synced 2026-07-22 20:57:10 +00:00
Clear Workers after changing the network
ensures internal state (e.g. accumulator cache) is consistent with network closes https://github.com/official-stockfish/Stockfish/pull/5204 No functional change
This commit is contained in:
committed by
Joost VandeVondele
parent
be142337d8
commit
be026bdcb2
@@ -161,6 +161,9 @@ void ThreadPool::clear() {
|
||||
for (Thread* th : threads)
|
||||
th->worker->clear();
|
||||
|
||||
if (threads.size() == 0)
|
||||
return;
|
||||
|
||||
main_manager()->callsCnt = 0;
|
||||
main_manager()->bestPreviousScore = VALUE_INFINITE;
|
||||
main_manager()->bestPreviousAverageScore = VALUE_INFINITE;
|
||||
|
||||
Reference in New Issue
Block a user