These reviews are from Crev, a distributed system for code reviews. To add your review, set up cargo-crev.

The current version of shakmaty-syzygy is 0.25.1.

0.15.0 (older version) Rating: Positive Thoroughness: High Understanding: High

by niklasf on 2021-02-24

Probes Syzygy tablebases.

This is a self-assessment. I am the author of this crate.

Soundness: The crate uses no unsafe code. Unlike existing implementations in C/C++, I made a deliberate choice to use the safer pread instead of mmap, despite performance costs.

Panics/DOS: I carefully reviewed the code to ensure that all loops and all recursion is bounded. I used fuzz testing to simulate corrupted tablebase files. Nonetheless, it is best to verify the checksums of tablebase files before use, if only for transmission errors.

Correctness: The test suite compares the probe results of random and hand picked positions with multiple independent implementations (in other languages). The library has also been used by researchers and players (through the https://lichess.org/analysis#explorer and https://syzygy-tables.info frontends) for years, without reported inconsistencies.

I am gradually less confident in the implementation of variant tablebases, simply because they are less popular and used less frequently.

During the development of 7-piece Syzygy tablebases, this library was used successfully to find inconsistencies in the new tablebase files. See http://www.talkchess.com/forum3/viewtopic.php?start=0&t=66797&topic_view=flat for details.

The Syzygy format itself has a stellar reputation in the chess community.

0.13.0 (older version) Rating: Positive Thoroughness: High Understanding: High

by niklasf on 2020-02-27

Show review…

Probes Syzygy tablebases.

This is a self-assessment. I am the author of this crate.

Soundness: The crate uses no unsafe code. Unlike existing implementations in C/C++, I made a deliberate choice to use the safer pread instead of mmap, despite performance costs.

Panics/DOS: I carefully reviewed the code to ensure that all loops and all recursion is bounded. I used fuzz testing to simulate corrupted tablebase files. Nonetheless, it is best to verify the checksums of tablebase files before use, if only for transmission errors.

Correctness: The test suite compares the probe results of random and hand picked positions with multiple independent implementations (in other languages). The library has also been used by researchers and players (through the https://lichess.org/analysis#explorer and https://syzygy-tables.info frontends) for years, without reported inconsistencies.

I am gradually less confident in the implementation of variant tablebases, simply because they are less popular and used less frequently.

During the development of 7-piece Syzygy tablebases, this library was used successfully to find inconsistencies in the new tablebase files. See http://www.talkchess.com/forum3/viewtopic.php?start=0&t=66797&topic_view=flat for details.

The Syzygy format itself has a stellar reputation in the chess community.


Lib.rs has been able to verify that all files in the crate's tarball, except Cargo.lock, are in the crate's repository with a git tag matching the version. Please note that this check is still in beta, and absence of this confirmation does not mean that the files don't match.

Crates in the crates.io registry are tarball snapshots uploaded by crates' publishers. The registry is not using crates' git repositories, so there is a possibility that published crates have a misleading repository URL, or contain different code from the code in the repository.

To review the actual code of the crate, it's best to use cargo crev open shakmaty-syzygy. Alternatively, you can download the tarball of shakmaty-syzygy v0.25.1 or view the source online.