From: Guenther Demetz Date: Tue, 18 Dec 2018 07:05:09 +0000 (+0100) Subject: Tweak main killer penalty X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=0f2df4e4afa37946e02a2b647ff21146e0588af7 Tweak main killer penalty Apply refuted main killer penalty also on early TT cut-offs. This makes penalty logic more consistent with the logic at normal search. Failed STC: http://tests.stockfishchess.org/tests/view/5c121e730ebc5902ba11aad8 LLR: -2.95 (-2.94,2.94) [0.00,5.00] Total: 72193 W: 15848 L: 15625 D: 40720 Elo +1.07 Passed LTC: http://tests.stockfishchess.org/tests/view/5c17b1b10ebc5902ba123c24 LLR: 2.95 (-2.94,2.94) [0.00,5.00] Total: 35073 W: 5886 L: 5625 D: 23562 Elo +2.59 Closes https://github.com/official-stockfish/Stockfish/pull/1878 bench: 3393939 --- diff --git a/src/search.cpp b/src/search.cpp index 02f40199..756b2d57 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -656,9 +656,11 @@ namespace { if (!pos.capture_or_promotion(ttMove)) update_quiet_stats(pos, ss, ttMove, nullptr, 0, stat_bonus(depth)); - // Extra penalty for a quiet TT move in previous ply when it gets refuted - if ((ss-1)->moveCount == 1 && !pos.captured_piece()) - update_continuation_histories(ss-1, pos.piece_on(prevSq), prevSq, -stat_bonus(depth + ONE_PLY)); + // Extra penalty for a quiet TT or main killer move in previous ply when it gets refuted + if ( (ss-1)->moveCount == 1 + || ((ss-1)->currentMove == (ss-1)->killers[0] && (ss-1)->killers[0])) + if (!pos.captured_piece()) + update_continuation_histories(ss-1, pos.piece_on(prevSq), prevSq, -stat_bonus(depth + ONE_PLY)); } // Penalty for a quiet ttMove that fails low else if (!pos.capture_or_promotion(ttMove))