moveCountPruning = moveCount >= futility_move_count(improving, depth);
if ( !captureOrPromotion
- && !givesCheck
- && (!PvNode || !pos.advanced_pawn_push(move) || pos.non_pawn_material(~us) > BishopValueMg))
+ && !givesCheck)
{
// Reduced depth of the next LMR search
int lmrDepth = std::max(newDepth - reduction(improving, depth, moveCount), 0);
// search without the ttMove. So we assume this expected Cut-node is not singular,
// that multiple moves fail high, and we can prune the whole subtree by returning
// a soft bound.
- else if ( eval >= beta
- && singularBeta >= beta)
+ else if (singularBeta >= beta)
return singularBeta;
}
&& pos.pawn_passed(us, to_sq(move)))
extension = 1;
+ // Last captures extension
+ else if ( PvNode
+ && PieceValue[EG][pos.captured_piece()] > PawnValueEg
+ && pos.non_pawn_material() <= 2 * RookValueMg)
+ extension = 1;
+
// Castling extension
if (type_of(move) == CASTLING)
extension = 1;
&& ( !captureOrPromotion
|| moveCountPruning
|| ss->staticEval + PieceValue[EG][pos.captured_piece()] <= alpha
- || cutNode))
+ || cutNode
+ || thisThread->ttHitAverage < 384 * ttHitAverageResolution * ttHitAverageWindow / 1024))
{
Depth r = reduction(improving, depth, moveCount);