mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 08:43:09 +00:00
evaluate_passed_pawns() micro-optmization
No functional change, only a bit faster. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
90585a8a36
commit
cbfbf25d1b
1 changed files with 1 additions and 1 deletions
|
@ -937,7 +937,7 @@ namespace {
|
||||||
ebonus += Value(square_distance(theirKingSq, blockSq) * 6 * tr);
|
ebonus += Value(square_distance(theirKingSq, blockSq) * 6 * tr);
|
||||||
|
|
||||||
// If the pawn is free to advance, increase bonus
|
// If the pawn is free to advance, increase bonus
|
||||||
if (pos.square_is_empty(blockSq))
|
if (tr != 0 && pos.square_is_empty(blockSq))
|
||||||
{
|
{
|
||||||
b2 = squares_in_front_of(us, s);
|
b2 = squares_in_front_of(us, s);
|
||||||
b3 = b2 & ei.attacked_by(them);
|
b3 = b2 & ei.attacked_by(them);
|
||||||
|
|
Loading…
Add table
Reference in a new issue