Author: Diogo de Oliveira Almeida
Deep Becky 2.0 what's new?
Deep Becky 2.0 is a major strength upgrade over version 1.2, adding Lazy SMP multi-threading for parallel search on multi-core CPUs. The search was significantly enhanced with Singular Extensions, ProbCut, Null Move Verification, and many LMR refinements. The transposition table was completely redesigned with a more efficient 10-byte entry format, and evaluation gained incremental PSQT and quadratic king safety.
Highlights
Multi-Threading (Lazy SMP)
- ThreadPool with UCI
Threadsoption (1–256 threads) - Per-thread Position copy with independent killers, history, and pawn hash — zero contention
- Vote-based best thread selection combining score + depth across all threads
- Condition variable parking for zero idle CPU cost
- TT is the only communication channel between threads
Ponder Support
- UCI option
Ponder(true/false) for continuous analysis during opponent's turn - Ponder move extraction from PV/TT, output with
bestmove ... ponder ...
Search
- Singular Extensions at depth ≥ 6: single (+1), double (+2), and MultiCut pruning
- ProbCut at depth ≥ 5: shallow capture verification to prune large beta excess
- Null Move Verification Search at depth ≥ 14 to prevent zugzwang errors
- IIR (Internal Iterative Reduction) replacing IID, with cut-node awareness
- CutNode tracking for IIR and LMR adjustments
- Enhanced LMR: history-based, cut-node (+2), singular (-2), TT-capture adjustments
- Root best move tracking per-thread (safe in Lazy SMP)
- Aggressive null move R formula:
(854 + 68*depth)/258 + min((eval-beta)/192, 3)
Transposition Table Redesign
- 10-byte entries (down from 16) — 50% more entries per MB
- 3 entries per 32-byte cluster (cache-line aligned)
- PV node flag stored in genBound8
- Static eval stored (
eval16) — saves evaluate() calls on TT hits - 16-bit packed move format (from:6+to:6+type:2+promo:2)
- Max hash increased to 32768 MB
Evaluation
- Incremental PSQT: piece-square tables updated in makeMove/undoMove
- Non-linear king safety: quadratic danger scaling (
attackUnits²/3) with attacker synergy - Endgame mating eval: KQ vs K, KR vs K with king-to-corner guidance
- Static eval in TT: reuses stored eval to skip evaluate() calls
- Improved pawn shield bonuses (+15/-18 front, +10/-12 side)
History Heuristic
- Gravity formula:
entry += bonus - entry * |bonus| / 16384(bounded updates) - History malus: negative update for non-best quiet moves at beta cutoffs
Time Management
- Winning endgame time extension for deeper mate search
- Mate search extension: pushes optimum toward maximum (≥ 80% of max)
- Improved contempt side handling (not stored in TT eval)
UCI & Build
setoption name Threads value N(1–256)setoption name Ponder value true/falseponderhitcommand support- Thread count in UCI info output
- Default hash: 64 MB
- Binary:
deepbecky-v2.0-windows-x64.exe - 27 source files (13 .cpp + 13 .h + Makefile)
Result
Version 2.0 represents a major leap in playing strength. Lazy SMP multi-threading provides near-linear scaling on multi-core CPUs, while Singular Extensions, ProbCut, and the redesigned transposition table allow the engine to search deeper and more efficiently. The quadratic king safety model and endgame mating evaluation ensure more accurate positional and tactical judgment.

Comments
Post a Comment