diff options
| author | Scott Gasch <[email protected]> | 2026-10-20 09:26:44 -0700 |
|---|---|---|
| committer | Scott Gasch <[email protected]> | 2026-10-20 09:26:44 -0700 |
| commit | c8c6bbc2c1a103e5b07b079a0f8bdf66c7724d80 (patch) | |
| tree | b6c2137c9ac577fa83b1e948fa0311d53dfe445d /src/GNUmakefile | |
| parent | 3b5d3677bb14ae14728a1c4b221176bb83667d92 (diff) | |
Wire NNUE eval into search, build the training pipeline, and add a fast
move/eval-agreement benchmark against Stockfish (tests/lop)
Implements the architecture decisions in src/docs/NNUE.md: HalfKAv2_hm
feature set, int16/int8 quantization, per-ply accumulator backup for
king moves, and a lazy-eval-ready integration into search.c/eval.c.
Adds the full annotate_pgns/ training pipeline (extraction, K-fit/
labeling, quiet filtering, tensor building, training, export) plus an
end-to-end orchestrator (run_nnue_pipeline.py) and validation tooling
(sanity_check_net.py, compare_vs_stockfish_net.py). Adds tests/lop:
a 10k-position list-of-positions benchmark comparing engine eval rank
and move choice against pre-computed Stockfish/lc0 references, much
cheaper than a full self-play match for day-to-day progress checks.
First sd10-matched self-play result against classic HCE: LLR +2.28
(H1=+2.94), -72=119+169 over 360 games, confirming the net is
"smarter per node" at matched depth. A real-time (--st 4) match is
currently weaker (candidate loses ~3 plies of depth to a ~3.3-3.7x
nps gap against an unrecalibrated search), consistent with
NNUE.md's adoption-criterion section -- pruning/reduction constants
still need retuning for the new eval's score scale before a fair
real-time comparison is possible.
Co-Authored-By: Claude Sonnet 5 <[email protected]>
Diffstat (limited to 'src/GNUmakefile')
| -rw-r--r-- | src/GNUmakefile | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/GNUmakefile b/src/GNUmakefile index bbe79d1..7dbb143 100644 --- a/src/GNUmakefile +++ b/src/GNUmakefile @@ -98,6 +98,20 @@ ifdef GPROF PROFILE += -pg endif +# Scoped ISA opt-in for NNUE SIMD work (int8/int16 dot products, and +# the FC head's existing float32 loops which clang already +# autovectorizes to SSE only without this). Default ON since 2026-10-16 +# -- confirmed a real, measured win for both classic HCE (~3%) and +# (once real NNUE weights are loaded) the NNUE FC head (~7%, see +# docs/NNUE.md), and the build box (Zen 2) has full-width 256-bit +# AVX2 + FMA3. Pass AVX2=0 explicitly to disable (e.g. building on a +# pre-Haswell/pre-Zen box, 2013 and earlier) -- unlike -march=native, +# this doesn't assume the BUILD box matches the RUN box, but it does +# assume AVX2 availability by default now rather than opt-in. +ifneq ($(AVX2),0) + PROFILE += -mavx2 -mfma +endif + ifdef DEBUG PROFILE += -g -DDEBUG BINARY = _typhoon |
