Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

better for cache #564

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/attacks.c
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ BitBoard PINNED_MOVES[64][64];

BitBoard PAWN_ATTACKS[2][64];
BitBoard KNIGHT_ATTACKS[64];
BitBoard BISHOP_ATTACKS[64][512];
BitBoard ROOK_ATTACKS[64][4096];
BitBoard BISHOP_ATTACKS[64][513];
BitBoard ROOK_ATTACKS[64][4097];
BitBoard KING_ATTACKS[64];
BitBoard ROOK_MASKS[64];
BitBoard BISHOP_MASKS[64];
Expand Down Expand Up @@ -524,4 +524,4 @@ inline BitBoard AttacksToSquare(Board* board, int sq, BitBoard occ) {
PieceBB(QUEEN, WHITE) | PieceBB(QUEEN, BLACK))) | //
(GetRookAttacks(sq, occ) & (PieceBB(ROOK, WHITE) | PieceBB(ROOK, BLACK) | // Rook + Queen
PieceBB(QUEEN, WHITE) | PieceBB(QUEEN, BLACK)));
}
}
4 changes: 2 additions & 2 deletions src/attacks.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ extern BitBoard PINNED_MOVES[64][64];

extern BitBoard PAWN_ATTACKS[2][64];
extern BitBoard KNIGHT_ATTACKS[64];
extern BitBoard BISHOP_ATTACKS[64][512];
extern BitBoard ROOK_ATTACKS[64][4096];
extern BitBoard BISHOP_ATTACKS[64][513];
extern BitBoard ROOK_ATTACKS[64][4097];
extern BitBoard KING_ATTACKS[64];
extern BitBoard ROOK_MASKS[64];
extern BitBoard BISHOP_MASKS[64];
Expand Down