Remove Zobrist::noPawns which is no longer necessary #4344
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This Zobrist key is only used once, to initialize a
Position
'ssi->pawnKey
. Thesi->pawnKey
is then updated with pawn information as board state is changed.The
si->pawnKey
is itself only used in one place:Entry::probe
, where it is used to look into the current thread'spawnsTable
. This is likewise the only place that the thread'spawnsTable
is used.As a result of the above, we can be confident that this particular key can be removed. It's only ever mixed into a key once, and that key is only ever used to index into a hash table that no other key is used for. Therefore its removal cannot possibly lead to colliding with another key from another source.
Bench: 4106793
https://tests.stockfishchess.org/tests/view/63c5cb8418c20f4929c5fd7e