X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fsearch.cpp;h=eb0ac5bbd02c856c2a9d85989af21f22eafcacf5;hb=2c30956a13986454dcc5dd8c7daa1b27d5a77a1b;hp=8a4db35185921776e4288e02e83c8744c2c35db7;hpb=0a318cdddf8b6bdd05c2e0ee9b3b61a031d398ed;p=stockfish diff --git a/src/search.cpp b/src/search.cpp index 8a4db351..eb0ac5bb 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -1037,6 +1037,16 @@ moves_loop: // When in check, search starts here && captureHistory[movedPiece][to_sq(move)][type_of(pos.piece_on(to_sq(move)))] < 0) continue; + // Futility pruning for captures + if ( !pos.empty(to_sq(move)) + && !givesCheck + && !PvNode + && lmrDepth < 6 + && !ss->inCheck + && ss->staticEval + 342 + 238 * lmrDepth + PieceValue[EG][pos.piece_on(to_sq(move))] + + captureHistory[movedPiece][to_sq(move)][type_of(pos.piece_on(to_sq(move)))] / 8 < alpha) + continue; + // SEE based pruning if (!pos.see_ge(move, Value(-218) * depth)) // (~25 Elo) continue; @@ -1113,12 +1123,6 @@ moves_loop: // When in check, search starts here extension = -2; } - // Capture extensions for PvNodes and cutNodes - else if ( (PvNode || cutNode) - && captureOrPromotion - && moveCount != 1) - extension = 1; - // Check extensions else if ( givesCheck && depth > 6