mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-20 09:06:45 +08:00
Optimize order of a few conditions in search
Also fix size of KingDanger array to reduce memory footprint. Small speed up of around 0.5% No functional change.
This commit is contained in:
@@ -210,7 +210,7 @@ namespace {
|
||||
// in KingDanger[]. Various little "meta-bonuses" measuring the strength
|
||||
// of the enemy attack are added up into an integer, which is used as an
|
||||
// index to KingDanger[].
|
||||
Score KingDanger[512];
|
||||
Score KingDanger[400];
|
||||
|
||||
// KingAttackWeights[PieceType] contains king attack weights by piece type
|
||||
const int KingAttackWeights[PIECE_TYPE_NB] = { 0, 0, 7, 5, 4, 1 };
|
||||
|
||||
Reference in New Issue
Block a user