]> git.sesse.net Git - stockfish/blobdiff - src/search.cpp
Don't IID when in check also in PvNodes
[stockfish] / src / search.cpp
index 220fff5e10d03e50e74e4052c2f3c9f97bbfd380..af01050212ceca3ef4c9a4225c4952ede31b683b 100644 (file)
@@ -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,