From: Marco Costalba Date: Sun, 7 Jul 2013 11:45:46 +0000 (+0200) Subject: Don't IID when in check also in PvNodes X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=58aee9a9ea522cd9eb40b6a4cc888e37e2da54c5;ds=sidebyside Don't IID when in check also in PvNodes This tiny functional change allows to nicely simplify things. Performed at 50% in short TC: LLR: -0.43 (-2.94,2.94) Total: 46406 W: 9681 L: 9565 D: 27160 And succesfully passed long TC reverse test: LLR: -2.95 (-2.94,2.94) Total: 4945 W: 858 L: 937 D: 3150 bench: 4507230 --- diff --git a/src/search.cpp b/src/search.cpp index 220fff5e..af010502 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -512,7 +512,7 @@ namespace { assert(splitPoint->bestValue > -VALUE_INFINITE && splitPoint->moveCount > 0); - goto split_point_start; + goto moves_loop; } bestValue = -VALUE_INFINITE; @@ -583,7 +583,7 @@ namespace { if (inCheck) { ss->staticEval = ss->evalMargin = eval = VALUE_NONE; - goto iid_start; + goto moves_loop; } else if (tte) @@ -736,12 +736,10 @@ namespace { } } -iid_start: // When in check we skip early cut tests - // Step 10. Internal iterative deepening if ( depth >= (PvNode ? 5 * ONE_PLY : 8 * ONE_PLY) && ttMove == MOVE_NONE - && (PvNode || (!inCheck && ss->staticEval + Value(256) >= beta))) + && (PvNode || ss->staticEval + Value(256) >= beta)) { Depth d = depth - 2 * ONE_PLY - (PvNode ? DEPTH_ZERO : depth / 4); @@ -753,7 +751,7 @@ iid_start: // When in check we skip early cut tests ttMove = tte ? tte->move() : MOVE_NONE; } -split_point_start: // At split points actual search starts from here +moves_loop: // When in check and at SpNode search starts from here Square prevMoveSq = to_sq((ss-1)->currentMove); Move countermoves[] = { Countermoves[pos.piece_on(prevMoveSq)][prevMoveSq].first,