From a516b517d374bb9b4086dd2cc56be8f55d6aeba8 Mon Sep 17 00:00:00 2001 From: aronpetkovski Date: Tue, 15 Jul 2025 14:23:18 +0300 Subject: [PATCH] Simplify eval >= beta condition from NMP It seems that now only checking if static eval is above beta by some margin is all that's necessary. Passed Non-Regression STC LLR: 2.93 (-2.94,2.94) <-1.75,0.25> Total: 227264 W: 58430 L: 58421 D: 110413 Ptnml(0-2): 532, 26559, 59454, 26542, 545 https://tests.stockfishchess.org/tests/view/68763a77432ca24f6388c766 Passed Non-Regression LTC LLR: 2.94 (-2.94,2.94) <-1.75,0.25> Total: 72048 W: 18622 L: 18455 D: 34971 Ptnml(0-2): 26, 7775, 20272, 7908, 43 https://tests.stockfishchess.org/tests/view/687c9f2b6e17e7fa3939b0c5 closes https://github.com/official-stockfish/Stockfish/pull/6175 Bench: 2759840 --- AUTHORS | 1 + src/search.cpp | 4 +--- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/AUTHORS b/AUTHORS index b43a9e5b6..76b4f71ca 100644 --- a/AUTHORS +++ b/AUTHORS @@ -31,6 +31,7 @@ Andy Duplain Antoine Champion (antoinechampion) Aram Tumanian (atumanian) Arjun Temurnikar +Aron Petkovski (fury) Artem Solopiy (EntityFX) Auguste Pop Balazs Szilagyi diff --git a/src/search.cpp b/src/search.cpp index e698e2c7f..c5534924b 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -848,12 +848,10 @@ Value Search::Worker::search( } // Step 9. Null move search with verification search - if (cutNode && (ss - 1)->currentMove != Move::null() && eval >= beta + if (cutNode && (ss - 1)->currentMove != Move::null() && ss->staticEval >= beta - 19 * depth + 389 && !excludedMove && pos.non_pawn_material(us) && ss->ply >= nmpMinPly && !is_loss(beta)) { - assert(eval - beta >= 0); - // Null move dynamic reduction based on depth Depth R = 7 + depth / 3;