]> git.sesse.net Git - stockfish/commitdiff
Do lmr for more captures
authorVizvezdenec <Vizvezdenec@gmail.com>
Wed, 20 Nov 2019 20:20:20 +0000 (23:20 +0300)
committerStéphane Nicolet <cassio@free.fr>
Thu, 21 Nov 2019 08:52:13 +0000 (09:52 +0100)
Based on machinery introduced by vondele. Logic behind patch if relatively simple -
if we reduce less with high hit rate of transposition table somewhat logical is to
reduce more with low hit rate. For example enable all captures for LMR.

Threshold 0.375 is arbitrary and can be tweaked :)

STC
http://tests.stockfishchess.org/tests/view/5dd4d51df531e81cf278eaac
LLR: 2.97 (-2.94,2.94) [-1.50,4.50]
Total: 16495 W: 3591 L: 3434 D: 9470

LTC
http://tests.stockfishchess.org/tests/view/5dd52265f531e81cf278eace
LLR: 2.96 (-2.94,2.94) [0.00,3.50]
Total: 23598 W: 3956 L: 3716 D: 15926

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

Bench: 5067870

src/search.cpp

index b54ff19648d7adce0fd1b4f04f7c11afada68bbd..d3f38aae10954ec1eadefdbbc59cb6548e21b837 100644 (file)
@@ -1084,7 +1084,8 @@ moves_loop: // When in check, search starts from here
           && (  !captureOrPromotion
               || moveCountPruning
               || ss->staticEval + PieceValue[EG][pos.captured_piece()] <= alpha
           && (  !captureOrPromotion
               || moveCountPruning
               || ss->staticEval + PieceValue[EG][pos.captured_piece()] <= alpha
-              || cutNode))
+              || cutNode
+              || thisThread->ttHitAverage < 384 * ttHitAverageResolution * ttHitAverageWindow / 1024))
       {
           Depth r = reduction(improving, depth, moveCount);
 
       {
           Depth r = reduction(improving, depth, moveCount);