镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

Commit ac9dc52

Browse files
committed
docs(json): publish cycle-index evidence (#556)
Publish six seven-pair exact-parent rows comparing benchmark-only parent 4be2bc6 with runtime candidate 63d0543 on AC power with nominal thermal state and no discarded samples. The real depth-4096 cycle isolates active membership and improves to 0.3688x retired instructions and 0.422x median wall time. Acyclic instruction ratios improve progressively from 0.9860x at depth 512 to 0.8252x at depth 4096; the shallow repeated-alias control remains near neutral at 1.0124x instructions and 1.006x wall. Retain wall, process CPU, peak RSS, instructions, cycles, energy availability, thermal state, dispersion, exact identities, and checksums in the raw artifacts. Track the separately exposed recursive output-copy cost in #558. Validation: six performance-attribution schema validations, benchmark-comparison-test, and docs-link-check across 252 files. Flips 0 test262 cases.
1 parent 3a67f66 commit ac9dc52

13 files changed

Lines changed: 29684 additions & 0 deletions

‎docs/.data/exact-parent-json-stringify-cycle-4096-2026-08-14.json‎

Lines changed: 4911 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# Exact-parent performance A/B — representative_json_stringify_cycle_4096 (single, 1 lane(s))
2+
3+
- parent: `4be2bc64c995d43a778294b1b99e1ff07656e1d2`
4+
- candidate: `63d054374b1398ce627c16782748ed9f514d04ec`
5+
- zig-gc: `89b6652c81ba892119b7b9ce3b0d07fc78a009ff`
6+
- zig-regex: `719673318b0c6250898d7ced3603876c148e370b`
7+
- host class: `diagnostic`
8+
- material-change categories: `cpu_work`
9+
- sampling: 7 order-balanced pairs; no discarded samples
10+
- timed boundary: one JSON.stringify invocation of a prebuilt depth-4096 object chain with a leaf-to-root back-edge after ten one-job warmups; exact TypeError validated inside the timed invocation
11+
12+
| parent median | candidate median | candidate / parent | parent RSD | candidate RSD | assessment |
13+
| ---: | ---: | ---: | ---: | ---: | --- |
14+
| 3.823 ms | 1.612 ms | 0.422x | 19.82% | 4.25% | `diagnostic_only` |
15+
16+
| memory/allocation metric | parent median | candidate median | candidate / parent | parent RSD | candidate RSD |
17+
| --- | ---: | ---: | ---: | ---: | ---: |
18+
| `peak_rss_bytes` | 54034432 | 56606720 | 1.0476x | 0.08% | 0.06% |
19+
20+
| efficiency metric | parent median | candidate median | candidate / parent | parent RSD | candidate RSD |
21+
| --- | ---: | ---: | ---: | ---: | ---: |
22+
| `instructions` | 59457654 | 21927790 | 0.3688x | 0.24% | 1.18% |
23+
| `cycles` | 13822423 | 5953301 | 0.4307x | 19.94% | 4.11% |
24+
| `energy_joules` | 0 | 0 | NaNx | NaN% | NaN% |
25+
26+
Thermal states: `nominal->nominal`. Unmet category metrics: none. Efficiency evidence: `blocked_or_diagnostic`.
27+
28+
All input identities and checksums matched. Missing attribution values are encoded as unavailable with a reason, never as zero.
Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
# JSON.stringify active-cycle identity index — exact-parent evidence (2026-08-14)
2+
3+
Order-balanced exact-parent diagnostic for [#556](https://github.com/zig-utils/zig-js/issues/556).
4+
5+
- parent: `4be2bc64c995d43a778294b1b99e1ff07656e1d2`
6+
- candidate: `63d054374b1398ce627c16782748ed9f514d04ec`
7+
- source: `bench/representative_comparison.js`
8+
- host: Apple M3 Pro, macOS 27.0.0, arm64
9+
- power: AC power, charging; every sample recorded `nominal->nominal` thermal state
10+
- sampling: seven alternating fresh-process pairs per row, no discarded samples
11+
- mode/jobs: `single`, one scored job after ten one-job warmups
12+
- identity: every runner, source, dependency, mode, job, output, and checksum identity matched
13+
14+
| workload | parent wall | candidate wall | wall ratio | median process CPU parent → candidate | parent instructions | candidate instructions | instruction ratio | candidate / parent peak RSS |
15+
| --- | ---: | ---: | ---: | ---: | ---: | ---: | ---: | ---: |
16+
| acyclic depth 512 | 0.695 ms | 0.672 ms | 0.968× | 10 → 0 ms | 7,873,667 | 7,763,338 | 0.9860× | 1.0062× |
17+
| acyclic depth 1,024 | 1.839 ms | 1.831 ms | 0.995× | 20 → 20 ms | 20,980,658 | 19,481,960 | 0.9286× | 1.0027× |
18+
| acyclic depth 2,048 | 5.992 ms | 5.595 ms | 0.934× | 70 → 60 ms | 64,189,683 | 55,900,332 | 0.8709× | 1.0015× |
19+
| acyclic depth 4,096 | 19.916 ms | 18.131 ms | 0.910× | 240 → 210 ms | 216,536,198 | 178,683,094 | 0.8252× | 1.0009× |
20+
| real cycle depth 4,096 | 3.823 ms | 1.612 ms | 0.422× | 40 → 10 ms | 59,457,654 | 21,927,790 | 0.3688× | 1.0476× |
21+
| shallow repeated alias width 4,096 | 2.641 ms | 2.656 ms | 1.006× | 30 → 30 ms | 47,795,317 | 48,388,213 | 1.0124× | 1.0005× |
22+
23+
The deep real-cycle row isolates active-ancestor membership because it throws at
24+
the back-edge before copying a successful nested result back through every
25+
ancestor. Its 0.3688× retired-instruction ratio is the clearest causal signal
26+
that the indexed path removes the former linear scan at every depth. The
27+
acyclic rows retain identical complete output and show progressively larger
28+
instruction reductions as depth increases.
29+
30+
The shallow control never promotes the index: each repeated object is removed
31+
before its sibling is visited, so active depth stays two. Its 1.0124×
32+
instruction and 1.006× wall ratios keep common shallow aliasing neutral while
33+
also proving the implementation did not substitute a global visited set.
34+
35+
Wall dispersion is too high for a stable latency claim on several sub-20 ms
36+
rows, so wall values remain diagnostic. Retired instructions are the causal
37+
decision metric. Process CPU is the median sum of `/usr/bin/time -l` user and
38+
system observations and retains that source's 10 ms granularity; cycles and
39+
energy are retained with their exact availability and dispersion in each raw
40+
artifact. The 4K acyclic peak RSS reflects a separate nested-output copying
41+
cost and is not attributed to the bounded cycle index.
42+
43+
## Row artifacts
44+
45+
- [depth 512 report](exact-parent-json-stringify-depth-512-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-depth-512-2026-08-14.json)
46+
- [depth 1,024 report](exact-parent-json-stringify-depth-1024-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-depth-1024-2026-08-14.json)
47+
- [depth 2,048 report](exact-parent-json-stringify-depth-2048-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-depth-2048-2026-08-14.json)
48+
- [depth 4,096 report](exact-parent-json-stringify-depth-4096-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-depth-4096-2026-08-14.json)
49+
- [real cycle report](exact-parent-json-stringify-cycle-4096-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-cycle-4096-2026-08-14.json)
50+
- [shallow repeated-alias control](exact-parent-json-stringify-shallow-4096-2026-08-14.md) · [raw JSON](exact-parent-json-stringify-shallow-4096-2026-08-14.json)

0 commit comments

Comments
 (0)