Skip to content

W-004 spike: phantom capability witnesses — zero-cost use-after-move enforcement in emitted Go (race-verified, preregistered) - #507

Open
limitlessprojects wants to merge 1 commit into
mainfrom
spike/w004-phantom-witnesses
Open

limitlessprojects wants to merge 1 commit into
mainfrom
spike/w004-phantom-witnesses

Conversation

@limitlessprojects

Copy link
Copy Markdown
Owner

Implements the first milestone of W-004 (issue #174, capabilities-replace-the-alias-graph family) — a no-compiler spike per the row's own directive.

What's here

  • spikes/w004-phantom-witnesses/work/witness.go — the encoding hyb emit would synthesize: per-binding zero-size root markers, Live[R]/Moved[R] witnesses, hyUse guards (zero-cost), hyMove consumption, and the W-005 hyClone boundary seam so the two spikes share vocabulary.
  • work/witness_test.go — pre-registered P1–P4 with P4 as the DECLARED falsifier (closure captures), committed in the same commit as the artifact.
  • work/negative/ + run_negatives.sh — use-after-move and loop-backedge double-move must FAIL go build (both do).
  • work/bench_test.go — P1 quantified: 0.347 ns/op, 0 B/op, 0 allocs/op vs plain baseline 0.356 ns/op — inside noise; the witness compiles away.
  • RESULTS.md — preregistration + results + M1 verdict draft + falsifier terms.

Headline verdict

Zero-cost E3003-class enforcement for the non-captured emitted subset is real (the checker becomes a witness producer, the Go type checker enforces for free). P4 fired as predicted: captured uses after move still share storage — the second independent spike (after #370's P4) to converge on that residual, which is exactly what the may-share graph/capture-freeze machinery owns on main.

Race-verified (go test -race -count=2), vet/gofmt clean, negatives compile-rejected.

…enforcement in emitted Go (preregistered P1-P4, P4 falsifier fired as predicted)

P1 CONFIRMED: witnessed move 0.347 ns/op 0 allocs = plain baseline (0.356). P2/P3 confirmed. P4 (declared falsifier) confirmed: captured use after hyMove still shares storage — witnesses own the non-captured subset, may-share graph keeps captures. Negatives compile-rejected (uam.go, backedge.go). go vet/gofmt/race clean.

Second independent convergence with #370's P4 residual — the M1 evidence the capabilities family needed for slot 4.
limitlessprojects pushed a commit that referenced this pull request Oct 17, 2026
…plete, W-004 spike PR #507, W-019/020/021 intake, M1 prep at 21 rows/10 artifacts
@limitlessprojects limitlessprojects added triage:new New arrival (<= 3 days old), awaiting recon triage:wildcard-hold Wildcard Track spike artifact — stays open, never merges (Track 3); window verdicts in MOONSHOT.md labels Oct 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

triage:new New arrival (<= 3 days old), awaiting recon triage:wildcard-hold Wildcard Track spike artifact — stays open, never merges (Track 3); window verdicts in MOONSHOT.md

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant