]> git.sesse.net Git - stockfish/commitdiff
Simplify advanced pawn push pruning
authorVizvezdenec <Vizvezdenec@gmail.com>
Sun, 17 Nov 2019 18:47:17 +0000 (21:47 +0300)
committerStéphane Nicolet <cassio@free.fr>
Tue, 19 Nov 2019 22:18:14 +0000 (23:18 +0100)
This patch simplifies away all conditions related to advanced pawn pushes
in shallow depth pruning. Idea is based on fact that in master we have
advanced pawn pushes not being pruned what we are only in PV node and
when non-pawn material of opponent is > Bishop, so pretty rarely. With
this patch we will have all pruning heuristics working for this moves as
for every other move.

STC
LLR: 2.94 (-2.94,2.94) [-3.00,1.00]
Total: 159143 W: 34271 L: 34418 D: 90454
http://tests.stockfishchess.org/tests/view/5dcdb3110ebc5902563249d7

LTC
LLR: 2.95 (-2.94,2.94) [-3.00,1.00]
Total: 63900 W: 10375 L: 10322 D: 43203
http://tests.stockfishchess.org/tests/view/5dd05e820ebc5902579e1fb8

Closes https://github.com/official-stockfish/Stockfish/pull/2416

bench 4897149

src/search.cpp

index 24bcb9ad2af5baf1f9d15d49e05068fb552687f1..b54ff19648d7adce0fd1b4f04f7c11afada68bbd 100644 (file)
@@ -974,8 +974,7 @@ moves_loop: // When in check, search starts from here
           moveCountPruning = moveCount >= futility_move_count(improving, depth);
 
           if (   !captureOrPromotion
-              && !givesCheck
-              && (!PvNode || !pos.advanced_pawn_push(move) || pos.non_pawn_material(~us) > BishopValueMg))
+              && !givesCheck)
           {
               // Reduced depth of the next LMR search
               int lmrDepth = std::max(newDepth - reduction(improving, depth, moveCount), 0);