ValueType vt;
Value bestValue, value, oldAlpha;
Value refinedValue, nullValue, futilityBase, futilityValueScaled; // Non-PV specific
- bool isPvMove, inCheck, singularExtensionNode, givesCheck, captureOrPromotion, dangerous, isBadCap;
+ bool isPvMove, inCheck, singularExtensionNode, givesCheck, captureOrPromotion, dangerous;
int moveCount = 0, playedMoveCount = 0;
int threadID = pos.thread();
SplitPoint* sp = NULL;
}
}
- // Bad capture detection. Will be used by prob-cut search
- isBadCap = depth >= 3 * ONE_PLY
- && depth < 8 * ONE_PLY
- && captureOrPromotion
- && move != ttMove
- && !dangerous
- && !move_is_promotion(move)
- && abs(alpha) < VALUE_MATE_IN_PLY_MAX
- && pos.see_sign(move) < 0;
-
// Step 13. Make the move
pos.do_move(move, st, ci, givesCheck);
// Probcut search for bad captures. If a reduced search returns a value
// very below beta then we can (almost) safely prune the bad capture.
- if (isBadCap)
+ if ( depth >= 3 * ONE_PLY
+ && depth < 8 * ONE_PLY
+ && mp.isBadCapture()
+ && move != ttMove
+ && !dangerous
+ && !move_is_promotion(move)
+ && abs(alpha) < VALUE_MATE_IN_PLY_MAX)
{
ss->reduction = 3 * ONE_PLY;
Value rAlpha = alpha - 300;