mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-21 01:27:16 +08:00
Simplify and speed up previous patch
Use an optinal argument instead of a template parameter. Interestingly, not only is simpler, but also faster, perhaps due to less L1 instruction cache pressure because we don't duplicate the very used SEE code path. No functional change.
This commit is contained in:
@@ -1225,11 +1225,11 @@ split_point_start: // At split points actual search starts from here
|
||||
continue;
|
||||
}
|
||||
|
||||
// Prune moves with negative or equal SEE.
|
||||
// Also prune moves with positive SEE where capturing loses a tempo and SEE < beta - futilityBase.
|
||||
// Prune moves with negative or equal SEE and also moves with positive
|
||||
// SEE where capturing piece loses a tempo and SEE < beta - futilityBase.
|
||||
if ( futilityBase < beta
|
||||
&& depth < DEPTH_ZERO
|
||||
&& pos.see_asymm(move, beta - futilityBase) <= 0)
|
||||
&& pos.see(move, beta - futilityBase) <= 0)
|
||||
{
|
||||
bestValue = std::max(bestValue, futilityBase);
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user