]> git.sesse.net Git - stockfish/commitdiff
Increase reduction in case of stable best move
authorVizvezdenec <Vizvezdenec@gmail.com>
Mon, 14 Dec 2020 00:49:04 +0000 (03:49 +0300)
committerJoost VandeVondele <Joost.VandeVondele@gmail.com>
Mon, 14 Dec 2020 06:52:02 +0000 (07:52 +0100)
The idea of this patch is pretty simple - we already do more reductions
for non-PV and root nodes in case of stable best move for depth > 10.
This patch makes us do so if root depth if > 10 instead, which
is logical since best move changes (thus instability of it) is
counted at root, so it makes a lot of sense to use depth of the root.

passed STC
https://tests.stockfishchess.org/tests/view/5fd643271ac16912018885c5
LLR: 2.94 (-2.94,2.94) {-0.25,1.25}
Total: 13232 W: 1308 L: 1169 D: 10755
Ptnml(0-2): 39, 935, 4535, 1062, 45

passed LTC
https://tests.stockfishchess.org/tests/view/5fd68db11ac16912018885f0
LLR: 2.96 (-2.94,2.94) {0.25,1.25}
Total: 14024 W: 565 L: 463 D: 12996
Ptnml(0-2): 3, 423, 6062, 517, 7

closes https://github.com/official-stockfish/Stockfish/pull/3263

Bench: 4050630

src/search.cpp

index e825fce7522b8f15bf3535bdebffefc57ecd4133..cdbccb4c0abbc395f27465a33e6675ba133817d6 100644 (file)
@@ -1188,7 +1188,7 @@ moves_loop: // When in check, search starts from here
               r -= 2;
 
           // Increase reduction at root and non-PV nodes when the best move does not change frequently
               r -= 2;
 
           // Increase reduction at root and non-PV nodes when the best move does not change frequently
-          if ((rootNode || !PvNode) && depth > 10 && thisThread->bestMoveChanges <= 2)
+          if ((rootNode || !PvNode) && thisThread->rootDepth > 10 && thisThread->bestMoveChanges <= 2)
               r++;
 
           // More reductions for late moves if position was not in previous PV
               r++;
 
           // More reductions for late moves if position was not in previous PV