]> git.sesse.net Git - stockfish/commitdiff
Do not overwrite valuable TT data after probcut.
authorVizvezdenec <Vizvezdenec@gmail.com>
Mon, 13 Jul 2020 17:30:58 +0000 (20:30 +0300)
committerJoost VandeVondele <Joost.VandeVondele@gmail.com>
Fri, 17 Jul 2020 18:28:44 +0000 (20:28 +0200)
This patch allows an engine to write probcut data only in case
the probcut search depth is greater than transposition table depth.

passed STC
https://tests.stockfishchess.org/tests/view/5f0b52e959f6f035328949a6
LLR: 2.97 (-2.94,2.94) {-0.50,1.50}
Total: 52544 W: 10145 L: 9880 D: 32519
Ptnml(0-2): 853, 6097, 12121, 6334, 867

passed LTC
https://tests.stockfishchess.org/tests/view/5f0bd94c59f6f035328949f3
LLR: 2.93 (-2.94,2.94) {0.25,1.75}
Total: 49576 W: 6164 L: 5863 D: 37549
Ptnml(0-2): 297, 4371, 15218, 4538, 364

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

bench 4578298

src/search.cpp

index 6cf2f90d409f96dbe4f6a88ce625d71341153493..17ccab9251abb052a12c7e1b6a41ef8db75f5e4f 100644 (file)
@@ -925,9 +925,12 @@ namespace {
 
                 if (value >= probcutBeta)
                 {
-                    tte->save(posKey, value_to_tt(value, ss->ply), ttPv,
-                        BOUND_LOWER,
-                        depth - 3, move, ss->staticEval);
+                    if ( !(ttHit
+                       && tte->depth() >= depth - 3
+                       && ttValue != VALUE_NONE))
+                        tte->save(posKey, value_to_tt(value, ss->ply), ttPv,
+                            BOUND_LOWER,
+                            depth - 3, move, ss->staticEval);
                     return value;
                 }
             }