mirror of
https://github.com/sockspls/badfish
synced 2025-05-02 01:29:36 +00:00
Rebalance usage of history heuristics in pruning
This patch has multiple effects: * history heuristics sum in futility pruning now can't exceed some negative value so futility pruning for moves with negative histories should become slightly less aggressive; * history heuristics are now used in SEE pruning for quiet moves; Passed STC: https://tests.stockfishchess.org/tests/view/63cde339c93e8828d0f02e3a LLR: 2.94 (-2.94,2.94) <0.00,2.00> Total: 88424 W: 23681 L: 23303 D: 41440 Ptnml(0-2): 258, 9559, 24219, 9899, 277 Passed LTC: https://tests.stockfishchess.org/tests/view/63ce9009c93e8828d0f04e4f LLR: 2.94 (-2.94,2.94) <0.50,2.50> Total: 79536 W: 21223 L: 20843 D: 37470 Ptnml(0-2): 22, 7599, 24146, 7979, 22 closes https://github.com/official-stockfish/Stockfish/pull/4355 Bench: 4208265
This commit is contained in:
parent
3dd0a7a7cd
commit
d3860f8d5e
1 changed files with 6 additions and 1 deletions
|
@ -1026,12 +1026,17 @@ moves_loop: // When in check, search starts here
|
|||
|
||||
history += 2 * thisThread->mainHistory[us][from_to(move)];
|
||||
|
||||
lmrDepth += history / 7208;
|
||||
lmrDepth = std::max(lmrDepth, -2);
|
||||
|
||||
// Futility pruning: parent node (~13 Elo)
|
||||
if ( !ss->inCheck
|
||||
&& lmrDepth < 13
|
||||
&& ss->staticEval + 103 + 136 * lmrDepth + history / 53 <= alpha)
|
||||
&& ss->staticEval + 103 + 136 * lmrDepth <= alpha)
|
||||
continue;
|
||||
|
||||
lmrDepth = std::max(lmrDepth, 0);
|
||||
|
||||
// Prune moves with negative SEE (~4 Elo)
|
||||
if (!pos.see_ge(move, Value(-25 * lmrDepth * lmrDepth - 16 * lmrDepth)))
|
||||
continue;
|
||||
|
|
Loading…
Add table
Reference in a new issue