From 5769509d72ab59d1a1856d035c38d84ecdc6f687 Mon Sep 17 00:00:00 2001 From: Marco Costalba Date: Fri, 9 Aug 2013 08:21:55 +0200 Subject: [PATCH] Fix 'improving' condition Because VALUE_NONE is 30002, it happens that after a check the next move is never an improving one. After this patch bench signature is independent from VALUE_NONE actual value. bench: 4303194 --- src/search.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/search.cpp b/src/search.cpp index bba0cb65..9143f669 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -775,7 +775,10 @@ moves_loop: // When in check and at SpNode search starts from here MovePicker mp(pos, ttMove, depth, History, countermoves, ss); CheckInfo ci(pos); value = bestValue; // Workaround a bogus 'uninitialized' warning under gcc - improving = ss->staticEval >= (ss-2)->staticEval; + improving = ss->staticEval >= (ss-2)->staticEval + || ss->staticEval == VALUE_NONE + ||(ss-2)->staticEval == VALUE_NONE; + singularExtensionNode = !RootNode && !SpNode && depth >= (PvNode ? 6 * ONE_PLY : 8 * ONE_PLY) -- 2.39.2