Skip to content

Price QQ16 scratch access and stream bank-major sweeps - #2722

Merged
Mister-Meeseeks merged 1 commit into
CrocSwap:mainfrom
petalas:research/qq16-scratch-travel-20261015
Oct 16, 2026
Merged

Mister-Meeseeks merged 1 commit into
CrocSwap:mainfrom
petalas:research/qq16-scratch-travel-20261015

Conversation

@petalas

@petalas petalas commented Oct 15, 2026

Copy link
Copy Markdown
Contributor

Summary

PR #2709 leaves the physical seek cost of QQ16 output-slice scratch access open. This source-bound package prices its two scalar sweeps and supplies one paid streaming variant.

unchanged per-site word, bank-major: 8564*N^2 + 306*N - 2 steps
unchanged per-site word, site-major: 9300*N - 432 steps
24 extra unit ADDs, bank-major streaming: 11866*N - 2840 steps

Eight scratch subtractions use an existing dirty Z0 output and restore it exactly. The variant needs no additional payload array in the declared word-address model. It raises the complete added local scalar allowance from 17,280 to 17,472 and requires exclusive W-bank ownership across each whole window. Native events remain unchanged.

The package includes a proof for every positive integer N, a pinned compressed source word, exact receipts, a standalone checker and registered replay. Credit ywz65/PR #2709 and #2540, commdata2338/PR #2651, and the retained QQ16 lineage. Direct source head is d7749c49e967b214537c0bd832e435e177e21d4f; exact pins and provenance are in SOURCES.json and TASK.json.

Evidence

  • Before: PR Reuse QQ16 output slices under an explicit scratch-access contract #2709's access contract leaves seeks and staging unpriced.
    After: exact coefficients derived from the literal word, checked against address traces at N=1..32,64, with rational dirty-state and restoration controls at N=2,3,5.
  • CPython 3.12.15 registered normal/optimized replay and four artifact tests pass. Direct Python 3.14 checks and Ruff E/F/B/UP/SIM pass. Git-free read-only export, source/typed-receipt corruption and equivalent recompression are covered.
python3.12 -I -B scripts/research_package.py --package research/qq16-scratch-travel

Priority revision 5, task joint-query-controller; initial main c3c94c2ea, checked main 78ceed413, relevant guidance/inputs unchanged. Claim and handoff. Complete overlap snapshots and limitations are recorded in TASK.json.

Merge Danger

Door: two-way.

Blast Radius: isolated.

One new research package and its opt-in replay. No selected-frontier change. These are fixed-protocol address tariffs, not global schedule minima or a runtime/kappa improvement. Whole-window ownership/retention, bit arithmetic, instruction control, surrounding native placement and a complete caller remain open. No selected cold replay, native-kernel admission or Lean proof is claimed. New work is Apache-2.0.

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