Skip to content

Research construction: restored X4 target pairs save 33,800 primitives per orientation (no new kappa) - #901

Merged
Mister-Meeseeks merged 2 commits into
CrocSwap:mainfrom
ToikY:research/complex-x4-compensation-seed39
Oct 13, 2026
Merged

Mister-Meeseeks merged 2 commits into
CrocSwap:mainfrom
ToikY:research/complex-x4-compensation-seed39

Conversation

@ToikY

@ToikY ToikY commented Oct 13, 2026

Copy link
Copy Markdown
Contributor

Finite complex-supplier circuit construction; no new κ. The selected PR799 X4 word’s zero-frame arbitrary-helper compensation shrinks from 6,320 to 3,276 additions, including all target preparation and restoration. Both complete emitted programs save 33,800 real-component primitives under the unchanged binary-Horner lowering.

Full scalar program Original Candidate
Forward real primitives 193,162 159,362
Inverse-transpose real primitives 193,210 159,410
Scalar macros, either orientation 19,197 16,153

The 56-pair schedule implements T⁻¹(Ty + TCh) = y + Ch with arbitrary target/helper dirt. All source accesses, coefficient work, basis changes and clears are paid. No helper is written by the replacement. Every non-scalar event and paid child is unchanged. The reverse positive prefix rises slightly; budgets stay at 55/72 bits.

Reproduce with Python 3.10+ and the standard library:

python3 -I -B research/complex-x4-compensation-pairs/verify.py
python3 -I -B research/complex-x4-compensation-pairs/test_package.py

Expected main marker: PASS_X4_COMPENSATION_PAIRS pairs=56 compensation=6320->3276 saved_real=33800 columns=728+9 orientations=2 no_new_kappa.

Verification covers every literal primitive on 728 logical plus nine arbitrary private input columns, both orientations; an independently implemented sparse integer/dyadic engine checks the full baseline/candidate logical words and compensation boundary. Public dirty helpers restore; inherited private centres/coefficient work erase via charged CLEARs. Nine focused tests pass normally and under -O, including corruption controls, recompression and standalone relocation. A missing-preparation control passes helper-only checking but fails arbitrary-target checking. Selected-record integrity and its five existing tests pass.

The complete 24,864 ordered target-pair/sign census has 2,978 profitable scores; one seed-39 greedy disjoint pass selects 56 pairs. Recipe, census hash, complete prices, prefix bounds and program hashes are reproducible. No matching/circuit optimality claim.

Exact base: f567884. Inputs are unchanged accepted integrated799-replay.tar.gz members, matching PR799’s exact canonical/program pins. Only research/complex-x4-compensation-pairs/ is added. Current main was refreshed unchanged; final PR inventory reaches #897. The API-published tree equals the tested local tree.

Credit Sricharan Vagvala’s #749 for the rational restored target-pair mechanism on earlier JP8, following the #713/#716 binary work; its implementation is not imported. Credit Jeremy Kothe #799, Chafik Boukhalfa #741, icekylinx’s gauge44, and retained compiler/cold/owner contributors. Concurrent Philipp (@mightyOil) #883 changes the preceding 168-macro precondition, which is byte-identical here; its code/saving is not consumed and no combined saving is claimed. #864 frame-only exclusion has different scope.

The accepted conditional κ remains 0.001661634653669567. Production integration needs a typed alternative-compensation step and refreshed bindings, global hosting/invoice and assembly admission. No full supplier cold replay, repository-wide suite, hosted CI or Lean multiplication theorem is claimed. All-size/compiler, realization, hosting, precision/tape, analytic transfer and bit H1–H5 remain inherited.

Prepared for ToikY with substantial OpenAI Codex assistance, including a bounded delegated integer-checker implementation/review. Apache-2.0 and predecessor notices retained. No independent human review claimed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants