mirror of
https://github.com/sockspls/badfish
synced 2025-04-30 00:33:09 +00:00
Another generate_piece_moves() micro optimization
This time on the for loop. Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
parent
5e768e4b0a
commit
af5743837d
1 changed files with 1 additions and 1 deletions
|
@ -576,7 +576,7 @@ namespace {
|
||||||
Square from, to;
|
Square from, to;
|
||||||
Bitboard b;
|
Bitboard b;
|
||||||
|
|
||||||
for (int i = 0; i < pos.piece_count(us, Piece); i++)
|
for (int i = 0, e = pos.piece_count(us, Piece); i < e; i++)
|
||||||
{
|
{
|
||||||
from = pos.piece_list(us, Piece, i);
|
from = pos.piece_list(us, Piece, i);
|
||||||
b = pos.piece_attacks<Piece>(from) & target;
|
b = pos.piece_attacks<Piece>(from) & target;
|
||||||
|
|
Loading…
Add table
Reference in a new issue