Skip to content

Ciekce/Stormphranj

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

26 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Stormphranj

License
GitHub release (latest by date) Commits since latest release

LGBTQ+ friendly trans rights

a work-in-progress UCI shatranj engine based on Stormphrax, with NNUE evaluation trained from zero knowledge starting with random weights

Strength

??

Features

  • standard PVS with quiescence search and iterative deepening
    • aspiration windows
    • check extensions
    • countermoves
    • futility pruning
    • history
      • capture history
      • 1-ply continuation history (countermove history)
      • 2-ply continuation history (follow-up history)
      • 4-ply continuation history
    • internal iterative reduction
    • killers (1 per ply)
    • late move reductions
    • late move pruning
    • mate distance pruning
    • multicut
    • nullmove pruning
    • reverse futility pruning
    • SEE move ordering and pruning
    • singular extensions
      • double extensions
      • triple extensions
      • various negative extensions
    • Syzygy tablebase support
  • NNUE
    • _
  • BMI2 attacks in the bmi2 build, otherwise fancy black magic
    • pext/pdep for rooks
  • lazy SMP
  • static contempt

To-do

  • make it stronger uwu

UCI options

Name Type Default value Valid values Description
Hash integer 64 [1, 131072] Memory allocated to the transposition table (in MB).
Clear Hash button N/A N/A Clears the transposition table.
Threads integer 1 [1, 2048] Number of threads used to search.
UCI_ShowWDL check true false, true Whether Stormphranj displays predicted win/draw/loss probabilities in UCI output.
Move Overhead integer 10 [0, 50000] Amount of time Stormphranj assumes to be lost to overhead when making a move (in ms).
EvalFile string <internal> any path, or <internal> NNUE file to use for evaluation.

Builds

avx512: requires AVX-512 (Zen 4, Skylake-X)
avx2-bmi2: requires BMI2 and AVX2 and assumes fast pext and pdep (i.e. no Bulldozer, Piledriver, Steamroller, Excavator, Zen 1, Zen+ or Zen 2)
avx2: requires BMI and AVX2 - primarily useful for pre-Zen 3 AMD CPUs back to Excavator
sse41-popcnt: needs SSE 4.1 and popcnt - for older x64 CPUs

Alternatively, build the makefile target native for a binary tuned for your specific CPU (see below)

Note:

  • If you have an AMD Zen 1 (Ryzen x 1xxx), Zen+ (Ryzen x 2xxx) or Zen 2 (Ryzen x 3xxx) CPU, use the avx2 build even though your CPU supports BMI2. These CPUs implement the BMI2 instructions pext and pdep in microcode, which makes them unusably slow for Stormphranj's purposes.

Building

Requires Make and a competent C++20 compiler that optionally supports LTO. GCC is not currently supported, so the usual compiler is Clang.

> make <BUILD> CXX=<COMPILER>
  • replace <COMPILER> with your preferred compiler - for example, clang++ or icpx
    • if not specified, the compiler defaults to clang++
  • replace <BUILD> with the binary you wish to build - native/avx512/avx2-bmi2/avx2/sse41-popcnt
    • if not specified, the default build is native
  • if you wish, you can have Stormphranj include the current git commit hash in its UCI version string - pass COMMIT_HASH=on

By default, the makefile builds binaries with profile-guided optimisation (PGO). To disable this, pass PGO=off. When using Clang with PGO enabled, llvm-profdata must be in your PATH.

About

UCI shatranj engine

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published