diff --git a/src/search.cpp b/src/search.cpp index cb0340ec..ffe6e04b 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -559,12 +559,11 @@ Value Search::Worker::search( Key posKey; Move move, excludedMove, bestMove; Depth extension, newDepth; - Value bestValue, value, eval, maxValue, probCutBeta, singularValue; + Value bestValue, value, eval, maxValue, probCutBeta; bool givesCheck, improving, priorCapture, opponentWorsening; bool capture, moveCountPruning, ttCapture; Piece movedPiece; int moveCount, captureCount, quietCount; - Bound singularBound; // Step 1. Initialize node Worker* thisThread = this; @@ -948,8 +947,6 @@ moves_loop: // When in check, search starts here value = bestValue; moveCountPruning = false; - singularValue = VALUE_INFINITE; - singularBound = BOUND_NONE; // Step 13. Loop through all pseudo-legal moves until no moves remain // or a beta cutoff occurs. @@ -999,9 +996,7 @@ moves_loop: // When in check, search starts here if (!rootNode && pos.non_pawn_material(us) && bestValue > VALUE_TB_LOSS_IN_MAX_PLY) { // Skip quiet moves if movecount exceeds our FutilityMoveCount threshold (~8 Elo) - moveCountPruning = - moveCount >= futility_move_count(improving, depth) - - (singularBound == BOUND_UPPER && singularValue < alpha - 51); + moveCountPruning = moveCount >= futility_move_count(improving, depth); // Reduced depth of the next LMR search int lmrDepth = newDepth - r; @@ -1087,9 +1082,8 @@ moves_loop: // When in check, search starts here Depth singularDepth = newDepth / 2; ss->excludedMove = move; - value = singularValue = + value = search(pos, ss, singularBeta - 1, singularBeta, singularDepth, cutNode); - singularBound = singularValue >= singularBeta ? BOUND_LOWER : BOUND_UPPER; ss->excludedMove = Move::none(); if (value < singularBeta)