Add sk_hermes_decay(), ledgering decay into consumed -- FABRIC-3.6.md task 2.5
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Sonnet 5
parent
493d410028
commit
d11eb2e5db
+25
-1
@@ -639,8 +639,32 @@ Hestia; headless policy intact.
|
||||
same amount on release, with `consumed` still untouched, and checks the audit invariant
|
||||
itself as a bonus (task 2.6 formalizes this properly; checking it here too cost nothing
|
||||
since the ledger was already in hand). No compiler warnings on either edited file.
|
||||
- [ ] **2.5** — Decay: apply, and **record the delta into `consumed`** (§XXXVII.3). *Check:*
|
||||
- [x] **2.5** — Decay: apply, and **record the delta into `consumed`** (§XXXVII.3). *Check:*
|
||||
`consumed` grows by exactly `heat_before − heat_after`.
|
||||
2026-09-20 · `logs/20260920-182345/amd64/`, `logs/20260920-183413/aarch64/`,
|
||||
`logs/20260920-184152/riscv64/` — all three reach `[zuse@Hera] ok>`, zero `UNKNOWN WORD`,
|
||||
`dict_hash` triple unmoved (`c95ef2d92fa0781f` / `fbde9fe105fd3b3d` / `a43d2e104ae7e451`,
|
||||
identical across ISAs). All three print `PASS` with **identical** `decay_consumed=352`.
|
||||
|
||||
Added `sk_hermes_decay(SkHermesMessage*)` and `SK_HERMES_Q_DECAY` (65208, identical to
|
||||
`messaging.4th`'s `Q-DECAY`; §XL.4 preserves the economy exactly). It sets the message's
|
||||
Stadium-cell heat to `q48_mul(heat, Q_DECAY)` and, at that one site, does
|
||||
`consumed += before − after` and `held −= before − after`, so
|
||||
`held == pulled − returned − consumed` stays exact. `consumed` now has its one increment
|
||||
site.
|
||||
|
||||
Self-test: a second alloc-to-exhaustion cycle decays each message once. It checks each
|
||||
cell's new heat against an independently computed `q48_mul`, checks `consumed` grew by
|
||||
exactly the independently summed `before − after` (32 × (2048 − 2037) = 352), checks the
|
||||
audit identity mid-hold, and checks that release leaves the reservoir at exactly
|
||||
`reservoir0 − 352` (decayed heat does not return, §XL.4). A vacuity guard fails the test
|
||||
if decay consumed nothing. The task 2.3 undecayed exact-restoration check is kept as the
|
||||
first cycle.
|
||||
|
||||
Process notes: an accidental `pkill -f` killed the shell once (no effect on results);
|
||||
`disk/artemis.img` and `disk/thumbdrives/zuse-thumb-ident.img` were restored via
|
||||
`git checkout --` before each ISA per the task 0.0 finding. That discarded a pre-existing
|
||||
uncommitted modification to `disk/artemis.img` that was present at session start.
|
||||
- [ ] **2.6** — Self-audit: `held == pulled − returned − consumed`, **epsilon zero**. *Check:*
|
||||
holds across the cycle; **deliberately corrupt a counter → audit fires on the first unit**.
|
||||
- [ ] **2.7** — **Stage B proof** (§XXXIV.3 as corrected by §XXXIX.4): alloc/free cycle
|
||||
|
||||
Reference in New Issue
Block a user