Files
Build-System/schemas/README.md
T
faumaray 7365279cf3
VoidBuildSystem CI / 3A · Linux test (relwithdebinfo) (push) Failing after 6m43s
VoidBuildSystem CI / 3A · Linux test (debug) (push) Failing after 6m49s
VoidBuildSystem CI / 4A2 · VBS installers (linux target) (push) Skipped
VoidBuildSystem CI / 4A2 · VBS installers (windows target) (push) Skipped
VoidBuildSystem CI / 5 · Release (push) Skipped
VoidBuildSystem CI / 1 · Requirements (push) Successful in 7s
VoidBuildSystem CI / 2A · Linux build (debug) (push) Successful in 2m16s
VoidBuildSystem CI / 2A · Linux build (coverage) (push) Successful in 2m22s
VoidBuildSystem CI / 2A · Linux build (sanitizers) (push) Successful in 3m49s
VoidBuildSystem CI / 2B · Windows Wine build (debug) (push) Successful in 2m1s
VoidBuildSystem CI / 2A · Linux build (relwithdebinfo) (push) Successful in 4m46s
VoidBuildSystem CI / 2B · Windows Wine build (relwithdebinfo) (push) Successful in 3m16s
VoidBuildSystem CI / 3B · Windows Wine test (debug) (push) Successful in 18s
VoidBuildSystem CI / 3A · Linux test (coverage) (push) Failing after 1m4s
VoidBuildSystem CI / 3A · Linux test (sanitizers) (push) Successful in 1m4s
VoidBuildSystem CI / 3B · Windows Wine test (relwithdebinfo) (push) Successful in 17s
feat(bench): benchmark targets, baselines and regression gates (G1, G8)
- p.benchmark(name) adds the `benchmark` target kind, built and linked
  like an executable (graph lowering, compdb, IDE runnables and the
  installer default destination all handle it).
- vbs bench builds only the benchmark targets (or the --target subset),
  runs each binary --samples times (default 3) with VBS_BENCH=1, keeps the
  best wall-clock time, and compares against --baseline
  (default <build>/.vbs/bench_baseline.json) with --max-regression PCT
  (default 5). The first run records the baseline; --update-baseline
  rewrites it while merging entries for benchmarks not selected.
- Baselines carry os/architecture/compiler/profile; comparison across
  machines warns and skips the gate instead of failing noisy CI.
- --json FILE writes a schema-versioned results document (per-benchmark
  status, samples, baseline, regression percent).
- vbs metadata bumps to schema v2 (new `benchmark` kind, corrected
  `header_only` enum); metadata-v1.schema.json is retained per the
  schema versioning rule, and the schema test fixture now declares a
  benchmark target.

Verified: bench_records_baseline_and_enforces_regression_gate covers
recording, passing, crafted-slow/fast baselines, JSON results,
--update-baseline, machine mismatch, no-benchmark and invalid options;
the schema test passes against v2; vbs_core_tests 8/8; CLI contracts
pass; clang-format clean.
2026-12-06 20:37:33 +03:00

1.6 KiB

JSON schemas

Versioned JSON Schemas for the machine-readable vbs surfaces:

Command Schema
vbs metadata metadata-v2.schema.json (current), metadata-v1.schema.json (retained)
vbs describe describe-v1.schema.json
vbs explain --format json explain-v1.schema.json

Versioning rule

  • The schema file name and the document's schema_version integer always match (-vN ⇔ "schema_version": N).
  • Any change to the emitted shape bumps the version and adds a new -vN file. That includes adding, removing, renaming or retyping a field. The previous schema stays for consumers that read older documents.
  • Consumers must ignore fields they do not know; producers must not rely on that for breaking changes.
  • The repository tests validate the emitted documents against these files (FullV1Tests.json_schemas_validate_metadata_describe_and_explain), so a code change that alters a document without updating its schema fails the suite.

Adding a new version

  1. Emit the new schema_version from the command.
  2. Copy the previous schema to <surface>-vN+1.schema.json and update it.
  3. Add the new document to the schema validation test.
  4. Keep the older schema file until the next major release.

History

  • metadata v2 (2026-12-06): added the benchmark target kind (G1 vbs bench) and corrected the target-kind enum to the names actually emitted (header_only, not header_only_library). v1 is retained unchanged for older consumers.