targeted-mutation 0.0.0-stage → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (63) hide show
  1. package/LICENSE +201 -0
  2. package/NOTICE +21 -0
  3. package/README.md +111 -2
  4. package/bin/tmt-compile.mjs +46 -0
  5. package/bin/tmt.mjs +117 -0
  6. package/build/typescript-syntax/LICENSE.txt +55 -0
  7. package/build/typescript-syntax/ThirdPartyNoticeText.txt +193 -0
  8. package/build/typescript-syntax/typescript-syntax.cjs +43 -0
  9. package/docs/analysis.md +218 -0
  10. package/docs/compiler.md +462 -0
  11. package/docs/development.md +61 -0
  12. package/docs/how-it-works.svg +188 -0
  13. package/docs/l1.md +94 -0
  14. package/docs/performance.md +647 -0
  15. package/docs/releasing.md +48 -0
  16. package/package.json +49 -4
  17. package/src/analysis.mjs +689 -0
  18. package/src/assertion-session.mjs +93 -0
  19. package/src/assertion-strength.mjs +795 -0
  20. package/src/builtin-mutations.mjs +755 -0
  21. package/src/builtin-switches.mjs +642 -0
  22. package/src/change-undone.mjs +524 -0
  23. package/src/cli-output.mjs +166 -0
  24. package/src/compiler-compat.cjs +108 -0
  25. package/src/compiler-maps.cjs +60 -0
  26. package/src/compiler-routes.cjs +391 -0
  27. package/src/compiler.cjs +98 -0
  28. package/src/compiler.mjs +1 -0
  29. package/src/conventional.mjs +172 -0
  30. package/src/displacement.mjs +19 -0
  31. package/src/extract.mjs +135 -0
  32. package/src/fallback-process.mjs +14 -0
  33. package/src/in-parallel.mjs +20 -0
  34. package/src/lean-replay.mjs +39 -0
  35. package/src/operator-analysis.mjs +123 -0
  36. package/src/playwright.mjs +139 -0
  37. package/src/probe-runtime.mjs +50 -0
  38. package/src/probe.mjs +170 -0
  39. package/src/prototype.mjs +230 -0
  40. package/src/regex-mutations.mjs +102 -0
  41. package/src/runner-process.mjs +59 -0
  42. package/src/runtime-binaries.mjs +50 -0
  43. package/src/scope.mjs +202 -0
  44. package/src/source-text.mjs +49 -0
  45. package/src/standard-plan.mjs +308 -0
  46. package/src/standard-runner.mjs +185 -0
  47. package/src/standard-session.mjs +362 -0
  48. package/src/standard-setup.mjs +20 -0
  49. package/src/targeted-gaps.mjs +85 -0
  50. package/src/threshold.mjs +185 -0
  51. package/src/trace-buffer.mjs +126 -0
  52. package/src/typescript-bindings.mjs +243 -0
  53. package/src/typescript-compiler.mjs +59 -0
  54. package/src/typescript-extraction.mjs +354 -0
  55. package/src/typescript-grammar.mjs +923 -0
  56. package/src/vitest-reporter.mjs +64 -0
  57. package/src/vitest.mjs +262 -0
  58. package/src/witness-analysis.mjs +234 -0
  59. package/src/witness-contracts.mjs +110 -0
  60. package/src/witness-discovery.mjs +239 -0
  61. package/src/witness-fixtures.mjs +149 -0
  62. package/src/witness-order.mjs +83 -0
  63. package/src/witness-rules.mjs +254 -0
@@ -0,0 +1,647 @@
1
+ # Performance measurements
2
+
3
+ ## Mutation runs compared with StrykerJS
4
+
5
+ A Vitest session decides mutations inside running workers instead of starting one Vitest run for each ([how mutations run on Vitest](analysis.md#how-mutations-run-on-vitest)). The table compares whole command runs of `--mutators full` with StrykerJS and its Vitest runner (`coverageAnalysis: perTest`). In every row both tools produced the same number of mutations and the same count of each verdict.
6
+
7
+ | Project | Mutations | StrykerJS | `--mutators full` |
8
+ | --- | ---: | ---: | ---: |
9
+ | Sample, one source file and one test file | 220 | 20.0 s, 33.7 s | 3.1 s, 6.1 s |
10
+ | Sample, twelve source files and twelve test files | 2,640 | 120.8 s | 19.9 s |
11
+ | jsdom UI library, a store module with three test files (StrykerJS configured with 4 workers) | 85 | 58.4 s, 78.3 s | 14.5 s, 28.6 s |
12
+ | Same library, a router module with one test file (2 workers) | 160 | 144.2 s | 21.1 s |
13
+ | Firestore data library, five utility modules with six test files (1 worker) | 210 | 93.0 s | 14.1 s |
14
+
15
+ Each pair of numbers in a cell is one round, StrykerJS first and this tool directly after it. The two libraries are private projects with their own StrykerJS 10.0.0 configuration, used as it is, on Vitest 4.1; the samples use StrykerJS 10.1.1 with its default concurrency on Vitest 4.0.18. The host, an Apple M5 Max with 18 cores and Node 24.14.0, was carrying other work during every run (load average 17 to 50), so the times are slower than on an idle machine and vary between rounds. With one worker on each side the store module took 118.8 s and 157.8 s with StrykerJS and 22.7 s and 37.5 s with this tool. The [raw rounds](../evidence/performance/stryker-comparison.json) include earlier states of this tool.
16
+
17
+ Where the time goes in the store module's run (85 mutations, 44 tests, about 9 s on a quieter round): the baseline run takes 2 to 3 s, loading Vitest and the first instance 0.4 to 1 s, the project copy about 0.5 s, and the trials 3 to 5 s. Vitest's own breakdown of that suite is 0.3 s of transforms against 1.0 s of jsdom setup and 0.6 s of tests. In a profile of the single-file sample the worker thread spent 0.77 s on 190 mutations, a quarter of it waiting for the main thread. The remaining time is test code, module evaluation and process start, so faster byte scanning (SIMD or assembly in the parser) would not change these totals.
18
+
19
+ To reproduce the sample rows, install `vitest`, `@stryker-mutator/core` and `@stryker-mutator/vitest-runner` in a Vitest project, add a `stryker.conf.json` with the Vitest runner and `perTest` coverage analysis, and run `scripts/bench-stryker-comparison.sh PROJECT 3`.
20
+
21
+ ## Full Pulse parser migration
22
+
23
+ The ordinary and standalone builds now compile the complete parser extracted from F★ and Pulse. The generated C uses KaRaMeL's tail-call loop lowering. The direct Custard C experiment exhausted the stack on a 1 MiB whitespace source. The adopted pipeline passed the source-limit regression matrix, including the same input.
24
+
25
+ Each comparison alternates nine samples on an Apple M5 Max with Node 24.14.0 and fixture-trained PGO. The first-process runs start with source buffers in memory and disable the Node compile cache. The warm run does not force garbage collection between samples. The former Low★ implementation is `8fbd469` and the former Yuku runtime is `8592705`.
26
+
27
+ | Workload | Warm, Low★ → Pulse | First extraction, Low★ → Pulse | First extraction, Yuku → Pulse |
28
+ | --- | ---: | ---: | ---: |
29
+ | Vite | 11.02 → 11.47 ms | 42.06 → 42.63 ms | 46.64 → 42.43 ms |
30
+ | mreact | 58.75 → 59.92 ms | 116.16 → 117.78 ms | 147.10 → 117.78 ms |
31
+ | tachyon-dom | 21.41 → 22.12 ms | 66.31 → 66.98 ms | 70.09 → 66.98 ms |
32
+
33
+ Warm medians rose by 2.0–4.0%, and cold medians rose by 1.0–1.4% relative to Low★. First extraction remains 4.4–19.9% faster than the former Yuku runtime. Both implementations returned identical candidate, diagnostic and extraction metadata records for 8,549 tracked files and 3,303 unique captured inputs with each logical-rule setting. See the [paired samples and corpus details](../evidence/m1/pulse-parser.json).
34
+
35
+ ## Independent JavaScript and TypeScript corpora
36
+
37
+ The audit reads pinned Git blobs from Fastify, Vue, React, Ant Design, Material UI, RxJS, Zod, esbuild, and SWR Firestore. Across all 2,896 audited files, the shipped extractor matched full TypeScript and Yuku on acceptance and ordered UTF-8 candidate fields. A separate walk of the full TypeScript AST checked candidate spans on accepted, syntactically clean inputs. The audit includes JavaScript, CommonJS script mode, TypeScript, and TSX. It excludes the selected projects' test and fixture directories and React's Flow-annotated JavaScript. It records JavaScript files that required an explicit TSX dialect. Declaration files, generated files and conformance harnesses are counted separately.
38
+
39
+ Across the 2,530 application and tooling source files, native coverage rose from 2,232 to 2,316. The native route now emits 834 of 1,375 candidates, up from 721. The TypeScript route handled all 13 observed JSX disabled-disjunction candidates. The expanded grammar recognizes ordinary top-level enums and general statement sequences in explicit script mode with script restrictions on static imports and exports. The pinned esbuild decorator harness matches Yuku after the compatibility grammar correction. The five earlier corpora also passed the logical-rule audit across 8,549 files.
40
+
41
+ Extraction measurements alternate nine pairs on an Apple M5 Max with Node 24.14.0 and fixture-trained native PGO. Cold timing starts with source buffers in memory, includes importer and parser loading, and disables the compile cache. Both versions produced the same acceptance and candidate fingerprints on these workloads.
42
+
43
+ | Workload | Source files | Warm | First extraction |
44
+ | --- | ---: | ---: | ---: |
45
+ | Fastify CommonJS | 29 | 12.69 → 9.60 ms | 62.37 → 53.12 ms |
46
+ | Vue | 232 | 43.01 → 27.60 ms | 122.33 → 89.12 ms |
47
+ | React | 241 | 60.54 → 49.63 ms | 146.72 → 131.58 ms |
48
+
49
+ First extraction on the established Vite, mreact, and tachyon-dom inputs changed by less than 0.6% from the previous Pulse baseline. Focused analysis reuses the runtime-module syntax decision for an unchanged subject and reads the package type in each new trial copy. Repeated preflight on the same 49,314-byte file took 1.417 → 0.011 ms per lookup, excluding test execution. The clone-on-write copy experiment was within 1% for both measured layouts, including the one with 96 MiB of assets. Focused mutations still use their own Vitest startup and independent project copy.
50
+
51
+ Run the [independent corpus audit](../scripts/audit-independent-extraction.mjs) against local checkouts at the recorded revisions. See the [pinned revisions, exact counts, and paired samples](../evidence/m1/independent-extraction.json).
52
+
53
+ ### Server, typed library, and framework cohorts
54
+
55
+ The three additional cohorts cover 4,275 pinned files from 14 repositories. The extractor agrees with full TypeScript and Yuku on acceptance and ordered candidate records with the logical rule both enabled and disabled. A separate TypeScript AST walk checks the byte ranges. With the nine established repositories, the same audit covers 7,171 files. The counts in the table exclude declaration and generated files.
56
+
57
+ | Cohort | Native source files | Native candidates |
58
+ | --- | ---: | ---: |
59
+ | Express, Commander, Undici, ESLint, Lodash, Prettier | 770 / 910 | 1,046 / 1,679 |
60
+ | Hono, tRPC, Solid, TanStack Query, Zustand, date-fns | 1,638 / 1,837 | 1,131 / 1,561 |
61
+ | Astro and Svelte | 859 / 1,018 | 580 / 881 |
62
+
63
+ The Pulse grammar changes raised native coverage from 568 files and 648 candidates to 770 files and 1,046 candidates in the server cohort. Declaration-file handling fixed six valid inputs previously rejected by the compatibility parser. The framework cohorts cover the repositories' JS and TS implementation sources. Astro and Svelte template files are outside this audit.
64
+
65
+ | Workload | Source files | Warm extraction | First extraction |
66
+ | --- | ---: | ---: | ---: |
67
+ | ESLint | 421 | 125.33 → 41.01 ms | 244.71 → 121.08 ms |
68
+ | Undici | 102 | 47.63 → 42.87 ms | 133.43 → 127.69 ms |
69
+ | Hono | 223 | 28.96 → 27.86 ms | 100.23 → 95.30 ms |
70
+ | Astro | 642 | 41.32 → 40.94 ms | 109.10 → 107.99 ms |
71
+ | Svelte | 376 | 70.46 → 65.40 ms | 168.00 → 157.65 ms |
72
+
73
+ This comparison uses `55e3975` as the baseline, nine alternating pairs, fixture-trained PGO on Apple M5 Max, and Node 24.14.0. Cold timings include parser loading and use in-memory source buffers with the Node compile cache disabled. Acceptance and ordered candidate records match across both versions. The Vite, mreact, and tachyon-dom cold medians changed by at most 1.1%. A verified packed-byte reader experiment showed no consistent benefit on the measured corpora and was dropped.
74
+
75
+ The audit accepts bare repositories and reads regular Git blobs at fixed revisions. Use bare fetches from the listed upstream URLs. This keeps upstream package scripts, Git hooks, and automation instructions out of the workflow. For unfamiliar corpora, run the audit in a rootless container with no network, a read-only root, explicit read-only input mounts, a bounded temporary directory, dropped capabilities, and memory and process limits. Use a snapshot of this tool and its lockfile-pinned oracle dependencies. The package for the target platform can be verified against the lockfile's SHA-512 integrity before extraction, with lifecycle scripts disabled.
76
+
77
+ The audit was repeated on Linux arm64 in rootless Podman for all 14 new repositories with both logical-rule settings. The addon was built from checked-in generated C inside the isolated process, and the same audit produced zero differences.
78
+
79
+ The [audit results, pinned revisions, and paired samples](../evidence/m1/wider-extraction.json) include the exact checked paths. The oracles can share gaps in JavaScript acceptance. For example, Node rejects some invalid Unicode regex escapes that both compatibility oracles accept. The native path declines the tested invalid forms.
80
+
81
+ ## Direct parser comparison
82
+
83
+ These measurements use 1,784 pinned source files from Hono, ESLint, Astro, Svelte and Vite. TMT, Yuku 0.19.0, SWC Next `@swc-next/parser` 0.7.0, and Oxc 0.159.0 returned identical ordered results for 1,853 comparison candidates. Each range and replacement is checked before timing. The table reports milliseconds per corpus as warm extraction / first extraction.
84
+
85
+ | Workload | TMT baseline | Current TMT | Yuku | SWC Next | Oxc standard | Oxc lazy |
86
+ | --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: |
87
+ | Hono | 45.60 / 119.65 | 43.12 / 118.43 | 30.33 / 63.54 | 26.76 / 57.42 | 57.15 / 84.67 | 8.01 / 30.17 |
88
+ | ESLint | 62.57 / 143.33 | 48.48 / 131.20 | 51.63 / 92.46 | 36.86 / 75.05 | 92.98 / 115.01 | 14.35 / 37.84 |
89
+ | Astro | 66.92 / 145.87 | 55.07 / 134.24 | 69.40 / 122.42 | 51.02 / 84.11 | 135.68 / 170.65 | 20.28 / 45.97 |
90
+ | Svelte | 94.42 / 211.64 | 86.14 / 204.59 | 52.57 / 94.37 | 36.03 / 78.39 | 91.12 / 121.87 | 16.51 / 41.09 |
91
+ | Vite | 16.45 / 50.04 | 13.57 / 48.90 | 35.96 / 81.75 | 28.30 / 60.14 | 69.63 / 98.27 | 9.48 / 32.16 |
92
+
93
+ The benchmark used seven rotating warm trials and seven fresh-process trials on Linux arm64 under rootless Podman on an Apple M5 Max with Node 24.14.0. Fresh-process timing begins with sources in memory, before the parser import, with the Node compile cache disabled. Warm extraction includes syntax and early-error checking and candidate collection from each parser. Yuku and SWC Next use the public JS AST, and both Oxc modes use their public visitors. The raw JSON separately records warm parse-to-program timings for all external parsers. These timings include reading diagnostics and `program.body.length`. Lazy-return APIs can defer materializing child AST nodes.
94
+
95
+ Oxc lazy has the lowest median on every complete corpus. On the 1,572 files accepted directly by Pulse, TMT has the lowest first-extraction median in all five cohorts and the lowest warm median in four. Warm ESLint medians on that subset are 12.37 ms for TMT and 12.29 ms for Oxc lazy. This slice isolates the native route. It excludes the costs of handling files outside its grammar.
96
+
97
+ The new BMP regex production moved 77 date-fns files into Pulse. The generator changes moved another 12 ESLint files and five Astro files onto the native route. The full 23-repository independent audit still agrees in both rule settings. The largest identified remaining fallback family was a private identifier in a class field declaration. The refusal probe identified this as the first stopping token in 84 inputs before the generator change. The count covers first refusals. In a separate feasibility probe, replacing only private-name prefixes in scratch copies let 70 files with 136 candidates transfer to native extraction with exact output parity. Production support must also validate private names against the correct enclosing class, including forward declarations and duplicate or undeclared names.
98
+
99
+ Use [the pinned input builder](../scripts/prepare-parser-benchmark.mjs) with a directory of Git repositories named `hono`, `eslint`, `astro`, `svelte`, and `vite`. Set `TMT_BENCH_INPUTS` to its output directory and `TMT_BENCH_BASELINE` to the built baseline’s `src/extract.mjs`, then run `node scripts/bench-parser-comparison.mjs hono eslint astro svelte vite`. Add `--native-only` before the cohort names to reproduce the native slice. The external parsers are benchmark inputs only. The recorded run used fixed package versions and verified their registry integrity, with no package lifecycle scripts and no network access during execution. See the [exact inputs, package digests, audit counts, and timing samples](../evidence/m1/parser-comparison.json).
100
+
101
+ ### Private names, wider grammar, and NEON
102
+
103
+ The same pinned 1,784 files and 1,853 ordered comparison candidates were measured again. TMT improves across all five complete workloads. Vite is fully native and has the lowest warm and first-extraction medians among the compared engines. On the 1,669 files accepted directly by Pulse, TMT has the lowest median in both timing modes for every cohort. All timings in the table are milliseconds per corpus, warm / first extraction.
104
+
105
+ | Workload | Native files | Previous TMT | Current TMT | Oxc lazy |
106
+ | --- | ---: | ---: | ---: | ---: |
107
+ | Hono | 207 / 223 | 46.22 / 118.30 | 34.60 / 98.26 | 7.80 / 30.13 |
108
+ | ESLint | 409 / 421 | 49.78 / 131.19 | 28.55 / 82.94 | 14.55 / 37.84 |
109
+ | Astro | 626 / 642 | 56.21 / 134.06 | 29.67 / 83.54 | 20.50 / 45.90 |
110
+ | Svelte | 305 / 376 | 88.41 / 203.64 | 76.41 / 180.17 | 15.36 / 40.87 |
111
+ | Vite | 122 / 122 | 14.07 / 48.62 | 8.65 / 10.33 | 9.41 / 31.76 |
112
+
113
+ The comparison uses `1fdc764` as the baseline. It uses the same Node 24.14.0 Linux arm64 rootless Podman environment and package pins as the previous five-cohort comparison. Both binaries use GCC optimization and LTO. The current build enables NEON for confirmed scalar comment and quoted-string loops. In a paired macOS arm64 addon-only pilot, that specialization improved warm medians by 1.9–3.0%. The compiled code contains AArch64 vector compares and a lane minimum reduction. The full-run comparison includes the TypeScript compatibility path wherever needed. The test suite compares production NEON and scalar packed records on every byte value and lane, and verifies fallback to the original generated C if one of the scalar loops changes.
114
+
115
+ Vite’s remaining files entered the native path through the new destructuring defaults, namespace star re-exports, and adjacent class overload syntax. Most of the Astro and ESLint gains followed private-name validation. In Svelte, 71 files still require compatibility. A separate binding-spelling probe recovered 26 files with 24 exact candidates when function-wide lexical and hoisted var names were disjoint. A 64-bit fingerprint reduced that estimate to 20 files and 17 candidates because collisions would delegate. The probe rewrites `var` only in temporary inputs. Production support must preserve the original variable scoping rules.
116
+
117
+ The [pinned comparison records, native subset, and feasibility probes](../evidence/m1/native-overtake.json) contain all raw samples.
118
+
119
+ ### Complete ESLint and Vite extraction
120
+
121
+ On the same pinned inputs, the Pulse parser now covers every ESLint and Vite source file. Both workloads have the lowest warm and fresh-process extraction median of all five engines in the same rootless Linux arm64 comparison. All five corpora still match on all 1,853 comparison candidates, including their order, replacements and UTF-8 spans. The table gives warm and first-extraction medians in milliseconds per complete corpus.
122
+
123
+ | Workload | Native files | TMT | Yuku | SWC Next | Oxc standard | Oxc lazy |
124
+ | --- | ---: | ---: | ---: | ---: | ---: | ---: |
125
+ | Hono | 210 / 223 | 26.49 / 79.95 | 30.81 / 62.94 | 26.58 / 58.34 | 57.39 / 83.52 | 8.24 / 30.26 |
126
+ | ESLint | 421 / 421 | 14.13 / 16.09 | 51.22 / 89.79 | 36.44 / 74.55 | 91.12 / 114.16 | 15.58 / 37.60 |
127
+ | Astro | 631 / 642 | 26.62 / 72.81 | 69.69 / 121.72 | 51.96 / 83.81 | 127.78 / 170.56 | 18.91 / 45.59 |
128
+ | Svelte | 354 / 376 | 49.40 / 125.39 | 54.90 / 92.64 | 36.53 / 81.91 | 93.42 / 122.04 | 15.39 / 40.90 |
129
+ | Vite | 122 / 122 | 8.85 / 10.54 | 38.87 / 82.11 | 30.43 / 62.17 | 72.32 / 101.34 | 9.50 / 33.06 |
130
+
131
+ The complete ESLint lead follows native support for computed class method names, a single prototype setter, strict-script block functions, constructor expressions, trailing argument commas, four Unicode regular-expression category aliases and flat object assignments. Function-local and module-level `var` support moved much of Svelte to Pulse. The complete Hono, Astro and Svelte workloads still include compatibility parsing and trail Oxc lazy. The 23-repository independent extraction audit agreed with the development references for both logical-rule settings. See the [native coverage, parser samples, and audit results](../evidence/m1/native-grammar-coverage.json).
132
+
133
+ ### Complete native coverage of all five workloads
134
+
135
+ The Pulse path handles all 1,784 pinned source files and produces all 1,853 ordered comparison candidates. The full-workload results agree with Yuku 0.19.0, SWC Next `@swc-next/parser` 0.7.0, and Oxc 0.159.0 in both AST modes. TMT has the lowest warm and first-extraction median on every workload in two complete runs. The table reports the final run after the class-field computed-key review fix. Times are warm / first extraction in milliseconds per corpus.
136
+
137
+ | Workload | Files | TMT baseline | TMT | Oxc lazy |
138
+ | --- | ---: | ---: | ---: | ---: |
139
+ | Hono | 223 | 43.73 / 118.37 | 7.43 / 9.56 | 8.07 / 30.24 |
140
+ | ESLint | 421 | 50.49 / 131.39 | 14.58 / 16.50 | 15.72 / 37.26 |
141
+ | Astro | 642 | 58.40 / 134.01 | 15.83 / 18.05 | 18.83 / 45.82 |
142
+ | Svelte | 376 | 89.58 / 204.07 | 14.96 / 17.31 | 16.28 / 40.92 |
143
+ | Vite | 122 | 14.07 / 49.02 | 9.19 / 10.87 | 9.68 / 32.34 |
144
+
145
+ Each run uses seven rotating warm trials and seven alternating fresh-process trials under rootless Linux arm64 Podman on an Apple M5 Max. First extraction includes parser loading with the source buffers already in memory and the Node compile cache disabled. The early ESLint warm lead was approximately 0.08 ms, and the final run put it at 1.14 ms. See the [all-engine medians, exact inputs, and raw trials for both runs](../evidence/m1/complete-native-comparison.json).
146
+
147
+ The final Svelte coverage comes from validating hoisted names at each lexical scope boundary. The second-pass log reclaims block-local lexical entries and retains the variables hoisted to the parent. The grammar also handles nested loop labels, collection assignment targets, regular-expression code points and `new.target`. Hono and Astro gained type-only namespace handling, stronger type annotation coverage and completed-module resolution of forward exports. These are extraction measurements for the pinned files. The TypeScript compatibility parser remains available for sources outside the supported grammar.
148
+
149
+ ### Ecosystem expansion
150
+
151
+ The new `ecosystem` audit covers pinned htmx, Alpine.js and Redux Toolkit implementation sources. Additional runs cover mreact and tachyon-dom. Argumentless constructors bring four more Alpine.js files onto the Pulse path. TypeScript non-null assignments move 52 Vue candidates onto Pulse, bringing coverage to 376 of 400. JSX opening attribute trivia brings TanStack Query to 96 of 96 candidates. Legacy regex brackets and escaped surrogate ranges bring tachyon-dom to 338 of 338 candidates across all 94 selected implementation files.
152
+
153
+ The table gives warm and first-extraction medians in milliseconds. The baseline is `c673659`. The run uses seven repetitions under offline rootless Linux arm64 Podman on an Apple M5 Max with Node 24.14.0, with the same candidate comparison as the five-workload benchmark. All six implementations agreed on all ordered records for these sources. First extraction includes parser loading and excludes file I/O. The comparison uses implementation sources and excludes declaration files.
154
+
155
+ | Workload | Native candidates before → after | TMT baseline | TMT | Oxc lazy |
156
+ | --- | ---: | ---: | ---: | ---: |
157
+ | htmx | 0 → 0 / 68 | 20.03 / 76.83 | 19.72 / 76.67 | 1.39 / 22.06 |
158
+ | Alpine.js | 39 → 46 / 51 | 8.84 / 42.80 | 4.70 / 32.05 | 2.60 / 25.20 |
159
+ | Redux Toolkit | 31 → 31 / 34 | 18.72 / 65.41 | 17.84 / 65.21 | 4.39 / 29.11 |
160
+ | mreact | 988 → 988 / 1,001 | 40.34 / 79.80 | 39.73 / 79.11 | 30.99 / 69.25 |
161
+ | tachyon-dom | 316 → 338 / 338 | 18.39 / 54.08 | 9.18 / 10.78 | 9.30 / 36.16 |
162
+
163
+ TMT kept the lowest median in both metrics on Hono, ESLint, Astro, Svelte and Vite. On tachyon-dom it also led both medians, with a 0.12 ms warm lead over Oxc lazy and four wins in seven warm rounds. SWC Next had the fastest first extraction on htmx and Alpine.js. Oxc lazy led both medians on Redux Toolkit and mreact. An independent audit compares the full TypeScript parser and Yuku against TMT with and without logical rules. The [pinned inputs, audit results and raw samples](../evidence/m1/ecosystem-expansion.json) include all compared engines and a separate macOS run.
164
+
165
+ ### Native script extraction and a shared compatibility walk
166
+
167
+ Pulse now handles the full htmx implementation script and all 88 selected Alpine.js implementation files. Leading script `var` declarations start in the expanded reader. On htmx this avoids reading the long initializer twice to discover the automatic semicolon. The larger initial reserve also holds all 68 candidates in the first allocation. Native support for adjacent local overloads and typed global variables recovers the last 13 mreact comparison candidates. The remaining three mreact compatibility files contain no comparison candidates. Optional generic tuple elements and new type signature boundaries move five more Redux Toolkit files to the native path.
168
+
169
+ The benchmark uses seven rotating warm runs and seven fresh-process runs on offline rootless Linux arm64 Podman with Node 24.14.0 on an Apple M5 Max. All compared engines agree on every ordered comparison candidate and UTF-8 span across the ten pinned corpora. Times are warm / first extraction in milliseconds. First extraction includes parser loading with the buffers already in memory and the compile cache disabled.
170
+
171
+ | Workload | Native source files | Native candidates | TMT at `2cba9fe` | TMT | Oxc lazy |
172
+ | --- | ---: | ---: | ---: | ---: | ---: |
173
+ | htmx | 1 / 1 | 68 / 68 | 19.13 / 76.54 | 1.31 / 2.72 | 1.57 / 22.28 |
174
+ | Alpine.js | 88 / 88 | 51 / 51 | 4.72 / 31.75 | 2.62 / 4.11 | 2.89 / 25.09 |
175
+ | Redux Toolkit | 101 / 106 | 31 / 34 | 17.69 / 65.33 | 12.15 / 52.40 | 4.56 / 29.08 |
176
+ | mreact | 318 / 321 | 1,001 / 1,001 | 40.11 / 79.19 | 33.67 / 59.91 | 31.21 / 68.78 |
177
+
178
+ TMT has the lowest first-extraction median on nine workloads and the lowest warm median on six. In this run Oxc lazy leads warm Hono and ESLint by 0.08 and 0.05 ms, respectively. The larger gaps are Redux Toolkit in both metrics and mreact in warm extraction. The shared TypeScript traversal reduced warm medians by 3.7–5.9% on the earlier Redux Toolkit, mreact and tachyon-dom compatibility inputs. It preserves the relative order of context and statement diagnostics at the same byte range. The [raw measurements and audit records](../evidence/m1/script-native-comparison.json) include parser versions, exact input fingerprints and the before-and-after candidate coverage.
179
+
180
+ ### Complete typed ecosystem workloads
181
+
182
+ Pulse handles every selected Redux Toolkit and mreact implementation file and emits all 34 and 1,001 candidates, respectively. The typed extensions cover interface variance, type getters, local interfaces, adjacent class overloads and selected global declarations. The TypeScript compatibility reader now recognizes private names during its existing AST walk and omits the separate private-name validation walk when it found none.
183
+
184
+ The same ten pinned workloads had identical ordered comparison candidates and UTF-8 spans in TMT, Yuku 0.19.0, SWC Next 0.7.0, and Oxc 0.159.0 in both AST modes. TMT had the lowest warm and first-extraction medians on all ten workloads in this run. The table shows the workloads newly reaching complete native coverage. Times are milliseconds for warm / first extraction, with preloaded input buffers and the Node compile cache disabled. The Linux arm64 Podman run used Node 24.14.0 on an Apple M5 Max. Host load varied substantially, so use the raw paired samples to compare these results.
185
+
186
+ | Workload | Native files | Previous TMT | TMT | Yuku | SWC Next | Oxc lazy |
187
+ | --- | ---: | ---: | ---: | ---: | ---: | ---: |
188
+ | Redux Toolkit | 106 / 106 | 304.27 / 581.65 | 36.51 / 50.04 | 432.77 / 352.42 | 386.28 / 416.64 | 148.89 / 806.47 |
189
+ | mreact | 321 / 321 | 193.84 / 190.34 | 169.41 / 97.16 | 907.65 / 851.22 | 711.18 / 551.17 | 297.70 / 330.81 |
190
+
191
+ On Redux Toolkit, TMT improved on its prior extractor in all seven pairs for both measurements. TMT led Oxc lazy in four warm Redux Toolkit pairs and six warm mreact pairs. The independent 28-project audit produced zero mismatches across 7,784 inputs in both logical-rule settings. The [pinned inputs, native coverage, and all measured results](../evidence/m1/complete-typed-corpora.json) record every corpus and competitor.
192
+
193
+ ### Framework and build tool expansion
194
+
195
+ The independent audit includes pinned implementation sources from React Router, Immer, Lit, Rollup, Vitest and Tailwind CSS. Pulse emits all 1,368 comparison candidates on these inputs and handles 1,124 of the 1,125 source files. The table is limited to each audit's implementation-source selection. The Tailwind CSS corpus now reads external `.cts` files as TypeScript module source and recognizes terminal export assignments.
196
+
197
+ | Workload | Native files before → after | Native candidates before → after |
198
+ | --- | ---: | ---: |
199
+ | React Router | 68 → 75 / 75 | 104 → 118 / 118 |
200
+ | Immer | 15 → 16 / 16 | 26 → 26 / 26 |
201
+ | Lit | 107 → 113 / 113 | 18 → 34 / 34 |
202
+ | Rollup | 165 → 271 / 271 | 148 → 236 / 236 |
203
+ | Vitest | 473 → 487 / 488 | 394 → 431 / 431 |
204
+ | Tailwind CSS | 144 → 162 / 162 | 511 → 523 / 523 |
205
+
206
+ Native additions include typed declaration fields, default function overload groups, plain exported interface reopening, explicit resource bindings, decimal property names and a bounded TypeScript default object assertion. The audit compares shipped diagnostic records with full TypeScript wherever both report diagnostics. The independent Yuku oracle compares source acceptance and candidate records.
207
+
208
+ The bounded comment and quoted-string scan now uses SSE2 on x86-64 and NEON on arm64. Scalar and production Node addons matched on every byte and lane within the 16-byte window, including the x86-64 build run under Rosetta. In six translated x86-64 source workloads, native-core CPU time was approximately unchanged. A separate long-comment and long-literal input fell from 0.516 to 0.317 ms under the same translation. The benchmark records describe the translated environment.
209
+
210
+ The initial 16-cohort comparison included 3,519 pinned implementation inputs and 4,713 candidates. Yuku 0.19.0, SWC Next 0.7.0, Oxc 0.159.0 in eager and lazy modes, and both TMT builds emitted the same ordered candidate records. TMT led all four reference paths on 15 cohorts in both measurements. In Vite, it reached 73.72 ms warm and 188.30 ms in a fresh process, compared with Oxc lazy at 66.75 and 152.42 ms. The measurements time extraction from in-memory source buffers. Fresh-process samples include engine loading and exclude the input read and Node startup. The benchmark runs offline in rootless Linux arm64 Podman on an Apple M5 Max, with Node 24.14.0, the compile cache disabled, seven alternating rounds and variable host load.
211
+
212
+ Three Vite files, three Vitest files and one mreact file reached the compatibility parser in the initial comparison because distinct signature names occupied both fingerprint lanes. The third lane restores native extraction in those seven files. Vite and mreact reached 122 of 122 and 321 of 321 native inputs in the measured implementation selections. The remaining Vitest compatibility file contributes zero candidates. A collision in all three lanes still uses compatibility. The [corpus audit and raw comparison samples](../evidence/m1/framework-native-extraction.json) record both builds.
213
+
214
+ The follow-up uses five rotating rounds on the same inputs and checks the same candidate records. It skips the separate AST-only timing passes. TMT has the lowest warm and fresh median in all 16 cohorts. The final independent audit found zero discrepancies across 34 projects and 8,921 inputs in both logical-rule settings. The table shows the TMT median and the fastest reference median for four workloads from the follow-up.
215
+
216
+ | Workload | Warm TMT / fastest reference (ms) | Fresh TMT / fastest reference (ms) |
217
+ | --- | ---: | ---: |
218
+ | Vite | 14.32 / 25.40 (Oxc lazy) | 17.73 / 89.84 (Oxc lazy) |
219
+ | mreact | 50.12 / 77.69 (Oxc lazy) | 106.19 / 731.89 (Oxc lazy) |
220
+ | Vitest | 95.12 / 127.03 (Oxc lazy) | 221.90 / 326.45 (Oxc lazy) |
221
+ | Tailwind CSS | 52.86 / 117.23 (Oxc lazy) | 54.85 / 612.32 (SWC Next) |
222
+
223
+ ## Analysis throughput
224
+
225
+ ### Reusing the syntax projection and reducing Lean input
226
+
227
+ Focused threshold discovery and probe module classification share the 639,522-byte TypeScript syntax projection with compatibility extraction. A matching projection keeps the full compiler unloaded. On an Apple M5 Max with Node 24.14.0, fresh-process syntax work decreased from 596.55 to 154.40 ms across thirteen alternating pairs. Seven paired runs of `analyze` on the eligibility fixture, including Vitest and Lean, had identical full reports and medians of 7.19 and 6.75 seconds. This machine was carrying other work during the run. The [raw syntax and CLI measurement pairs](../evidence/m1/analysis-syntax-projection.json) include the fixture invocation.
228
+
229
+ The threshold batch now transmits the greatest observation below each threshold and the smallest observation at or above it. Lean proves that these observations preserve the exact feasible interval. For 64 requests with 262,095 observations, this reduced the JSON payload from 1,282,824 to 4,225 bytes. Across thirteen alternating calls to the same compiled executable, the median decision time decreased from 133.74 to 70.92 ms, including the JavaScript projection. Every selected interval and witness matched. The [raw threshold samples and validation settings](../evidence/m1/threshold-extrema.json) record the workload.
230
+
231
+ Focused replay compares ordered decoded observation rows incrementally. For two stable traces with 50,000 observations each and interleaved coverage rows in the replay, the median comparison fell from 51.40 to 39.58 ms. Additional heap use measured immediately after comparison fell from 48.2 to 24.4 MB. An early mismatch can end comparison before serializing later observations. The [raw trace measurement pairs](../evidence/m1/focused-observation-comparison.json) include stable, early-mismatch and late-mismatch cases.
232
+
233
+ ### Scope and replay
234
+
235
+ Measurements on Apple M5 Max with Node 24.14.0 alternate baseline and current samples. The Git and CLI benchmarks use nine pairs. The coverage planner uses eleven pairs. CLI samples start a fresh Node process with the compile cache disabled.
236
+
237
+ | Workload | Median |
238
+ | --- | ---: |
239
+ | Git line selection with 100 changes across 1,000 tracked files | 545.80 → 56.47 ms |
240
+ | Standard coverage planning for 500 mutations and 2,000 tests | 77.27 → 1.59 ms |
241
+ | Writing 50,000 observations from one focused test | 973.66 → 20.35 ms |
242
+ | Focused CLI with the 50,000-observation fixture | 2.93 → 1.03 s |
243
+ | Focused CLI with eight comparisons reached by one of twelve tests | 2.76 → 0.80 s |
244
+
245
+ With one changed file, Git scope selection took 46.90 → 46.79 ms. The scope and coverage measurements exclude test execution. The trace reader returned identical ordered observation bytes after removing internal control records, and the 50,000-observation CLI reports matched. On the twelve-test fixture, Lean reduced Vitest launches from eleven to three. The reports matched after excluding the fields that identify how each verdict was obtained.
246
+
247
+ Focused trials continue to use independent project copies and Vitest contexts. Trace batches are accepted after task completion. If another producer writes while a chunk is pending, the runner repeats the attempt with immediate writes in a fresh copy. Threshold planning uses one lazy TypeScript parse per file across all comparison operators. See the [paired samples](../evidence/m1/analysis-throughput.json).
248
+
249
+ ## Pulse byte-class scanner pilot
250
+
251
+ The Pulse build replaces only the Low★ byte-class scanner. The scanner predicate, parser, compatibility route and Node-API interface are shared. Both variants use native LTO and fixture-trained PGO. Each column compares nine alternating samples on an Apple M5 Max with Node 24.14.0. First extraction starts a new process for each sample and disables the Node compile cache. Both measurements parse pre-read source buffers.
252
+
253
+ | Workload | Warm, Low★ → Pulse | First extraction, Low★ → Pulse |
254
+ | --- | ---: | ---: |
255
+ | Vite | 15.64 → 15.49 ms | 54.09 → 53.60 ms |
256
+ | mreact | 79.12 → 78.22 ms | 150.98 → 147.87 ms |
257
+ | tachyon-dom | 31.92 → 31.55 ms | 79.79 → 79.59 ms |
258
+
259
+ The pilot showed comparable throughput. An earlier run with a different C representation of the class parameter had up to a 3% increase in the median warm time. The final build removes that enum conversion and verifies the equivalence of its byte-code predicate in F★. Both variants produced identical complete extraction results, including diagnostics, for 8,549 tracked files across five corpora and 3,303 unique captured inputs, each with both logical-rule settings. The [raw paired samples and corpus revisions](../evidence/m1/pulse-scan.json) record the final variant. The optional scanner pilot is reproducible at commit `116527f`.
260
+
261
+ ## Cache-free first extraction compared with Yuku
262
+
263
+ The runtime archive includes a 639,522-byte syntax-only build generated from the pinned TypeScript compiler. It handles compatibility extraction, while the installed full compiler supplies witness and other compiler APIs. Low★ also handles byte-zero hashbangs and interface bodies in quoted ambient modules, moving two previously declined Vite files into native extraction.
264
+
265
+ Two independent runs alternate nine fresh processes per version with `NODE_DISABLE_COMPILE_CACHE=1`. The clock starts with file buffers already in memory and includes extractor import, native parsing, and loading and running the compatibility parser. Each pair matches source acceptance and every ordered candidate field. Both runs used an Apple M5 Max and Node 24.14.0. Sample times varied with unrelated host load.
266
+
267
+ | Workload | Former Yuku → current, run 1 | Former Yuku → current, run 2 |
268
+ | --- | ---: | ---: |
269
+ | Vite | 57.49 → 53.64 ms | 47.74 → 42.51 ms |
270
+ | mreact | 161.68 → 139.30 ms | 142.07 → 119.86 ms |
271
+ | tachyon-dom | 75.25 → 70.47 ms | 72.34 → 68.07 ms |
272
+
273
+ The projected parser also matched all candidate fields and diagnostic records of full TypeScript in both logical-rule settings for 8,540 decodable corpus files and 4,251 decodable captured inputs. Invalid UTF-8 remains rejected before either parser. The [paired samples and extraction audits](../evidence/m1/cold-yuku-parity.json) record the exact checkout revisions.
274
+
275
+ Use `npm run build:native -- --pgo` and `npm run build:typescript-syntax` in the current checkout. Build the former runtime at `8592705` in a separate checkout and pass its module to the benchmark.
276
+
277
+ ```sh
278
+ NODE_DISABLE_COMPILE_CACHE=1 node scripts/bench-first-extraction.mjs BASELINE/src/extract.mjs /path/to/vite /path/to/mreact /path/to/tachyon-dom
279
+ ```
280
+
281
+ ## First extraction and focused analysis planning
282
+
283
+ The CLI loads only the selected command, and native-only extraction leaves the TypeScript compatibility parser and grammar unloaded. Low★ handles right-associative exponentiation, common static import attributes and more regular expressions with named captures. Across the five pinned TS/TSX corpora, Low★ covered 2,490 of 2,968 candidates, up from 2,424. Both logical-rule settings matched the Yuku reference on source acceptance and every ordered candidate field. A further 3,303 captured inputs passed the same checks.
284
+
285
+ | Workload | Previous Low★ candidates | Current Low★ candidates | Low★ files |
286
+ | --- | ---: | ---: | ---: |
287
+ | Vite | 194 / 201 | 196 / 201 | 470 / 482 |
288
+ | mreact | 1,452 / 1,550 | 1,510 / 1,550 | 1,166 / 1,193 |
289
+ | tachyon-dom | 604 / 654 | 610 / 654 | 364 / 373 |
290
+
291
+ First extraction measures the initial module load and parsing in a fresh process for every sample. Source buffers are already in memory. Nine samples alternate baseline and current versions per checkout on an Apple M5 Max with Node 24.14.0. Each experiment has its own paired baseline. The host was running other workloads, and absolute times vary between experiments.
292
+
293
+ | Workload | First extraction, previous → current | First extraction with local cache, previous → current | Warm extraction, previous → current |
294
+ | --- | ---: | ---: | ---: |
295
+ | Vite | 210.45 → 204.39 ms | 203.25 → 116.40 ms | 30.50 → 28.44 ms |
296
+ | mreact | 438.00 → 358.89 ms | 503.36 → 277.47 ms | 189.02 → 144.06 ms |
297
+ | tachyon-dom | 251.71 → 240.03 ms | 504.41 → 274.52 ms | 61.07 → 54.99 ms |
298
+
299
+ | Workload | Former Yuku → current, first extraction | Former Yuku → current, first extraction with local cache |
300
+ | --- | ---: | ---: |
301
+ | Vite | 133.99 → 228.14 ms | 113.34 → 143.03 ms |
302
+ | mreact | 357.20 → 520.27 ms | 292.37 → 290.45 ms |
303
+ | tachyon-dom | 117.92 → 197.98 ms | 217.71 → 260.07 ms |
304
+
305
+ At `be13ba8`, the local checkout could opt into the Node module compile cache with `npm run build:typescript-cache` on Node 24.12 or later. It still read and parsed the supplied sources on every extraction. That runtime archive used the normal Node compiler load. Node 26.12 selects different cache directories for portable and portable read-only activation. See the [Node implementation](https://github.com/nodejs/node/blob/v26.12.0/src/compile_cache.cc#L43-L59).
306
+
307
+ Focused analysis now indexes trace observations by site and reuses observed test identities and threshold metadata. With 200 comparison sites and 2,000 observations, generating the complete trial plan dropped from 357.70 to 40.64 ms over nine alternating samples. The full trial records matched. This measurement excludes running the tests.
308
+
309
+ The [recorded samples and corpus details](../evidence/m1/cold-start.json) use `4fb291a` and the former Yuku runtime `8592705` as baselines. Reproduce first-process measurements with `node scripts/bench-first-extraction.mjs BASELINE/src/extract.mjs GIT_CHECKOUT...`. Set `NODE_DISABLE_COMPILE_CACHE=1` for the unprepared experiment. Warm measurements use `--expose-gc scripts/bench-extraction.mjs` with both native addons built using `--pgo`.
310
+
311
+ ## Extraction compared with the former Yuku runtime
312
+
313
+ At `69a4a22`, repeated extraction on an Apple M5 Max with Node 24.14.0 is faster than the former Yuku runtime `8592705` on all three measured projects. Each of the nine alternating samples parses every file anew from an in-memory buffer. Source results are never cached. The current binary uses Clang LTO and profile data trained on 19 repository fixtures. The measured corpora are outside that training set.
314
+
315
+ | Workload | Former Yuku | Current | Reduction |
316
+ | --- | ---: | ---: | ---: |
317
+ | Vite | 23.81 ms | 16.43 ms | 31.0% |
318
+ | mreact | 85.37 ms | 79.80 ms | 6.5% |
319
+ | tachyon-dom | 40.10 ms | 26.56 ms | 33.8% |
320
+
321
+ The first extraction in a fresh Node process includes importing the extractor and loading the compatibility parser when a file requires it. The corresponding Yuku and current medians are 47.19 and 106.25 ms for Vite, 133.10 and 203.92 ms for mreact, and 70.03 and 123.70 ms for tachyon-dom. These timings begin with source buffers in memory and exclude test execution.
322
+
323
+ Low★ accepted 4,117 of the 8,549 files from the five pinned checkouts and extracted 2,424 of 2,968 comparison candidates. Both logical-rule settings agreed with Yuku on source acceptance, candidate order and every candidate field. An additional 3,303 captured inputs passed the same comparison. The compatibility parser produces its own diagnostic text and recovery. Type, expression and candidate checks share an AST traversal in the compatibility path.
324
+
325
+ | Workload | Low★ candidates | Total candidates | Low★ files |
326
+ | --- | ---: | ---: | ---: |
327
+ | Vite | 194 | 201 | 468 / 482 |
328
+ | mreact | 1,452 | 1,550 | 1,159 / 1,193 |
329
+ | tachyon-dom | 604 | 654 | 363 / 373 |
330
+
331
+ The compiled Lean checker also evaluates boundary-flip replay summaries through `maySkipBoundary`. Lean proves that the summary gives the same decision as evaluating all observations in the original model. Over 64 requests containing 262,144 safe integer pairs, the JSON payload decreased from 2,630,957 to 11,971 bytes and the median decision time fell from 61.47 to 19.14 ms. The CLI still requires complete, stable observations under the replay contract. This measurement covers replay decisions separately from extraction.
332
+
333
+ The [audit data and paired samples](../evidence/m1/yuku-runtime-parity.json) include exact checkout revisions. The warm measurement uses `node --expose-gc scripts/bench-extraction.mjs BASELINE_MODULE GIT_CHECKOUT` after `npm run build:native -- --pgo`. The [native profile integration test](../test/native-profile.integration.mjs) includes regular builds on systems without a matching Clang and `llvm-profdata`.
334
+
335
+ ## Production extraction without Yuku or Oxc
336
+
337
+ The installed runtime uses Low★ first and uses its existing TypeScript dependency for declined files. Yuku is the development reference. Across 8,549 tracked TS/TSX files in the five pinned checkouts, both settings of the JSX logical rule produced the same source acceptance and ordered candidate fields as the reference. Low★ extracted 2,163 of 2,968 candidates across 3,786 valid files and reported five duplicate-declaration diagnostics. The compatibility parser retains source byte ranges and can use different diagnostic wording and recovery.
338
+
339
+ | Checkout | All candidates | Low★ | TypeScript compatibility |
340
+ | --- | ---: | ---: | ---: |
341
+ | Vite | 201 | 159 | 42 |
342
+ | Preact | 1 | 0 | 1 |
343
+ | TypeScript corpus | 562 | 115 | 447 |
344
+ | mreact | 1,550 | 1,339 | 211 |
345
+ | tachyon-dom | 654 | 550 | 104 |
346
+
347
+ The 37 JavaScript implementation files under Preact's root and package `src/` directories produced 43 identical candidates in both logical modes, with 12 from Low★. A separate audit of 3,303 captured inputs also found agreement on all source acceptance decisions and ordered candidate fields.
348
+
349
+ | Warm extraction workload | Yuku runtime `8592705` | TypeScript cutover `5c60b31` | After reducing AST traversal |
350
+ | --- | ---: | ---: | ---: |
351
+ | Vite | 24.51 ms | 150.58 ms | 143.40 ms |
352
+ | mreact | 87.63 ms | 419.52 ms | 408.53 ms |
353
+ | tachyon-dom | 40.72 ms | 214.89 ms | 204.64 ms |
354
+
355
+ Each experiment alternates nine warm samples on an Apple M5 Max with Node 24.14.0 and measures extraction from in-memory buffers. The traversal experiment uses the TypeScript cutover as its paired baseline and reduces the three medians by 3.4%, 1.8%, and 1.7%. The current compatibility path still costs more than the former Yuku path on these workloads. The [audit and timing evidence](../evidence/m1/typescript-runtime-cutover.json) includes the paired samples and exact checkout revisions.
356
+
357
+ ## Low★ arrow parameter expressions
358
+
359
+ At `2a8a993`, Low★ extracts 1,964 of 2,968 candidates across 3,490 of 8,549 files, including 1,200 in mreact and 498 in tachyon-dom. The ordinary and logical audits match all candidate fields and ordered diagnostics. Five diagnostic files also complete in Low★.
360
+
361
+ | Warm extraction workload | Previous C-only build `4be72f5` | Expanded arrow defaults |
362
+ | --- | ---: | ---: |
363
+ | Vite | 25.16 ms | 24.71 ms |
364
+ | mreact | 105.21 ms | 98.29 ms |
365
+ | tachyon-dom | 54.31 ms | 45.59 ms |
366
+
367
+ These are nine alternating warm samples over identical buffers. The [audit and samples](../evidence/m1/low-arrow-default-expressions.json) record fallback counts and fixed revisions.
368
+
369
+ ## Low★ callable and mapped type coverage
370
+
371
+ At `a9c789c`, Low★ extracts 1,843 of 2,968 candidates across 3,472 of 8,549 files. Overloads, object accessors, generic function and constructor types, and mapped types moved 205 candidates to Low★ since `89f96fd`. The complete ordered candidate records and diagnostics match Yuku across the five pinned checkouts in both JSX logical modes.
372
+
373
+ | Checkout | All candidates | Low★ | Yuku fallback |
374
+ | --- | ---: | ---: | ---: |
375
+ | Vite | 201 | 159 | 42 |
376
+ | Preact | 1 | 0 | 1 |
377
+ | TypeScript corpus | 562 | 107 | 455 |
378
+ | mreact | 1,550 | 1,191 | 359 |
379
+ | tachyon-dom | 654 | 386 | 268 |
380
+
381
+ | Warm extraction workload | Oxc-linked baseline `b42c79a` | Low★ and Yuku `a9c789c` |
382
+ | --- | ---: | ---: |
383
+ | Vite | 17.71 ms | 25.34 ms |
384
+ | mreact | 83.83 ms | 109.38 ms |
385
+ | tachyon-dom | 35.48 ms | 58.38 ms |
386
+
387
+ Each pair uses nine alternating warm runs over the same input buffers on an Apple M5 Max with Node 24.14.0. The C-only addon still takes longer on all three workloads. The [measurements](../evidence/m1/low-type-coverage.json) include corpus revisions and samples.
388
+
389
+ ## Low★ coverage after Oxc removal
390
+
391
+ At `89f96fd`, the Low★ parser extracts 1,638 of 2,968 candidates across 3,271 of 8,549 files in the same five checkouts. The first C-only build extracted 1,212. The complete ordered candidate records and diagnostics match Yuku with the JSX logical rule enabled and disabled.
392
+
393
+ | Checkout | Low★ at Oxc removal | Low★ after grammar expansion | Yuku fallback |
394
+ | --- | ---: | ---: | ---: |
395
+ | Vite | 99 | 128 | 73 |
396
+ | Preact | 0 | 0 | 1 |
397
+ | TypeScript corpus | 56 | 107 | 455 |
398
+ | mreact | 883 | 1,062 | 488 |
399
+ | tachyon-dom | 174 | 341 | 313 |
400
+
401
+ Packed candidate transfer reduced time by 2.7–2.9× in synthetic inputs with 16, 512 or 4,096 sites per file. In the three complete repository workloads, the medians stayed within roughly 2.2% of the unoptimized transfer. Those workloads still spend a substantial share of extraction time in the parser and compatibility route.
402
+
403
+ | Warm extraction workload | Earlier Oxc build | Expanded Low★ with Yuku fallback |
404
+ | --- | ---: | ---: |
405
+ | Vite | 19.21 ms | 29.52 ms |
406
+ | mreact | 84.19 ms | 123.00 ms |
407
+ | tachyon-dom | 33.14 ms | 66.57 ms |
408
+
409
+ These are extraction timings over identical pinned source inputs, from nine alternating samples. The analyzer's test execution is outside these measurements. See the [audit, benchmark samples and verification](../evidence/m1/low-workload-after-oxc.json).
410
+
411
+
412
+ ## Native runtime without Oxc
413
+
414
+ At `5078acc`, the default build and packaged addon use the generated C parser without Rust or Cargo. Low★ accepts 2,946 of 8,549 tracked TS/TSX files in the pinned corpora. Complete candidate records and diagnostics match Yuku with the JSX logical rule enabled and disabled.
415
+
416
+ | Checkout | Candidates | Low★ | Yuku fallback |
417
+ | --- | ---: | ---: | ---: |
418
+ | Vite | 201 | 99 | 102 |
419
+ | Preact | 1 | 0 | 1 |
420
+ | TypeScript corpus | 562 | 56 | 506 |
421
+ | mreact | 1,550 | 883 | 667 |
422
+ | tachyon-dom | 654 | 174 | 480 |
423
+
424
+ The macOS ARM64 addon shrank from 2,113,064 to 170,344 bytes. Routing every Low★ refusal to Yuku increased warm extraction time in the three measured workloads. The median uses nine alternating samples over the same inputs and includes parsing and candidate conversion.
425
+
426
+ | Workload | Oxc build | C-only build with Yuku fallback |
427
+ | --- | ---: | ---: |
428
+ | Vite | 19.42 ms | 34.74 ms |
429
+ | mreact | 83.11 ms | 165.83 ms |
430
+ | tachyon-dom | 35.43 ms | 86.19 ms |
431
+
432
+ The standalone `--low-only` build also runs without Yuku for files within the Low★ grammar. At that revision, the standard build used Yuku for the other files. See the [corpus audits and samples](../evidence/m1/oxc-removal.json).
433
+
434
+ ## macOS link-time optimization and symbol visibility
435
+
436
+ On an Apple M5 Max with Node 24.14.0, full LTO and hidden visibility shortened the median standard extraction time from 31.34 to 26.30ms for Vite and from 171.33 to 137.94ms for mreact. This experiment used the same source and Oxc-linked addon before removal. The native API and candidate results matched across builds. The build probes whether the selected compiler can link a bundle with LTO and keeps hidden visibility if LTO is unavailable. See the [nine-sample measurements](../evidence/m1/oxc-removal.json).
437
+
438
+ ## Earlier Oxc-linked measurements
439
+
440
+ The rest of this page records the extraction routes in earlier revisions with Oxc in the addon.
441
+
442
+ ## Low★ classes, binding scopes, and tagged templates
443
+
444
+ Against `91b9af3`, Low★ accepted 2,893 of 8,549 tracked TS/TSX files, up from 2,401. It extracted 1,090 of 2,968 comparison candidates, up from 1,020. The byte spans, candidate order and diagnostics matched Yuku in both settings of the JSX logical rule.
445
+
446
+ | Checkout | Previous Low★ candidates | Current Low★ candidates | Oxc candidates | Yuku candidates |
447
+ | --- | ---: | ---: | ---: | ---: |
448
+ | Vite | 85 | 88 | 113 | 0 |
449
+ | Preact | 0 | 0 | 1 | 0 |
450
+ | TypeScript corpus | 47 | 56 | 496 | 10 |
451
+ | mreact | 720 | 776 | 710 | 64 |
452
+ | tachyon-dom | 168 | 170 | 480 | 4 |
453
+
454
+ In Vite's 118-file production scope, Low★ accepted 67 files and produced 55 of 160 candidates. The wider name table added Vite's `node/server/middlewares/indexHtml.ts` and mreact's `emit-server.ts` and `emit-server-stream.ts`. Module type/value namespaces and local type and variable declarations moved seven candidates off Yuku. A standalone build reproduced all 1,090 fast-path candidates in 335 files without Cargo, Oxc or npm dependencies. [Corpus and verification data](../evidence/m1/low-scope-expansion.json)
455
+
456
+ ## Linux link-time optimization and symbol visibility
457
+
458
+ On Linux ARM64, GCC 12.2 and Node 24.21.0, a single-core benchmark compared builds from the same native source with identical candidate records. Each value is the median of nine warm measurements over the same Vite buffers. Both Node-API registration symbols remained visible.
459
+
460
+ | Workload | Baseline | Hidden visibility plus LTO |
461
+ | --- | ---: | ---: |
462
+ | Vite, Low★ native call | 26.88 ms | 11.03 ms |
463
+ | Vite production, Low★ native call | 9.41 ms | 3.80 ms |
464
+ | Vite, native routes including Oxc | 34.91 ms | 23.31 ms |
465
+ | Vite production, native routes including Oxc | 19.98 ms | 15.46 ms |
466
+
467
+ The build retains hidden visibility if the selected Linux compiler cannot link a shared library with LTO. The native-route timings include the Node-API calls but exclude the JavaScript Yuku fallback and test execution. [Compiler experiment data](../evidence/m1/low-scope-expansion.json)
468
+
469
+ ## Low★ binding, module, and statement coverage
470
+
471
+ Against `3589d6e`, the AST-free route grew from 1,934 to 2,401 of 8,549 tracked TS/TSX files and from 808 to 1,020 of 2,968 comparison candidates. Both logical-rule settings matched Yuku on the complete diagnostics and ordered candidate records, including exact byte spans.
472
+
473
+ | Checkout | Baseline Low★ files | Current Low★ files | Baseline Low★ candidates | Current Low★ candidates |
474
+ | --- | ---: | ---: | ---: | ---: |
475
+ | Vite | 300 | 382 | 45 | 85 |
476
+ | Preact | 5 | 5 | 0 | 0 |
477
+ | TypeScript corpus | 767 | 866 | 47 | 47 |
478
+ | mreact | 704 | 931 | 591 | 720 |
479
+ | tachyon-dom | 158 | 217 | 125 | 168 |
480
+
481
+ In Vite's 118-file production scope, Low★ accepted 64 files and extracted 52 of 160 candidates, up from 53 files and 24 candidates. The newly covered sources include the five comparisons in `packages/vite/src/node/plugins/manifest.ts` and eleven in `packages/vite/src/node/plugins/importMetaGlob.ts`. The standard addon still routes 1,863 candidates through Oxc and 85 through Yuku. The Yuku total includes 67 mreact candidates, four tachyon-dom candidates, and fourteen TypeScript fixture candidates.
482
+
483
+ A standalone build with only the generated C and Node-API adapter reproduced all 1,020 candidates across 312 files. The build omitted Cargo, Oxc sources, and npm dependencies.
484
+
485
+ | Warm extraction workload | Baseline median | Current median |
486
+ | --- | ---: | ---: |
487
+ | Vite | 188.32 ms | 145.65 ms |
488
+ | Vite production source | 64.20 ms | 62.92 ms |
489
+ | mreact | 525.89 ms | 436.98 ms |
490
+ | tachyon-dom | 155.05 ms | 129.39 ms |
491
+
492
+ The benchmark alternated the two builds over the same source buffers for nine warm samples on an Apple M5 Max. The interquartile ranges overlap for Vite production source, mreact, and tachyon-dom. The measurements cover extraction with the standard runtime, including its fallback paths. The [audit and benchmark data](../evidence/m1/low-frontier-expansion.json) include exact standalone candidate records, corpus revisions, and all samples.
493
+
494
+ ## Low★ exceptions, function forms, and regular expressions
495
+
496
+ Against `acc4149`, the AST-free route increased from 1,139 to 1,934 of 8,549 tracked TS/TSX files and from 196 to 808 of 2,968 comparison candidates. Both logical-rule settings matched Yuku on complete ordered candidate records and diagnostics.
497
+
498
+ | Checkout | Baseline Low★ files | Current Low★ files | Baseline Low★ candidates | Current Low★ candidates |
499
+ | --- | ---: | ---: | ---: | ---: |
500
+ | Vite | 145 | 300 | 11 | 45 |
501
+ | Preact | 4 | 5 | 0 | 0 |
502
+ | TypeScript compiler fixtures | 586 | 767 | 41 | 47 |
503
+ | mreact | 322 | 704 | 105 | 591 |
504
+ | tachyon-dom | 82 | 158 | 39 | 125 |
505
+
506
+ In the 118-file Vite production scope, Low★ accepted 53 files and emitted 24 of 160 candidates, up from eight files and two candidates. These include all eight comparisons in `packages/vite/src/node/plugins/reporter.ts` and all five in `packages/vite/src/node/server/transformRequest.ts`. A clean standalone build reproduced all 808 candidates in 243 files without the Oxc source tree, Cargo, or npm dependencies. The original 85 Yuku candidates still use Yuku, including 67 in mreact and four in tachyon-dom.
507
+
508
+ | Warm extraction workload | Baseline median | Current median |
509
+ | --- | ---: | ---: |
510
+ | Vite | 76.39 ms | 64.66 ms |
511
+ | Vite production source | 32.08 ms | 29.42 ms |
512
+ | mreact | 425.70 ms | 447.30 ms |
513
+ | mreact repeat | 381.46 ms | 337.90 ms |
514
+ | tachyon-dom | 96.72 ms | 90.26 ms |
515
+
516
+ Each measurement uses nine alternating samples on the same source buffers. The first mreact run has overlapping interquartile ranges, and the repeat favored the current parser. The [audit and benchmark data](../evidence/m1/low-statements-and-regex.json) include the samples and standalone candidate spans.
517
+
518
+ ## Low★ control, TSX, and type syntax expansion
519
+
520
+ Against `3612949`, the AST-free route increased from 554 to 1,139 of 8,549 tracked TS/TSX files and from 40 to 196 of 2,968 comparison candidates. Both logical-rule settings agreed with Yuku on ordered candidates, all byte spans, and complete diagnostic output.
521
+
522
+ | Checkout | Baseline Low★ files | Current Low★ files | Baseline Low★ candidates | Current Low★ candidates |
523
+ | --- | ---: | ---: | ---: | ---: |
524
+ | Vite | 70 | 145 | 6 | 11 |
525
+ | Preact | 1 | 4 | 0 | 0 |
526
+ | TypeScript compiler fixtures | 339 | 586 | 12 | 41 |
527
+ | mreact | 122 | 322 | 17 | 105 |
528
+ | tachyon-dom | 22 | 82 | 5 | 39 |
529
+
530
+ The newly covered files include Vite's `client/env.ts` and `node/plugins/pluginFilter.ts` under `packages/vite/src/`, mreact's `packages/router/src/navigation-marker.ts` with 28 candidates, and tachyon-dom's `src/html-raw-text.ts` with five. Low★ extracted two of the 160 candidates in the Vite production-source scope. A clean standalone build reproduced all 196 candidates in 77 files without Cargo, Oxc sources, or npm dependencies. The compiler fixture `circularOptionalityRemoval.ts` moved one candidate from Yuku to Low★. The ordinary build routes 67 mreact candidates, four tachyon-dom candidates, and fourteen TypeScript compiler fixture candidates through Yuku.
531
+
532
+ | Warm extraction workload | Baseline median | Current median |
533
+ | --- | ---: | ---: |
534
+ | Vite | 54.91 ms | 50.31 ms |
535
+ | Vite production source | 24.28 ms | 23.43 ms |
536
+ | mreact | 304.80 ms | 287.67 ms |
537
+ | tachyon-dom | 79.42 ms | 76.47 ms |
538
+
539
+ Nine alternating samples used the same source buffers on an Apple M5 Max with Node.js 24.14.0. These measurements cover extraction. The paired samples and standalone candidate spans are in the [audit and benchmark data](../evidence/m1/low-extended-grammar.json).
540
+
541
+ ## Typed modules, callbacks, and collection loops in Low★
542
+
543
+ The Low★ path accepts 554 of 8,549 tracked TS/TSX files and extracts 40 of 2,968 candidates. At baseline `54649cb` it accepted 321 files and extracted 16 candidates. Both settings of the JSX logical rule matched Yuku on every ordered candidate field and the full diagnostic output.
544
+
545
+ | Checkout | Baseline Low★ files | Current Low★ files | Baseline Low★ candidates | Current Low★ candidates |
546
+ | --- | ---: | ---: | ---: | ---: |
547
+ | Vite | 57 | 70 | 2 | 6 |
548
+ | Preact | 1 | 1 | 0 | 0 |
549
+ | TypeScript compiler fixtures | 232 | 339 | 3 | 12 |
550
+ | mreact | 27 | 122 | 8 | 17 |
551
+ | tachyon-dom | 4 | 22 | 3 | 5 |
552
+
553
+ A clean standalone build extracted all 40 candidates in 25 files without Cargo, Oxc sources, or npm dependencies. The transferred candidates previously used Oxc. The ordinary build still uses Yuku for 67 mreact candidates and four tachyon-dom candidates. Among Vite production sources under `packages/vite/src/`, Low★ accepted three files with zero comparison candidates, and Oxc handled the remaining 115 files and all 160 candidates.
554
+
555
+ | Warm extraction workload | Baseline median | Current median |
556
+ | --- | ---: | ---: |
557
+ | Vite | 34.67 ms | 34.65 ms |
558
+ | Vite production source | 15.66 ms | 16.27 ms |
559
+ | mreact | 270.43 ms | 273.68 ms |
560
+ | tachyon-dom | 49.79 ms | 50.47 ms |
561
+
562
+ The benchmark alternates nine runs on the same input buffers. These medians range from approximately flat to 3.9% slower. The [audit and benchmark data](../evidence/m1/low-typed-expansion.json) record revisions, every standalone candidate span, and all timing samples.
563
+
564
+ ## Expanded Low★ expression and module grammar
565
+
566
+ The expanded Low★ path handled 321 of 8,549 tracked TS/TSX files, up from 81 at `ca1bc93`. It produced 16 candidates, up from four. All candidate fields and diagnostics in the five checkouts matched Yuku with the JSX logical rule disabled and enabled.
567
+
568
+ | Checkout | Previous Low★ files | Current Low★ files | Previous Low★ candidates | Current Low★ candidates |
569
+ | --- | ---: | ---: | ---: | ---: |
570
+ | Vite | 9 | 57 | 0 | 2 |
571
+ | Preact | 0 | 1 | 0 | 0 |
572
+ | TypeScript compiler fixtures | 70 | 232 | 3 | 3 |
573
+ | mreact | 2 | 27 | 1 | 8 |
574
+ | tachyon-dom | 0 | 4 | 0 | 3 |
575
+
576
+ A clean `--low-only` build extracted all 16 candidates across ten files without Cargo, Oxc sources, or npm dependencies. The Vite candidates came from HMR playground modules, and the tachyon-dom candidates came from `tests/whitespace-policy-types.ts`. The normal build still uses Yuku for 67 mreact candidates and four tachyon-dom candidates.
577
+
578
+ Nine alternating warm samples against `ca1bc93` measured median extraction times of 33.74 to 32.86 ms on Vite, 189.49 to 188.28 ms on mreact, and 49.68 to 49.74 ms on tachyon-dom. The mreact and tachyon-dom interquartile ranges overlap.
579
+
580
+ The [audit and benchmark data](../evidence/m1/low-expression-expansion.json) include the exact revisions, operand spans, and timing samples.
581
+
582
+ ## Standalone Low★ extraction
583
+
584
+ The [standalone extraction run](../evidence/m1/standalone-low-extraction.json) adds typed modules, generic type references, and method calls to the Low★ path. A clean build without npm dependencies, Cargo or Oxc sources extracted the comparison in mreact's `packages/router/src/navigation-history-cache.ts` directly from bytes. The macOS arm64 standalone addon was 86,776 bytes.
585
+
586
+ The expanded Low★ path extracted one mreact candidate and three TypeScript compiler fixture candidates. The ordinary build still sends 67 mreact candidates and four tachyon-dom candidates through Yuku. Across 8,549 files, all comparison and diagnostic results agreed with Yuku in both logical-rule settings. Warm medians against `d7e6384` were 193.99 ms and 196.86 ms on mreact, and 55.61 ms and 54.98 ms on tachyon-dom, with overlapping interquartile ranges for each checkout.
587
+
588
+ ## Native TS and TSX module extraction
589
+
590
+ The addon tries the AST-free Low★ grammar first. Oxc handles broader module syntax with a native AST and returns only candidates to JavaScript. The extraction audit compares ordered candidate records and full diagnostics with Yuku 0.19.0, with the JSX logical rule both disabled and enabled.
591
+
592
+ | Checkout and scope | Files extracted without Yuku | Candidates extracted without Yuku | Previous median | Current median |
593
+ | --- | ---: | ---: | ---: | ---: |
594
+ | Vite production source | 118 / 118 | 160 / 160 | 38.58 ms | 14.60 ms |
595
+ | Vite tracked TS/TSX | 481 / 482 | 201 / 201 | | |
596
+ | Preact tracked TS/TSX | 22 / 22 | 1 / 1 | | |
597
+ | TypeScript compiler fixtures | 4,680 / 6,479 | 547 / 562 | | |
598
+ | mreact tracked TS/TSX | 1,185 / 1,193 | 1,483 / 1,550 | 336.82 ms | 177.36 ms |
599
+ | tachyon-dom tracked TS/TSX | 372 / 373 | 650 / 654 | 125.95 ms | 51.56 ms |
600
+
601
+ Each timing is the median of nine alternating warm samples on an Apple M5 Max, using commit `9a9d333` as the baseline. The samples measure extraction of the same in-memory buffers and exclude test execution. A separate fresh process parsed the Vite production files while a Node load hook rejected any attempt to resolve Yuku.
602
+
603
+ The Vite-wide run used Yuku on one file to obtain its diagnostic. The compiler test checkout contains 952 diagnosed files, including nine invalid UTF-8 files rejected before parsing. Resource refusals, compatibility guards, and syntax revisions that Oxc declines also use Yuku. The macOS arm64 addon grew from 71,528 to 2,011,272 bytes with the statically linked parser.
604
+
605
+ The [recorded runs](../evidence/m1/broad-native-extraction.json) include revisions, scope, route counts, and all timing samples. To reproduce, build the native addon at `9a9d333` in a separate checkout and run the audit and benchmark against the pinned sources.
606
+
607
+ ```sh
608
+ npm run audit:extraction -- --logical /path/to/vite /path/to/preact /path/to/typescript /path/to/mreact /path/to/tachyon-dom
609
+ npm run audit:extraction -- --prefix packages/vite/src/ --source-only /path/to/vite
610
+ node --expose-gc scripts/bench-extraction.mjs --prefix packages/vite/src/ --source-only BASELINE/src/extract.mjs /path/to/vite
611
+ ```
612
+
613
+ ## Earlier measurements
614
+
615
+ The generated Low★ parser consumes the original byte buffer. Node's `buffer.isUtf8` validates byte inputs using simdutf. The native path can return candidates without constructing a UTF-16 string. On fallback the AST walker uses identity offsets for ASCII input, and builds a UTF-16-to-byte table for non-ASCII input. Both changes preserve candidate edits and diagnostics.
616
+
617
+ That version of the runtime used Yuku as its syntax fallback. An extraction-only run over 1,585 tracked TS/TSX files from this repository, mreact, and tachyon-dom produced identical paths and candidate spans with Yuku and Babel. Three files used the native path. The median of nine alternating warm passes was 0.46 s with Yuku 0.19.0 and 0.86 s with Babel 7.29.15 on macOS arm64 and Node.js 24.14.0.
618
+
619
+ Against commit `8e81bed` on those 1,585 files, the token precheck and single-pass location scan reduced median extraction time from 466 ms to 432 ms and candidate collection from 601 ms to 534 ms. All 2,211 candidate records, diagnostics and report positions matched. A generated file with 4,096 candidates went from 353 ms to 17 ms for collection. These measurements exclude test execution. The [recorded runs](../evidence/performance/candidate-pipeline.json) include all nine samples for each version.
620
+
621
+ The shipping fixture used four Vitest invocations with deterministic literal-threshold replay, down from five. Both versions reported the same mutation verdicts, and audit reexecution agreed with the new prediction.
622
+
623
+ On the pinned Vite checkout, the validated token path extracted five candidates from four production files. Nine alternating warm samples on macOS arm64 reduced the median for those four files from 0.353 ms to 0.121 ms against `a4ecee8`. Across all 118 production files in the same scope, the medians were 40.0 ms and 38.3 ms with overlapping interquartile ranges. The [recorded extraction runs](../evidence/m1/control-extraction.json) include the scope, paths, and samples.
624
+
625
+ ```sh
626
+ npm run audit:extraction -- /path/to/vite /path/to/preact /path/to/typescript
627
+ npm run audit:extraction -- --prefix packages/vite/src/ --source-only /path/to/vite
628
+ node --expose-gc scripts/bench-extraction.mjs --prefix packages/vite/src/ --source-only --token-subset BASELINE/src/extract.mjs /path/to/vite
629
+ ```
630
+
631
+ For `--since` selection over 1,000 tracked TypeScript files with one edited line, five alternating runs measured a median of 11.49 s before batched path lookup and 54 ms afterward. Both versions selected the same file and line. The measured path includes Git processes and source selection through `selectScope`.
632
+
633
+ Two historical changes exercised witness discovery in mreact and tachyon-dom. Both selected suites passed. The changed lines contained one and two comparison candidates respectively, all extracted by Yuku. Neither change matched an automatic witness source rule, so there were no proposals to assess for adoption. A positive control from this repository produced a confirmed one-literal edit. The [recorded study](../evidence/dogfood/pr-witnesses.json) includes source and test scopes, revisions, and counts.
634
+
635
+ The [extraction benchmark](../evidence/performance/extraction.json) compares the earlier extractor from commit `3bcf31c` and the generated parser with the revised input handling. Each implementation sees the same buffers, dialects and rules. The script checks candidate fields and paths before timing them. A warm nine-repetition run on an Apple M5 Max took a median of 98.27 ms before and 75.51 ms after on 482 Vite files. All those files used Yuku fallback. The 120-file controlled L1 TSX corpus took 0.99 ms before and 0.74 ms after. The results measure the product path, including its JavaScript processing and actual fallback. They do not compare native parser throughput against Yuku's Zig AST walker.
636
+
637
+ To reproduce, check out the baseline revision in a separate directory, install its dependencies and run its native build. Then run the command below in the current checkout, giving it both the baseline module path and the pinned Vite checkout.
638
+
639
+ ```sh
640
+ npm run build:native
641
+ npm run bench:extraction -- BASELINE/src/extract.mjs /path/to/vite
642
+ npm run bench:analysis
643
+ ```
644
+
645
+ The [Vitest analysis benchmark](../evidence/performance/analysis.json) compares source and Lean replay on the same eligibility fixture and candidate. Each sample starts a new CLI process. The Lean path replaces a source trial with a repeated disabled trace and a call to the compiled decision executable. This one-candidate workload mainly measures language and test-runner startup. The audit separately confirms that the predicted result matched the full rewrite.
646
+
647
+ In that run the full-scope source replay took 799 ms and the Lean path took 818 ms, with equal verdicts. The one-candidate workload saves one rewrite, and the extra disabled recording uses another runner invocation. It does not show a net replay speedup.