mirror of
https://github.com/opelly27/Stockfish.git
synced 2026-05-20 12:07:43 +00:00
Small micro-optimization in get_pawn_info()
No functional change. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
+4
-5
@@ -303,12 +303,11 @@ PawnInfo* PawnInfoTable::get_pawn_info(const Position& pos) {
|
|||||||
// it cannot be backward. If can capture an enemy pawn or if
|
// it cannot be backward. If can capture an enemy pawn or if
|
||||||
// there are friendly pawns behind on neighboring files it cannot
|
// there are friendly pawns behind on neighboring files it cannot
|
||||||
// be backward either.
|
// be backward either.
|
||||||
|
|
||||||
bool backward;
|
bool backward;
|
||||||
if ( passed
|
if ( (passed | isolated | chain)
|
||||||
|| isolated
|
|| (ourPawns & behind_bb(us, r) & neighboring_files_bb(f))
|
||||||
|| chain
|
|| (pos.attacks_from<PAWN>(s, us) & theirPawns))
|
||||||
|| (pos.attacks_from<PAWN>(s, us) & theirPawns)
|
|
||||||
|| (ourPawns & behind_bb(us, r) & neighboring_files_bb(f)))
|
|
||||||
backward = false;
|
backward = false;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user