From a24da071f0d6128c633febab7df55f14475217c3 Mon Sep 17 00:00:00 2001 From: Gary Linscott Date: Sun, 10 Mar 2013 10:06:39 +0100 Subject: [PATCH] Check for easy move just once Here the rational seems to be that if after one try easy move detection fails then the easy move is not so easy :-) After 15563 games at 60+0.05 ELO: 3.04 +-5.5 (95%) LOS: 97.0% Total: 15563 W: 2664 L: 2528 D: 10371 No functional change. --- src/search.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/search.cpp b/src/search.cpp index 40a887c2..cff8e768 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -293,6 +293,7 @@ namespace { Stack ss[MAX_PLY_PLUS_2]; int depth, prevBestMoveChanges; Value bestValue, alpha, beta, delta; + bool triedEasyMove = false; memset(ss, 0, 4 * sizeof(Stack)); depth = BestMoveChanges = 0; @@ -439,10 +440,12 @@ namespace { // Stop search early if one move seems to be much better than others if ( depth >= 12 && !stop + && !triedEasyMove && PVSize == 1 && ( RootMoves.size() == 1 || Time::now() - SearchTime > (TimeMgr.available_time() * 20) / 100)) { + triedEasyMove = true; Value rBeta = bestValue - 2 * PawnValueMg; (ss+1)->excludedMove = RootMoves[0].pv[0]; (ss+1)->skipNullMove = true; -- 2.39.2