interp: evaluate cache-free nominal sizes without recursion

This commit is contained in:
dev committed 2026-10-10 11:05:22 +03:00
1 parent c9064418bd
commit 897f538840
7 files changed
+218 -43

No files matched your search

+4
View File
@@ -471,6 +471,8 @@ The [equality/printing increment](air-type-depth-audit.md#type-equality-and-prin
The [audit-report increment](air-type-depth-audit.md#audit-report-traversal) fixes the capability-kind collector after a verified 65,536-depth module crashes `aji report`. The collector now iterates anonymous edges and retains report contents/order. Uncached nominal/query call paths remain open; Q-059 is not resolved.
The [cache-free nominal size increment](air-type-depth-audit.md#cache-free-nominal-accounted-size-queries) fixes an independently reproduced 32,768-declaration low-level query failure. Uncached queries use temporary explicit continuations, release their metadata and propagate host OutOfMemory separately from arithmetic overflow. Deep queries, 7,168 independent arithmetic comparisons, cached null/partial-cache reads and 54 cached/cache-free verified runtime outcome pairs constrain compatibility. Parsed depth-1,024/4,096 public verification/runtime programmes pass before and after; no old runtime failure at those depths is claimed. Uncached nominal property predicates and remaining public query call paths keep Q-059 open.
## Q-060 — Native recursion while materializing runtime values
The [executed runtime audit](runtime-value-depth-audit.md) confirms that a verified one-byte value with 32,768 length-one nested arrays aborts inside zeroValue under `aji run --fuel 8`, rather than producing a run record. The instruction has not exhausted fuel. Iterative runtime traversal must preserve initialization, value shape, allocator/root lifetimes, collection safety and instruction accounting; adding a depth trap/acceptance limit needs a normative decision. At that baseline, recursive copying, value sizing, collection and serialization were additional audit candidates with unverified failure paths; the increment below records subsequent executed failures. Compiler type repairs in Q-059 do not resolve Q-060.
@@ -484,3 +486,5 @@ The [sharing-preserving copy increment](runtime-value-depth-audit.md#sharing-pre
The [runtime value-size increment](runtime-value-depth-audit.md#runtime-value-size-repair) iterates fixed-array first-element chains with constant state, preserving zero-sized leaves, checked overflow, nominal maximum payloads and the element-before-dynamic-count rule. The previously crashing 32,768-level own.new probe now returns normally with the original one-byte charge; zero authority takes the original failure edge. Deep verified fuel/collection tests, nested-quota AIR/source runs and an independent allocation-size oracle constrain compatibility. Q-060 remains open for output serialization; there is no new normative limit or trap, and Q-059's nominal-query audit remains separate.
The [runtime value JSON increment](runtime-value-depth-audit.md#runtime-value-json-repair) removes recursive value serialization and bypasses the outer stringify's fixed nesting table for internal payloads. Exact encoding/options, outer-container state, writer/allocation failure and deep returned-payload lifetimes are tested; the formerly failing CLI now emits a complete record in deterministic and hosted profiles. All five confirmed Q-060 failure paths have repairs, without a new limit or trap. Q-060 remains open for closing call-path checks, including the inspection-only cache-free public verification/runtime entry path and its connection to Q-059's uncached nominal queries; no verified failure on that path is claimed yet.
The [cache-free runtime increment](runtime-value-depth-audit.md#cache-free-runtime-size-query-path) removes the recursive accounted-size fallback available through public verification/runtime entry. All runtime size callers propagate temporary metadata OOM before authority charging, retaining quota, fuel and ownership behavior. The deep query-only failure is independently reproduced and repaired; verified library entry and cache equivalence are separately tested. Q-060 remains open for closing traversal checks and full per-step validation; no new normative limit, trap or diagnostic is introduced.