mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 00:33:09 +00:00
Fix TB guard
even if beta is below TB range, once we return probcutBeta with beta + 390 we can return wrong TB value, and guard against ttData.value being `VALUE_NONE` closes https://github.com/official-stockfish/Stockfish/pull/5499 bench: 1440277
This commit is contained in:
parent
986173264f
commit
bb4b01e306
1 changed files with 2 additions and 1 deletions
|
@ -894,7 +894,8 @@ moves_loop: // When in check, search starts here
|
||||||
// Step 12. A small Probcut idea (~4 Elo)
|
// Step 12. A small Probcut idea (~4 Elo)
|
||||||
probCutBeta = beta + 390;
|
probCutBeta = beta + 390;
|
||||||
if ((ttData.bound & BOUND_LOWER) && ttData.depth >= depth - 4 && ttData.value >= probCutBeta
|
if ((ttData.bound & BOUND_LOWER) && ttData.depth >= depth - 4 && ttData.value >= probCutBeta
|
||||||
&& std::abs(beta) < VALUE_TB_WIN_IN_MAX_PLY)
|
&& std::abs(beta) < VALUE_TB_WIN_IN_MAX_PLY
|
||||||
|
&& std::abs(ttData.value) < VALUE_TB_WIN_IN_MAX_PLY)
|
||||||
return probCutBeta;
|
return probCutBeta;
|
||||||
|
|
||||||
const PieceToHistory* contHist[] = {(ss - 1)->continuationHistory,
|
const PieceToHistory* contHist[] = {(ss - 1)->continuationHistory,
|
||||||
|
|
Loading…
Add table
Reference in a new issue