Skip to content

Commit 249eec6

Browse files
FauziAkramvondele
authored andcommitted
Simplify the depth-dependent part of the best value adjustment formula in main search
Passed STC: LLR: 2.95 (-2.94,2.94) <-1.75,0.25> Total: 139648 W: 36171 L: 36061 D: 67416 Ptnml(0-2): 545, 16685, 35282, 16739, 573 https://tests.stockfishchess.org/tests/view/660d953b8ff4a059828d625d Passed LTC: LLR: 2.94 (-2.94,2.94) <-1.75,0.25> Total: 222894 W: 56519 L: 56505 D: 109870 Ptnml(0-2): 112, 25145, 60971, 25055, 164 https://tests.stockfishchess.org/tests/view/660fd4afbfeb43334bf7d558 closes #5164 bench: 1479416
1 parent d6bdcec commit 249eec6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/search.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -585,7 +585,7 @@ Value Search::Worker::search(
585585

586586
assert(0 <= ss->ply && ss->ply < MAX_PLY);
587587

588-
bestMove = Move::none();
588+
bestMove = Move::none();
589589
(ss + 2)->killers[0] = (ss + 2)->killers[1] = Move::none();
590590
(ss + 2)->cutoffCnt = 0;
591591
ss->multipleExtensions = (ss - 1)->multipleExtensions;
@@ -1307,7 +1307,7 @@ Value Search::Worker::search(
13071307
// Adjust best value for fail high cases at non-pv nodes
13081308
if (!PvNode && bestValue >= beta && std::abs(bestValue) < VALUE_TB_WIN_IN_MAX_PLY
13091309
&& std::abs(beta) < VALUE_TB_WIN_IN_MAX_PLY && std::abs(alpha) < VALUE_TB_WIN_IN_MAX_PLY)
1310-
bestValue = (bestValue * (depth + 2) + beta) / (depth + 3);
1310+
bestValue = (bestValue * depth + beta) / (depth + 1);
13111311

13121312
if (!moveCount)
13131313
bestValue = excludedMove ? alpha : ss->inCheck ? mated_in(ss->ply) : VALUE_DRAW;

0 commit comments

Comments
 (0)