ReviewOS

home-lang/home

perf(ts): retain owned JSDoc attachment results without rescanning trivia

#882
Open chris opened this 8 days ago ·
8 days ago

Follow-up to #854 and #416, distinct from the rejected stateless scanner and unqualified #881 root-index candidates. Exact measured bb4 native profiling retains displayed PCs in leadingJsDocBodyWithStart while resolving real declarations. Investigate reuse of completed syntax attachment results (including misses) keyed by owned source identity and declaration offset, preserving the existing scalar scanner exactly. No layout tuning or repeat-to-win, and no inference of whole-run CPU share from sample windows.

Acceptance: actual source ownership and borrow lifetime, positive/null results, clamped offsets, same/different source slices, source reset and allocator failure. Preserve export/async modifiers, comma declarations, adjacent block/line trivia, comments inside strings and virtual-file boundaries. Keep scalar-equivalence and full diagnostic tests; no weaker negatives, any erasure, new caps, skipped bodies or filename/library/benchmark predicates. Full unfiltered checker/Program/driver/CLI/entrypoint and actual CLI admissions, all full official protocols, unchanged pinned Zod comparison and a frozen exact-parent full official/scaling/independent risk protocol before timing. Adoption requires verified official target gain and no confirmed independent regression, with all raw evidence and README table/docs link. Push only qualified logical Chris-only conventional main commits; universal leadership remains #416 and is not claimed here.

8 days ago

Prototype is now frozen at patch e56746a (unadopted), parent e7ed4c0. It caches completed positive/null trivia attachment results by declaration offset only when input is the retained attached-source slice; other caller slices and allocator failures keep the exact original scalar scanner. Source reset clears borrows; source pointer/length mismatch invalidates results. No scanner rewrite, body skip, type approximation, layout tuning or semantic cutoff. Tests compare every source offset and warm/cold hit, modifiers/comma/trivia/string/virtual-section cases, clamped offsets, foreign slices, same-address reset and every allocation-failure stage. Full unfiltered five-module gates are starting under separate normal600s/3840MB guards. Baseline b251b72 is reusable with explicit evidence: e004->e7 compiler/build module diff is empty; newer commits are docs/evidence only. No timing started or source adoption.

8 days ago

Original checker guard refused before compilation at566MB disk free versus unchanged1024MB floor (exit123). That refusal and logs are retained. Read-only recheck now shows11GiB free, with all known task Zig caches absent. New admission attempt uses a separate capacity-recovered-gates directory and identical600s/3840MB guards; no original output overwrite or guard override. Prototype remains e56746a, unadopted. No compilation or benchmark sample was repeated by this retry: the first guard never started the child. Source/raw/retained b251/bb4 images and unrelated machine data are preserved.

8 days ago

Performance decision is frozen before any timing: exact e7 parent (explicit compiler/build equivalence with b251 image source e004), candidate patch e56746a, all20 official+512/8192 unchanged JS scales,10-pair screens then30-pair independent phases for all22,3 warmups/image. Paired mean-saving95% bootstrap20000/seed882; official128-family JS lower bound must be strictly positive, no wholly negative interval anywhere, and every phase complete. Inconclusive is not equivalence; incomplete cannot qualify, no repeat-to-finish. All semantic/actualCLI/protocol/scaled/unchanged-Zod gates required. Limits remain600s/3840MB/1024-512MB disk. Current checker gate19390 is live after genuine disk recovery; no candidate adoption or timing yet.

8 days ago

All full unfiltered source suites pass on frozen e56746a:4572 checker,265 Program,201 driver,80 CLI,47 entrypoint. Individual guards exit0, peak3401/3180/2893/2821/3055MB respectively; original prestartdisk refusal retained. Current source parent e7 and frozen B251 parent image have explicit empty compiler/build diff from e004 baseline buildsource. Separate-prefix candidate build then complete294 extended/180 protocol/16 scaled/unchanged-Zod checks are now starting under unchanged guards. Original scalar scanner remains intact; positive/null attachment results borrow only the attached source. No timing, source adoption, scanner retuning or negative relaxation yet.

8 days ago

Full qualification completedexit0. Native307e29a5 is frozen from exact e7 parent+e567 patch; installed/retained binaries unchanged. All5165 source tests,294 complete extended checks,180 full six-image protocol5 records and16 unchanged scale controls pass. Full pinned Zod retains exactly235 identities on parent/candidate,0added/0removed, stillunadmitted/untimed. Beginning the fixed880-pair protocol (all20 official+512/8192,10 screen/30 independent pairs,seed882/20000 bootstrap) under unchanged per-phase guards. Adoption withheld until officialJS strictly positive independent CI, no independent loss anywhere and every phase complete. No repeats or easier inputs, original disk refusal preserved.

8 days ago

Rejected and restored; no candidate compiler source adopted. All 44 frozen phases completed: 880 original pairs, 264 warmups, 136 phase admissions, no repeats/filtering. Primary official checkjs independent mean-saving CI -2.001 to +0.011 ms is inconclusive. Independent control-flow, overload and recursive-generics intervals are wholly negative, failing the predeclared adoption rule despite three independent savings. All 5,165 source tests, 294 extended CLI, 180 six-image protocol and 16 scaled admissions passed; full Zod remains unchanged at 233 TS plus two HM9002 identities, unadmitted/untimed. Docs, README table and 1,440-checksum raw archive pushed in 175c6ca. https://github.com/home-lang/home/blob/main/docs/docs/TS_PERFORMANCE.md#owned-jsdoc-attachment-memo-rejected-2026-10-12-utc . Only task-generated .zig-cache was removed; source matches current main, retained images match their prior hashes, current archive and 3,978 prior archive payloads verify. The initial cleanup unchanged-tree check was invalidated by rebasing concurrent main source updates during hashing; reconciliation is retained. Keep issue open for a genuinely different algorithm, not repeat-to-win.

Sign in to comment on this issue.