Skip to content

Reduce bounded NTT temporary storage from 17,920 to 1,282 (no new κ) - #5886

Merged
Mister-Meeseeks merged 1 commit into
CrocSwap:mainfrom
petalas:research/w2-1022y-wordram-live-storage
Oct 27, 2026
Merged

Mister-Meeseeks merged 1 commit into
CrocSwap:mainfrom
petalas:research/w2-1022y-wordram-live-storage

Conversation

@petalas

@petalas petalas commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Reduce the fixed 512-point bounded NTT multiplier's owned temporary storage by 16,638 words, answering Open next question 2 of David Ganz's #5466.

-temporary words:     17,920
+temporary words:      1,282
 static instructions: 507,701

Claim type: scoped program-refinement proof with a finite source-bound certificate. Address renaming preserves every opcode, branch target and per-input execution count. It preserves operands and exterior memory, including abandoned old temporary addresses, and returns the smaller owned arena and fixed scratch to zero. The original 20 scratch words and 513 output words are additional in both versions.

The new allocation and simulation proof build on #5466's cited bounded multiplication theorem. They do not audit or re-prove that theorem. Interval coloring and simulation are classical; the contribution is their checked refinement of this concrete construction. Original source bytes and predecessor credit remain unchanged.

Evidence

  • Before: 17,920 logical temporaries in the pinned original template. After: 1,282 physical cells, with a matching closed-interval overlap witness at instruction 140274.
  • Nine complete static allocation/renaming certificates, 280 paired dirty-memory executions and eight rejection controls pass. Every single hexadecimal-digit pair is included. Larger templates exercise maximal, zero and unit patterns; their outputs agree with direct integer multiplication.
  • Normal and optimized warning-strict direct checks pass locally in 2.39 and 2.29 seconds. Both registered commands pass; the complete registered replay takes 4.91 seconds locally.
  • Committed-byte/source-history preflight passes at b1b8ce5622a01a8e818defc25c836a440568d707 for 15 package/input files. Official export integrity and an optimized Git-free replay of that export pass. A separate read-only review found no correctness blockers in the new proof and transformation.

From the repository root, with CPython 3.12.15 and the standard library:

~/git/integer-mult-bounds/.venv/bin/python3.12 -B scripts/research_package.py --package research/wordram-live-storage
~/git/integer-mult-bounds/.venv/bin/python3.12 -I -W error -B research/wordram-live-storage/verify.py
~/git/integer-mult-bounds/.venv/bin/python3.12 -I -O -W error -B research/wordram-live-storage/verify.py
~/git/integer-mult-bounds/.venv/bin/python3.12 -B scripts/check_research_commit.py --package research/wordram-live-storage --check-source-history

Expected output: PASS_WORDRAM_LIVE_STORAGE, PASS_REGISTERED_RESEARCH_PACKAGE and PASS_RESEARCH_COMMIT_BYTES.

Limitations

The 1,282-word minimum applies only to the declared whole closed-lifetime allocation rule. It is not an unrestricted storage lower bound. The all-input endpoint conclusion uses the original bounded multiplier theorem as a premise and the new written simulation; finite execution examples do not enumerate all 1,024-bit operands. The nine certified balanced templates are not a census of every asymmetric length pair. Offline generation costs are separate from emitted runtime instructions. No new kappa, selected consumer, selected-supplier admission, complete machine formalization or independent human/formal proof-kernel review is claimed. Lean, Docker, the selected cold replay and the approximate FFT backend were not run.

Open next questions

  • Remove redundant final zeroings with a label-aware rewrite and a complete new instruction count. This PR preserves every original instruction.
  • Consider split lifetimes or last-use operand consumption. Either changes the allocation model and needs its own simulation and lower-bound scope.

Related open work

Refreshed the titles and bodies of this account's open PRs created since the advance CLAIM, including #5887 through #5893. None studies the fixed #5466 NTT temporary arena or computes this allocation quantity.

None is used as a premise, and no additional computations were run to compare their results.

CI notes

For commit b1b8ce5622a01a8e818defc25c836a440568d707, run 40495644209 failed in plan at Onboarding helper tests. All ten failure/error entries are in tests/test_research_current_assignment.py; the final summary is FAILED (failures=8, errors=2, skipped=22).

The two errors are KeyError: 'follow_up_steps' and KeyError: 'catalog_first_step'. The eight failure entries concern the frozen-card count (0 != 16), missing-helper/reference rejection, and sparse-reference receipts. This is the reported shared onboarding failure on main de5ec2e7a6074068452f45b1a191b5c72832df4a; the test file and shared implementation are unchanged by this PR. The same plan failure and skipped replay are also present on #5885. No shared tests or code were changed to address it.

replay was skipped. Hosted replay has not certified this package; only the local package checks reported above have run. No hosted scientific success is claimed.

Merge Danger

Door: two-way

Adds only research/wordram-live-storage/.

Blast Radius: research

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