]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Stat Score reset at rootNode - Bench: 3393330 (#2124)
[stockfish] / src / search.cpp
index 082be4f25587a7ec4d0e329b14890ae3c9446bb2..36e73a09cd8f1a2970edc9afdd405506da4b0baf 100644 (file)
@@ -594,7 +594,10 @@ namespace {
     // starts with statScore = 0. Later grandchildren start with the last calculated
     // statScore of the previous grandchild. This influences the reduction rules in
     // LMR which are based on the statScore of parent position.
-    (ss+2)->statScore = 0;
+       if (rootNode)
+               (ss + 4)->statScore = 0;
+       else
+               (ss + 2)->statScore = 0;
 
     // Step 4. Transposition table lookup. We don't want the score of a partial
     // search to overwrite a previous full search TT value, so we use a different