From e2612f9a294a2d9ee2f961ecd52a6c8b9043e989 Mon Sep 17 00:00:00 2001 From: Viren6 <94880762+Viren6@users.noreply.github.com> Date: Sun, 12 Jan 2025 13:00:45 +0000 Subject: [PATCH] Introduce Correction History Quad Extensions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Also modifies the double and triple extension margins with the correction history adjustment. STC Elo Estimate: Elo: -4.40 ± 1.4 (95%) LOS: 0.0% Total: 60000 W: 15230 L: 15990 D: 28780 Ptnml(0-2): 264, 7495, 15168, 6883, 190 nElo: -8.48 ± 2.8 (95%) PairsRatio: 0.91 https://tests.stockfishchess.org/tests/view/6783a3786ddf09c0b4b703a1 Passed 1st VVLTC: LLR: 2.95 (-2.94,2.94) <0.00,2.00> Total: 35736 W: 9354 L: 9088 D: 17294 Ptnml(0-2): 4, 3191, 11212, 3457, 4 https://tests.stockfishchess.org/tests/view/6783a3336ddf09c0b4b7039b Passed 2nd VVLTC: LLR: 2.95 (-2.94,2.94) <0.50,2.50> Total: 36394 W: 9515 L: 9225 D: 17654 Ptnml(0-2): 1, 3271, 11364, 3559, 2 https://tests.stockfishchess.org/tests/view/678395e26ddf09c0b4b70345 closes https://github.com/official-stockfish/Stockfish/pull/5767 Bench: 1567166 --- src/search.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/search.cpp b/src/search.cpp index 9ee9fb79..f20e4f02 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -1070,11 +1070,16 @@ moves_loop: // When in check, search starts here if (value < singularBeta) { - int doubleMargin = 259 * PvNode - 194 * !ttCapture; - int tripleMargin = 90 + 266 * PvNode - 272 * !ttCapture + 107 * ss->ttPv; + int corrValAdj = std::abs(correctionValue) / 262144; + int doubleMargin = 249 * PvNode - 194 * !ttCapture - corrValAdj; + int tripleMargin = + 94 + 287 * PvNode - 249 * !ttCapture + 99 * ss->ttPv - corrValAdj; + int quadMargin = + 394 + 287 * PvNode - 249 * !ttCapture + 99 * ss->ttPv - corrValAdj; extension = 1 + (value < singularBeta - doubleMargin) - + (value < singularBeta - tripleMargin); + + (value < singularBeta - tripleMargin) + + (value < singularBeta - quadMargin); depth += ((!PvNode) && (depth < 15)); }