]> git.sesse.net Git - stockfish/commitdiff
Simplify futilityBase formula
authorTaras Vuk <117687515+TarasVuk@users.noreply.github.com>
Sun, 22 Oct 2023 06:36:43 +0000 (08:36 +0200)
committerJoost VandeVondele <Joost.VandeVondele@gmail.com>
Sun, 22 Oct 2023 14:16:02 +0000 (16:16 +0200)
This patch replaces std::min(ss->staticEval, bestValue) with ss->staticEval in the futilityBase formula.
Original idea by Vizvezdenec: https://tests.stockfishchess.org/tests/view/64ce66795b17f7c21c0d85f3

Passed STC:
LLR: 2.94 (-2.94,2.94) <-1.75,0.25>
Total: 116928 W: 29925 L: 29793 D: 57210
Ptnml(0-2): 399, 13558, 30446, 13634, 427
https://tests.stockfishchess.org/tests/view/653285aade6d262d08d385dd

Passed LTC:
LLR: 2.96 (-2.94,2.94) <-1.75,0.25>
Total: 50868 W: 12947 L: 12757 D: 25164
Ptnml(0-2): 30, 5414, 14355, 5606, 29
https://tests.stockfishchess.org/tests/view/65336ffbde6d262d08d39ba0

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

bench: 1241996

src/search.cpp

index 43f0c8726e3721f2d7cbaa554923633951facac4..43d78892f60d7e6374a9e5c9dcd410cb5b3676a9 100644 (file)
@@ -1451,7 +1451,7 @@ Value qsearch(Position& pos, Stack* ss, Value alpha, Value beta, Depth depth) {
         if (bestValue > alpha)
             alpha = bestValue;
 
-        futilityBase = std::min(ss->staticEval, bestValue) + 200;
+        futilityBase = ss->staticEval + 200;
     }
 
     const PieceToHistory* contHist[] = {(ss - 1)->continuationHistory,