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.
Previously a lot of effort went into ensuring correct input when parsing a move given as part of a 'position' command - this sounds nice, but doesn't really do much. First of all, no GUI or other program would send an incorrect command to begin with, so for a vast majority of use cases there is no point checking it. Secondly, in the event that a poorly formatted input is given, ignoring the input would still not get the engine set up to search the correct position.
As such, this patch simplifies the parsing of moves, speeding up setup, and allowing weiss to (potentially) crash when used incorrectly. This is most likely not gaining any strength as this code runs outside of the timed search.
This also fixes a bug where weiss would crash due to an out of bounds during movegen in long games (total moves > MAXDEPTH). This crash was inconsistent as it would segfault at varying game lengths depending on the memory layout which changed between executions, at least on my windows machine.
No functional change.
ELO | 3.99 +- 5.36 (95%)
SPRT | 10.0+0.1s Threads=1 Hash=32MB
LLR | 2.98 (-2.94, 2.94) [-4.00, 1.00]
Games | N: 9850 W: 3073 L: 2960 D: 3817
http://chess.grantnet.us/viewTest/4491/