# MoonBit VCD benchmarks

These measurements were taken locally on Windows on 2026-08-24. The counter
benchmark is deterministic; wall-clock timings are warm-cache observations and
are not performance guarantees across machines.

## Deterministic workload

Command:

```bash
moon run cmd/vcd-report -- --benchmark
```

| Fixture | Operation | Iterations | Input chars | Parsed | Changes | Checksum |
| --- | --- | ---: | ---: | ---: | ---: | ---: |
| synthetic-8x128 | parse | 20 | 6476 | 20 | 23040 | 12880 |
| synthetic-8x128 | indexed-queries | 20 | 0 | 1 | 23040 | 240 |
| synthetic-8x128 | analysis | 20 | 0 | 1 | 20320 | 101600 |

The checksum is calculated from parsed end times, declaration widths, indexed
queries, and activity totals. It is intended to catch workload regressions in
CI without treating a single machine's clock as a correctness criterion.

## Local wall-clock observations

Five PowerShell `Measure-Command` samples were collected after the source had
been built. The first native test sample includes a rebuild and is retained
instead of being silently discarded.

| Command | Samples (ms) | Average | Median |
| --- | --- | ---: | ---: |
| `moon run cmd/vcd-report -- --benchmark` | 410.42, 389.85, 450.97, 488.81, 407.75 | 429.56 | 410.42 |
| `moon test --target native --deny-warn` | 286.53, 249.07, 276.86, 321.55, 305.80 | 287.96 | 286.53 |
