PawnInfo* PawnInfoTable::get_pawn_info(const Position& pos) const {
- assert(pos.is_ok());
-
Key key = pos.get_pawn_key();
PawnInfo* pi = probe(key);
for (int i = 0; i < 3; i++)
{
r += Shift;
- shelter += BitCount8Bit[(pawns >> r) & 0xFF] * (64 >> i);
+ shelter += BitCount8Bit[(pawns >> r) & 0xFF] << (6 - i);
}
}
kingSquares[Us] = ksq;