Skip to content

v1.2.0 — Day 3: Enriched Tables, O(1) Regalloc, Branchless Library

Choose a tag to compare

@oisee oisee released this 28 Mar 23:08
· 126 commits to main since this release

Day 3 Birthday Marathon Release

New: Enriched Register Allocation Tables (37.6M shapes)

  • data/enriched_{4v,5v,6v_dense}.enr.zst — 78MB compressed
  • 15 operation-aware cost metrics per shape
  • 43% of "feasible" shapes lack accumulator (hidden ALU infeasibility!)
  • Smart CALL save: 17T avg (was 34T) = 50% reduction
  • Width-aware: u8/u16/u32 scoring

New: O(1) Regalloc Architecture

  • Signature: (interference_shape, operation_bag) → hash lookup
  • 91% of functions resolve in O(1), 8% GPU partition, 1% Z3
  • Validated on 820-function production compiler corpus
  • 246 unique signatures (prediction <500 confirmed)

New: GPU Partition Optimizer

  • Brute-force optimal graph splits for 7-20v functions
  • All 172 corpus functions (7v+) partitioned optimally
  • 14v in 0.7s, 19v in 7min, 20v in 30min

New: Paper v2 — "Register Allocation as a Solved Game"

  • regalloc_paper.pdf — 1574 lines, 15 chapters, 12 Mermaid diagrams
  • Updated with corpus validation and partition results
  • regalloc_paper.epub — mobile-friendly version

New: Branchless Library (exhaustive verified)

  • ABS (6i,24T), MIN/MAX (8i,32T), CMOV (6i,24T)
  • div3 EXACT: A×171>>9 (zero error, no lookup table!)
  • Z flag WRITE-ONLY proof (CY = only viable branchless bool)
  • SBC A,A mask trick = foundation of all branchless Z80

New: Focused Search + Vulkan

  • gray_decode EXACT (13 ops, <1s on Vulkan RX 580)
  • sqr_hi ±29, cbrt ±16, sin_q1 ±68
  • Per-target minimal op pools: fewer ops → deeper search

Updated: Chronicle

  • chronicle.epub — 862 lines, 11 chapters, days 1-3

Also included (from v1.0.0/v1.1.0)

  • z80_compiler_never_guesses.epub/pdf/html — original article

Full changelog: v1.1.0...v1.2.0