Skip to content

Commit f7fbc68

Browse files
gab8192vondele
authored andcommitted
Avoid recomputing moveCountPruning
In search, when moveCountPruning becomes true, it can never turn false again. Passed STC https://tests.stockfishchess.org/tests/view/652075ceac57711436728aac LLR: 2.94 (-2.94,2.94) <0.00,2.00> Total: 136448 W: 34923 L: 34472 D: 67053 Ptnml(0-2): 420, 15094, 36767, 15501, 442 closes #4823 Non functional change
1 parent 25d444e commit f7fbc68

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/search.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -984,7 +984,8 @@ namespace {
984984
&& bestValue > VALUE_TB_LOSS_IN_MAX_PLY)
985985
{
986986
// Skip quiet moves if movecount exceeds our FutilityMoveCount threshold (~8 Elo)
987-
moveCountPruning = moveCount >= futility_move_count(improving, depth);
987+
if (!moveCountPruning)
988+
moveCountPruning = moveCount >= futility_move_count(improving, depth);
988989

989990
// Reduced depth of the next LMR search
990991
int lmrDepth = newDepth - r;

0 commit comments

Comments
 (0)