Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions .claude/board/ISSUES.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ fields, so it still becomes an orphan when its parent closes — which is correc
by design (the caller owns it) and is now safe precisely because this fix makes
`Mask.close()` release an orphan.

## ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW (2026-08-28) — OPEN
## ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW (2026-08-28) — OPEN (its specified remedy FAILED the §5 gate, 2026-09-03)

**Opened late, and the lateness is the first thing worth recording.** v3 W4
requires this issue to be opened **in the same commit** that re-scopes
Expand Down Expand Up @@ -174,6 +174,8 @@ status at all. The row now says **handle-mediated** operation and points at the
contract. The doc had been overclaiming exactly the guarantee this issue exists
to deny.

**2026-09-03.** The per-access probe that would have narrowed this window on `RowStore` was measured at +52.76 ± 1.49 ns/call against a pre-registered N = 40 and does not ship (see `ISS-LGJ-EPOCH-UNCHECKED`). This entry stays OPEN as a *documented, measured* gap: closing it now needs a mechanism that is not one crossing per accessor call — e.g. a per-scan probe on a bulk accessor, or the enforcement wave that makes `Engine.close(long)` unreachable from outside the owning facade — and either is its own plan.

## ISS-LGJ-ROWSTORE-PER-ACCESS-MEASURED — EXPLORATORY, decides nothing

> ⊘ Retitled (Codex P1a on #55). The header read *"the answer is 'not at
Expand Down Expand Up @@ -253,7 +255,7 @@ standing beside it. This is the eighth and the worst shape of it: the entry
*correctly* declared its own run void in one paragraph and then *acted on that
run anyway* in the next. Naming a failure mode does not confer immunity to it.

## ISS-LGJ-BENCH-GATE-PRECEDES-ITS-SUBJECT — the RowStore gate cannot be run as specified
## ISS-LGJ-BENCH-GATE-PRECEDES-ITS-SUBJECT — RESOLVED 2026-09-03 (the gate ran as specified)

Found while starting the benchmark v3 names as the `RowStore` half's gate.
Two ordering problems, both in the plan rather than in the code:
Expand Down Expand Up @@ -285,6 +287,8 @@ of this — it was never cost-gated.

**2026-09-03 — consequence 2 is now mechanised, consequence 1 is answered.** `bench/gate-run.sh` performs the two builds itself: the production tree as shipped, and the production tree with ONE file (`LaneProbe.java`, a package-private no-op seam `RowStore.lane()` calls) swapped for `bench/variants/probed/LaneProbe.java`. Same JDK, same `.so`, same machine, one script — the pinning this entry asked for is the script's own structure. The "implement, measure, then keep or discard" question is answered without a discardable implementation: the probe exists only as the bench variant until a PASS moves it into `java/src/main`, one file copy. `gate.py` refuses a run without the amendment sha, so the pre-registration ordering this entry names is enforced by the tool, not remembered. **Still open:** the amendment naming `N`. Nothing here runs the gate; nothing here decides.

**RESOLVED 2026-09-03.** Both ordering problems dissolved in practice: the amendment (`43a08d1`) preceded both builds and both runs, and the two builds were one script. Verdict FAIL — recorded under `ISS-LGJ-EPOCH-UNCHECKED`.

## ISS-LGJ-EPOCH-UNCHECKED — RESOLVED for the `Mask` half (W1.1)

`Mask.words()` now re-authorises its cached word lane with the substrate
Expand Down Expand Up @@ -537,7 +541,7 @@ headline stated one delivery path where the plan has two (Mask
unconditional, RowStore benchmark-gated).


## ISS-LGJ-EPOCH-UNCHECKED (2026-08-28) — OPEN (council ruled; implementation queued)
## ISS-LGJ-EPOCH-UNCHECKED (2026-08-28) — RESOLVED per half: `Mask` SHIPPED (#53), `RowStore` MEASURED WON'T-FIX (gate FAIL, 2026-09-03)

> **⊕ COUNCIL RULING (2026-08-28, `epoch-recheck-v3.md`).** The 5+3 council
> found this issue's own framing narrower than the truth: an epoch
Expand Down Expand Up @@ -597,6 +601,8 @@ measurement shows the facade's own close-discipline makes it provably
unreachable, downgrade this entry to a documented invariant rather than
a live gap — either resolution needs the measurement, not assumption.

**2026-09-03 — the `RowStore` half is closed by the §5 gate, run as pre-registered.** Amendment A1 (`43a08d1`, N = 40 ns/call, derived from the banked Component H crossing, committed before any run) → `bench/gate-run.sh` (two builds of `java/`, the production `classidAt` in both, #64) → results commit `37e5f95`. `delta +52.76 ± 1.49 ns/call`, powered, **FAIL** by 11 ns beyond budget at the interval's LOWER bound; ratio 7.1× flagged. The remedy §6 specified — per-access re-describe inside `lane()` — costs more than one bare crossing through the real accessor (+17 ns over H's 35.5: the §5.4 inlining barrier, measured), and §6 says *"or this half does not ship."* It does not ship. Both halves now have a status, which is what W4 required; `RowStore`'s cached lanes remain guarded by `closed` alone, and that residue lives in `ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW`, which this closure does NOT absorb. A different mechanism (not per-access describe) would need its own plan and its own gate.

## ISS-LGJ-HOP-LAYOUT-BLOCKS-THE-ALGEBRA (2026-08-27) — RESOLVED (same day; ABI minor 10)

**Found.** By landing R1 (selection as mask algebra) and measuring it.
Expand Down
14 changes: 14 additions & 0 deletions .claude/board/PR_ARC_INVENTORY.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,22 @@
> anti-pattern the imported board rules name. Backfilled below in one
> pass rather than left stale; PR #4 onward gets its entry at merge time.

## PR #65 — the §5 gate, run as pre-registered: FAIL; the RowStore half does not ship (opened 2026-09-03, head `cad704c`)

**Added.** Amendment A1 (`43a08d1`, N = 40 ns/call, derived from the banked H crossing, committed BEFORE any run); the results commit (`37e5f95`) citing it: `before 8.645 ± 0.284`, `after 61.405 ± 1.464`, `delta +52.76 ± 1.49 ns/call`, powered, **FAIL**, ratio 7.10 flagged; the four banked result files; a `Harness` fix (non-quick runs died at startup after #64 — `-1` passed to JMH setters).

**Locked.** `D-LGJ-MMV-1a-rowstore` CLOSED, does not ship (§6). `ISS-LGJ-EPOCH-UNCHECKED` resolved per half; `ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW` stays OPEN as a measured gap; `ISS-LGJ-BENCH-GATE-PRECEDES-ITS-SUBJECT` resolved. §5.4's inlining-barrier hypothesis is now a measurement: +17 ns over the bare crossing.

**Deferred.** Any other mechanism for the RowStore window (per-scan probe on a bulk accessor; the `Engine.close` enforcement wave) — its own plan and gate. The `LaneProbe` no-op seam stays.

**Docs.** Plan §5 Amendment A1; `STATUS_BOARD` `-1a`/`-rowstore`/`-bench` rows; three `ISSUES.md` appends; `CLAUDE.md` scope note storno; `bench/README.md` results; #64 merge sha + its shipped defect recorded.

**Confidence.** High in the number (powered, 5 forks, pre-registered N and estimator, FAIL at the lower bound). The one caveat is stated in the amendment itself: the author had seen a non-evidential smoke figure before deriving N from H.

## PR #64 — the §5 gate instrument: production accessor in two builds, verdict table as a tool (opened 2026-09-03, head `55b7648`)

**Merged 2026-09-03 as `c2b9344`** (recorded post-merge; final head `31576e0`). Zero external review landed — CodeRabbit rate-limited, Bugbot spend-capped, Codex silent. The first real gate run then caught a defect this PR shipped: `Harness` passed `-1` to JMH's fork/iteration setters outside quick mode and every non-quick run died at startup. Fixed in the results PR.

**Added.** `D-LGJ-MMV-1a-bench`. A package-private no-op seam `LaneProbe` in `RowStore.lane()`; its probed twin under `bench/variants/probed/` (re-describe + epoch/length compare, the `Mask.words()` shape); `bench/gate-run.sh` compiling `java/` twice with that one file swapped and running `I_ProductionAccessorGate` (the PRODUCTION `classidAt`, Blackhole, `@Fork(5)`, 65,536 rows) against each; `bench/gate.py`, the §5 verdict table with a self-test pinning the plan's own struck cases, refusing `N ≤ 0`, sub-5×8-sample CSVs, and a missing amendment sha. `Harness` gains `-Dlgj.bench.result` and `LGJ_BENCH_QUICK`.

**Locked.** Both arms are the production accessor as the JIT sees it; no flag, no branch (§5.5). Quick runs are structurally not evidence. A verdict without a preceding amendment sha is not producible by the tool.
Expand Down
6 changes: 3 additions & 3 deletions .claude/board/STATUS_BOARD.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ the membrane / Valhalla cheap addresses / everything else underneath).
| D-id | Deliverable | Status |
|---|---|---|
| D-LGJ-MMV-0 | Mechanical fences: materialization-list gate, §E worker-topology fence (+ reflective arm 2b), SIMD-branch fence — each proven able to fire | Shipped (PR #48, merged `42fba54`) |
| D-LGJ-MMV-1a | Resolve `ISS-LGJ-EPOCH-UNCHECKED`. **5+3 council COMPLETE** — ratified at `.claude/plans/epoch-recheck-v3.md`: ship (a) as a native generation-checked liveness probe (NOT "epoch checking" — the compare is unreachable), arm (ii) scoped contract, six obligations W1-W6, C1's rewritten falsifier, no new ABI symbol on the production path (the one the wave admits is test-only) | **Mask half DONE 2026-08-28** (#53) — `Mask.words()` re-authorises its cached word lane on every use via `lgj_mask_describe` (`resolve_mask_with_parent`, O(1) per whole scan, never per word), disable-run red-then-green. **RowStore half OPEN** — see the row below. Per v3 W4 the issue closes as RESOLVED only when BOTH halves ship, so `ISS-LGJ-EPOCH-UNCHECKED` stays OPEN, scoped to `RowStore`; `ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW` is the W4-paired second entry (opened late, on #55) |
| D-LGJ-MMV-1a | Resolve `ISS-LGJ-EPOCH-UNCHECKED`. **5+3 council COMPLETE** — ratified at `.claude/plans/epoch-recheck-v3.md`: ship (a) as a native generation-checked liveness probe (NOT "epoch checking" — the compare is unreachable), arm (ii) scoped contract, six obligations W1-W6, C1's rewritten falsifier, no new ABI symbol on the production path (the one the wave admits is test-only) | **Mask half DONE 2026-08-28** (#53) — `Mask.words()` re-authorises its cached word lane on every use via `lgj_mask_describe` (`resolve_mask_with_parent`, O(1) per whole scan, never per word), disable-run red-then-green. **RowStore half CLOSED 2026-09-03 — gate FAIL, does not ship** (see the row below). Per v3 W4 the issue closes as RESOLVED only when BOTH halves ship, so `ISS-LGJ-EPOCH-UNCHECKED` resolves for `RowStore` as MEASURED WON'T-FIX (not as shipped); `ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW` is the W4-paired second entry (opened late, on #55) |
| D-LGJ-MMV-1a-mask | The `Mask` half — probe at `words()`, one downcall per whole scan, falsifiable at negligible cost. **Ships regardless of measurement** | Queued |
| D-LGJ-MMV-1a-rowstore | The `RowStore` half — probe per-access inside `lane()`; forced by falsifiability, not chosen on cost (a first-resolve probe is blind to the only scenario it could catch). Does not ship if per-access proves too costly | **Still Queued; the §5 gate was ATTEMPTED on #55 and the run is VOID.** Bench Component H measured a bare `lgj_lane_describe` crossing at **+35.5 ns** over a cached read (CI [34.54, 36.53], 5 forks x 8 iters, rows=65536) — indicative only, on two independent grounds: no `N` was pre-registered (v3 §5.2), and both arms call `Engine.describeLane` directly rather than `RowStore.classidAt`, so they bypass the cached `lanes[]` lookup, `requireOpen`, the `FacetId` null-check and bounds (v3 §5.4: the accessor is an inlining barrier and *that total* is what gates). A first attempt to read a won't-fix verdict off it was withdrawn. **A valid gate needs all three, in order:** an amendment naming `N > 0` committed first; before/after variants of the PRODUCTION accessor in two builds of `java/` (the two-build requirement stands, unamended); a results commit citing that amendment's sha. **2026-09-03: the second and the tooling for the third exist** (`D-LGJ-MMV-1a-bench`); the sole remaining blocker is the first — the `N` amendment, an operator budget, not a measurement |
| D-LGJ-MMV-1a-rowstore | The `RowStore` half — probe per-access inside `lane()`; forced by falsifiability, not chosen on cost (a first-resolve probe is blind to the only scenario it could catch). Does not ship if per-access proves too costly | **CLOSED — DOES NOT SHIP (gate FAIL, 2026-09-03).** The §5 gate ran as specified: Amendment A1 (`43a08d1`, N = 40 ns/call, derived from the banked H crossing) committed FIRST; two builds of `java/` with the production `classidAt` (#64); results commit `37e5f95` citing the amendment. `before 8.645 ± 0.284`, `after 61.405 ± 1.464`, **`delta +52.76 ± 1.49 ns/call`**, powered (`hw 1.49 < 20`), **FAIL** (`delta − hw = 51.27 ≥ 40`); ratio 7.10 flagged. The probe costs ~17 ns MORE through the real accessor than H's bare crossing (35.5) — §5.4's inlining-barrier effect, now measured. Per §6 the half does not ship; `LaneProbe` stays a no-op seam (zero cost, keeps the instrument live). Banked: `bench/results/gate-{before,after}.csv`, `gate-run.txt`, `gate-verdict.txt` |
| D-LGJ-MMV-1a-hook | Test-only ABI export: invalidate a registry slot (bump generation) while deliberately leaking the `Arc`, so the allocation stays mapped — without it W5's disable arm performs a read-after-free and cannot report failure deterministically (Codex P1, PR #49). Full ABI citizen: minor bump, manifest + `abi.md`, lazy holder, `requireMinor`, `OldAbiCompatTest` leg. The ONLY new symbol this wave admits | Queued |
| D-LGJ-MMV-1a-bench | Isolated per-accessor JMH benchmark (build-time variant swap, Blackhole, ≥5 forks) — does not exist today; §5's gate is undecidable without it | **In PR (2026-09-03)** — `bench/gate-run.sh` (two builds of `java/`, one file swapped: the `LaneProbe` seam) + `I_ProductionAccessorGate` (the PRODUCTION `classidAt`, Blackhole, `@Fork(5)`, 65,536 rows) + `bench/gate.py` (the §5 verdict table, self-tested on the plan's own struck cases; refuses `N ≤ 0`, quick runs, and a missing amendment sha). Smoke-verified the swap takes (≈11 → ≈41 ns/call, quick mode, NOT evidence). The gate itself has NOT run: no amendment names `N` |
| D-LGJ-MMV-1a-bench | Isolated per-accessor JMH benchmark (build-time variant swap, Blackhole, ≥5 forks) — does not exist today; §5's gate is undecidable without it | **Shipped (#64, `c2b9344`)** — `bench/gate-run.sh` (two builds of `java/`, one file swapped: the `LaneProbe` seam) + `I_ProductionAccessorGate` (the PRODUCTION `classidAt`, Blackhole, `@Fork(5)`, 65,536 rows) + `bench/gate.py` (the §5 verdict table, self-tested on the plan's own struck cases; refuses `N ≤ 0`, quick runs, and a missing amendment sha). Smoke-verified the swap takes (≈11 → ≈41 ns/call, quick mode, NOT evidence). The gate ran on 2026-09-03 — see `-rowstore`. #64 shipped a Harness defect (non-quick runs died at startup: `-1` passed to JMH setters) that the first real run caught; fixed in the results PR |
| D-LGJ-MMV-1b | Minors 2-4 lazy `Downcalls` holders; `OldAbiCompatTest` minor-1 leg; doctrine "fails cleanly at the call" wording restored by storno | Queued |
| D-LGJ-MMV-2a | Fused single-plane columnar pass — the lab arm's ~10× claim verified through the real ABI, equivalence before timing | Queued |
| D-LGJ-MMV-2b | Register-sweep family (§14-16) answers facet-major; −18 refusal re-pinned two-sided, kept reachable | Queued |
Expand Down
36 changes: 36 additions & 0 deletions .claude/plans/epoch-recheck-v3.md
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,42 @@ could then yield opposite RowStore ship decisions. Ruled:

---

### Amendment A1 (2026-09-03) — the §5.2 cutoff, recorded BEFORE the first run

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Preserve the preregistration commit in this history

In the reviewed history, 02c38a3 has c2b9344 as its sole parent and git merge-base --is-ancestor 43a08d1 02c38a3 is false, so this amendment and the benchmark results are introduced together rather than the amendment preceding them. The separately referenced 43a08d1 → 37e5f95 chain is only a sibling history and is not preserved by this commit. Under this file's own §5.2 rule, that makes the run void, yet the same change records the FAIL verdict and closes the RowStore work as measured won't-fix; preserve the three-commit ancestry or repeat the run after an amendment committed in this history.

Useful? React with 👍 / 👎.


**`N = 40 ns` per accessor call.** Estimator, as ruled above: `hw_delta =
sqrt(hw_before² + hw_after²)`, independent arms. Instrument:
`bench/gate-run.sh` + `I_ProductionAccessorGate` (#64); verdict function:
`bench/gate.py`, which requires this amendment's commit sha and refuses a
run without it.

**Derivation, so the number can be overruled on its reasoning rather than
re-litigated from nothing.** The budget is derived from a measurement that
predates the instrument and is already banked — Component H's bare
`lgj_lane_describe` crossing: **+35.5 ns, 99.9% CI [34.54, 36.53]** (#55,
`jmh-results-H`, 5 forks × 8 iterations, rows = 65,536). The RowStore probe
is by construction ONE such crossing per accessor call (the `Mask.words()`
shape, #53: re-describe, compare, no second resolve), and `classidAt` is a
documented low-level inspection accessor, *"never an execution engine"*
(root `CLAUDE.md`). The budget therefore admits exactly one crossing at
its measured CI ceiling plus ~10% for the accessor's own overhead around
it — `36.53 × 1.1 ≈ 40.2`, rounded down to a whole number — and admits
nothing beyond that: a probe that costs two crossings, or that perturbs
the surrounding loop by more than that margin, FAILS.

**What this amendment is not.** It is not derived from the instrument's
own output. A quick-mode smoke run of `gate-run.sh` (1 fork, 2 iterations,
refused by `gate.py` as sub-threshold — `bench/README.md` § "The §5 gate")
was performed on 2026-09-03 while validating the instrument, before this
amendment, and showed ≈ +30 ns. That run is not evidence and this number
is not fitted to it: the derivation above uses H alone and would yield
40 ns had the smoke run never happened. Stated because §5.2's ordering
rule is about *information*, not just commit order, and a reader deserves
to know the author had seen a non-evidential number. If the operator
judges that contamination disqualifying, strike this amendment and
re-derive; the gate run must then be repeated after the new commit.

**Power precondition this implies:** `hw_delta < 20 ns`.

## 6. THE RESOLUTION

Ship **(a), renamed and re-scoped**, under arm **(ii)**:
Expand Down
6 changes: 6 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,12 @@ build):
- **`RowStore`** does **not**: its `lanes[]` reads consult only the
Java-side `closed` boolean, a strictly weaker, non-generation-checked
mechanism. `ISS-LGJ-EPOCH-UNCHECKED` stays OPEN, scoped to `RowStore`.
⊘ **2026-09-03:** the per-access probe was measured (+52.76 ± 1.49
ns/call, pre-registered N = 40, `epoch-recheck-v3.md` Amendment A1) and
FAILS; per §6 that half does not ship. `ISS-LGJ-EPOCH-UNCHECKED` is
now RESOLVED for `RowStore` as measured won't-fix — the mechanism above
is the SHIPPED state, not a pending one — and the residue is
`ISS-LGJ-CACHED-DESCRIPTOR-CROSS-THREAD-WINDOW`, still OPEN.

⊘ Struck: the earlier claim that this path reads "with NO further registry
call" and that `epoch` "is currently unconsulted anywhere in `src/main`".
Expand Down
9 changes: 8 additions & 1 deletion bench/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,14 @@ cd bench && ./gate.py --n <N> --amendment <sha> results/gate-before.csv results/
evidence), and requires the sha of the amendment that recorded `N` — a run whose `N` was chosen
after the numbers is not pre-registered and this tool will not bless it.

**What has NOT happened:** the gate has not been run as evidence. No amendment names `N`, and §5.2
**The gate ran on 2026-09-03** (Amendment A1 `43a08d1`, N = 40 ns/call, committed first; results
commit cites it). `before 8.645 ± 0.284`, `after 61.405 ± 1.464`, **delta +52.76 ± 1.49 ns/call**,
powered, **FAIL**; ratio 7.10 flagged. The RowStore probe does not ship. Banked in
`results/gate-{before,after}.csv`, `gate-run.txt`, `gate-verdict.txt`. The seam stays a no-op so
the instrument stays runnable. Below is the pre-run text, kept as the record of what was claimed
before the number existed.

**What had NOT happened as of #64:** the gate had not been run as evidence. No amendment names `N`, and §5.2
says that commit must precede both runs. A quick-mode smoke run on 2026-09-03 (1 fork, 2
iterations — refused by `gate.py` by design) showed the swap takes: before ≈ 11 ns/call, after ≈
41 ns/call, consistent with H's +35.5 ns bare crossing. That is a plumbing check, not a
Expand Down
2 changes: 2 additions & 0 deletions bench/results/gate-after.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
"Benchmark","Mode","Threads","Samples","Score","Score Error (99.9%)","Unit","Param: rows"
"com.adaworldapi.lancegraph.bench.I_ProductionAccessorGate.classidAt","avgt",1,40,61.404759,1.464256,"ns/op",65536
2 changes: 2 additions & 0 deletions bench/results/gate-before.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
"Benchmark","Mode","Threads","Samples","Score","Score Error (99.9%)","Unit","Param: rows"
"com.adaworldapi.lancegraph.bench.I_ProductionAccessorGate.classidAt","avgt",1,40,8.645018,0.284185,"ns/op",65536
Loading