Reproducible searches after ucinewgame
authorJoost VandeVondele <Joost.VandeVondele@gmail.com>
Sat, 5 Nov 2016 15:37:29 +0000 (16:37 +0100)
committerMarco Costalba <mcostalba@gmail.com>
Sat, 5 Nov 2016 21:25:55 +0000 (22:25 +0100)
Fixes issue #859.

thisThread->callsCnt in search<>() was different (by 1) for the first and second game played.

No functional change.

src/search.cpp

index 0ed6b19..1279fe9 100644 (file)
@@ -212,6 +212,7 @@ void Search::clear() {
       th->counterMoves.clear();
       th->fromTo.clear();
       th->counterMoveHistory.clear();
+      th->resetCalls = true;
   }
 
   Threads.main()->previousScore = VALUE_INFINITE;