Threads.stop = true;
}
else if ( Threads.increaseDepth
+ && !mainThread->ponder
&& Time.elapsed() > Time.optimum() * fallingEval * reduction * bestMoveInstability * 0.6)
Threads.increaseDepth = false;
else
// Futility pruning: parent node (~5 Elo)
if ( lmrDepth < 6
&& !inCheck
- && ss->staticEval + 255 + 182 * lmrDepth <= alpha
+ && ss->staticEval + 235 + 172 * lmrDepth <= alpha
&& thisThread->mainHistory[us][from_to(move)]
+ (*contHist[0])[movedPiece][to_sq(move)]
+ (*contHist[1])[movedPiece][to_sq(move)]
- + (*contHist[3])[movedPiece][to_sq(move)] < 30000)
+ + (*contHist[3])[movedPiece][to_sq(move)] < 25000)
continue;
// Prune moves with negative SEE (~20 Elo)
// Step 16. Reduced depth search (LMR, ~200 Elo). If the move fails high it will be
// re-searched at full depth.
if ( depth >= 3
- && moveCount > 1 + 2 * rootNode
+ && moveCount > 1 + rootNode + (rootNode && bestValue < alpha)
&& (!rootNode || thisThread->best_move_count(move) == 0)
&& ( !captureOrPromotion
|| moveCountPruning
r -= ss->statScore / 16384;
}
+ // Increase reduction for captures/promotions if late move and at low depth
+ else if (depth < 8 && moveCount > 2)
+ r++;
+
Depth d = clamp(newDepth - r, 1, newDepth);
value = -search<NonPV>(pos, ss+1, -(alpha+1), -alpha, d, true);