Releases: konsolas/ToppleChess
Topple v0.8.1
General
- Lots of code cleanup and refactoring to improve maintainability
- New material hashing scheme
- Replaced custom Syzygy probing code with the Fathom library
- New binaries compiled with LLVM/Clang (much smaller now).
Search
- Optimised move generation of pawns
- Adjusted hash table replacement criteria to favour PV nodes
Strength gains should be in the 5-10 elo range based on self play testing.
Updated evaluation
General
- Rewritten code for sliding move generation
- Simplified CMake code for releases
Search
- Worker threads are now pooled for Lazy SMP
- Fixed singular extensions not correctly excluding moves in PV nodes.
- Slightly updated move ordering
Evaluation
- Removed
kat_table_offset
parameter - Added an additional tapering dimension to evaluation related to pawn structure
- Vectorised evaluation using GCC's vector extensions
- Added evaluation of overprotected pieces
- Texel tuner now generates source code for evaluation parameters
Expected strength gain is ~20 elo based on self play testing. Use the modern
build if it runs, otherwise try popcnt
or legacy
if that doesn't work either.
You can compile Topple from source on other platforms as follows:
git clone https://github.com/konsolas/ToppleChess
mkdir build
cd build
cmake ../ToppleChess
make Topple
Topple uses GCC extensions to C++ and will need a compatible toolchain.
Threat evaluation
General
- Disabled interprocedural optimisation for tests.
Search
- Adjusted parameters in the history heuristic.
- Removed
alpha
parameter from search_zw. - LMR is now enabled for all moves, regardless of whether or not they are quiet.
- Even more aggressive LMR for quiet moves.
- Enabled recursive null move pruning.
- More aggressive razoring, null move pruning, and static null move pruning.
- Removed internal iterative deepening in zero window search.
- Bad captures are now pruned at low depths.
Evaluation
- Moved dynamic pawn evaluation from pawns.cpp to eval.cpp
- Fixed an asymmetry in king safety evaluation
- Rook and Bishop piece square tables now use 4-way symmetry instead of just 2-way symmetry.
- Replaced a bunch of repeated code with loops.
- Implemented evaluation of threats and undefended pieces.
- Decoupled game phase evaluation from material evaluation.
Estimated strength gain is around 30 elo based on self play.
Some minor improvements before TCEC S17
General
- Enabled interprocedural optimisation in CMakeLists.txt
- Default CMake compile now targets
-march=native
- Increased default UCI thread limits (TCEC S17)
- Release binaries are now compiled with GCC 9 on MSYS2.
Search
- Prefetch before hash write in zero window search
- Less aggressive reductions in the root node
Evaluation
- Removed parameters mat_exch_scale and mat_exch_pawn
- Merged material evaluation with PST evaluation.
- Modified king attack area and pawn shield area.
- Retuned parameters with the lichess-quiet set.
Estimated strength gains are around 30 elo on one thread and around 40 elo on 4 threads, based on self play testing.
Outposts
General
- Added the
MoveOverhead
UCI option (standard on many other engines) - Updated README
Search
- Quiescence search now probes the transposition table
- Removed an unnecessary move legality check
- Improved time management for non-repeating time controls
Evaluation
- Added evaluation parameters for outposts, outposts in holes, and outposts on half open files
- Retuned all evaluation parameters
Estimated strength gain is around 25 elo over 0.7.2 based on self play testing, though actual gains are likely to be less.
Improved evaluation
Search
- Added interior node recognisers for material draws
- King position is now included in the pawn hash table
Evaluation
- Added additional parameters for detached, paired and backwards pawns.
- Added linear king-pawn tropism parameters
- Adjusted king safety and blocked pawn evaluation
- Retuned all evaluation parameters
This is same version as the one playing in TCEC S16.
Estimated improvements are around 30 elo over 0.7.1 based on self play testing. Actual gains likely to be less.
Improved search and stability
General
- Updated CMakeLists.txt
- Additional validation on promotions when decompressing and checking for legality
- e.p. moves are now treated as captures
- Configured alignment for structures which are not shared between threads
- XOR trick used to improve the performance of the transposition table with many threads
hashfull
now determined with a sample of the first 4000 entriesMAX_PLY
increased to 255- UCI code now rejects
setoption
commands while a search is running - Removed "Move from Hash" due to regression against weaker engines
- Transposition table is now locked when aging to prevent crashes between games
- Topple's move generator now generates promotions separately to other pawns moves and captures
- Reduced the memory overhead of move generation
- Fixed compilation error for ToppleTune
- Added unit tests for move compression and for the new hash entry structure.
- Fixed a bunch of compilation warnings
Search
- Promotions are now generated with captures to be sorted first
- Removed separate generation stages for killer moves (now treated as quiets)
- Losing captures are now sorted after quiet moves
- Captures sorted by MVV instead of SEE.
- Move generator can now skip quiet moves without generating them
- History heuristic now scales the previous score to prevent high values being reached
- Lower reduction used in LMR if the evaluation is improving
- Added static null move pruning
- History leaf pruning now only allowed at depth 1
- Added late move pruning
- Futility pruning and LMR are now enabled for killer moves
Evaluation
- No change
Based on self play testing, 0.7.1 seems to be around 50 elo stronger than 0.7.0 on a single thread and around 100 elo stronger on 4 threads, though actual increases are likely to be much less.
I'd also like to thank @vshcherbyna for his help with debugging a particular infuriating crash.
Improved evaluation
General
- Optimised threefold repetition checking
- Error messages are now printed to STDERR for easier logging
- Significantly reduced memory overhead in general
- Each thread now gets a thread local pawn hash (1MiB/thread)
- The Move From Hash feature can no longer return empty moves (this was likely the cause of illegal moves in 5-piece Syzygy positions)
- The Move From Hash feature will no longer be used if the hash move leads to threefold repetition
- Updated GCC to 9.1.0 (MSYS2)
- Added a znver2 compile for the upcoming Ryzen 3000 series.
Search
- Quiescence root nodes are no longer counted twice
Evaluation
- Moved pawn structure evaluation to a separate file
- Retuned all parameters
- Added a parameter for candidate passed pawns
- Pawn structure evaluation is now performed setwise with bitboards
- Entries in the pawn hash table have been reduced in size
- King safety evaluation function now allows for attacks up to size 128
This should finally fix the illegal move issue.
Elo gains over 0.6.1 are reasonable, measured to be around +30 against a small gauntlet of 9 engines.
Syzygy fixes
General
- ToppleTune will now compile on linux:
cmake . && make ToppleTune
- Default compilation settings for
Topple
now include-march=native
and-O3
Search
- Fixed issues relating to illegal moves and converting won positions with 5-piece Syzygy tablebases enabled.
- Lower LMR reduction in PV nodes.
Evaluation
- Simplified king piece-square table. The table is now fully symmetric in the middlegame.
- Simplified isolated pawn evaluation: 24 terms to 4 terms.
The elo gain appears to be very small, given that most changes are just bugfixes and simplifications, but they may be larger for tests which use 5-piece tablebases or which don't use tablebase adjudication.
Re-implemented Lazy SMP
General
- Topple will now compile and run successfully on linux:
cmake . && make Topple
- Compilation now takes place with cmake's default options for release builds
- The 'x86-64' build has been replaced with a 'legacy' build which just uses GCC's default -march and -mtune settings.
Search
- Removed YBWC, replaced it with Lazy SMP
- Slightly improved time management
- Uses hash table to find a ponder move even if there is only one legal move
- Implemented "move from hash" which allows Topple to move instantly if there is already an entry of a suitable depth in the hash table.
Evaluation
- No changes
On a single thread, there is a gain of around +5 elo compared to Topple 0.5.0 in self play.
On 4 threads, the improvement seems to be around +120 elo in self play (vs Topple 0.5.0 on 4 threads), though the actual improvement is likely to be less.