bench: add a VBS vs CMake vs Meson comparison harness with a baseline
VoidBuildSystem CI / build-and-test-gcc16 (push) Failing after 3s
VoidBuildSystem CI / signing-openssl-gcc16 (push) Failing after 9s

This commit is contained in:
faumaray committed 2026-12-05 07:30:45 +03:00
1 parent 1e670cb96b
commit 4bd2999b49
5 files changed
+150 -1

No files matched your search

+2
View File
@@ -300,6 +300,8 @@ Stage: VERIFIED — Plans 01–19 + Plan 20 Slices 1–2C + Track A + Track B (B
- **Wave 103 (Test-Runner Parity: JUnit XML & Test Timeout)**: `vbs test` gained `--test-timeout SECONDS` (1..86400, validated before any project work) and `--junit FILE`, which writes a JUnit XML report aggregating every executed test target across profiles (`testcase` with classname/name/time, `failure` with exit status and captured output, escaped). Covered by `FullV1Tests.native_vbs_subproject_dependency_builds_without_cmake` (asserts the suite/testcase/failures fields) and a CLI contract for invalid timeouts.
- **Wave 104 (Competitor Benchmark Harness)**: `benchmarks/compare.sh` generates one C++ project and times VBS, CMake/Ninja and Meson cold and warm. First baseline (20 sources, 32 jobs): VBS 2578/209 ms, CMake configure 234 ms + build 98/9 ms, Meson setup 438 ms + compile 232/166 ms - VBS's per-invocation descriptor/toolchain work is the documented optimization target.
## Remaining future scope
- **Superiority plan ([22-superiority-and-gaps.md](../roadmap/22-superiority-and-gaps.md), 2026-12-05)**: revised platform strategy - **macOS deferred**, **Windows via MinGW-w64 cross-compilation + Wine execution** (`dev cpp-gcc -p pkgsCross.mingwW64.stdenv.cc`, `dev cpp-gcc -p wine64`), native MSVC deferred; plus packaging parity (ZIP/DEB/RPM), IDE ecosystem, migration tooling, test-runner parity, benchmarks, CI runners, and remote execution in prioritized order.
+1
View File
@@ -107,4 +107,5 @@ Base HEAD: `fe0d1a6`
| Wave 101 (CMake File API shim) | `vbs ide generate` emits `.cmake/api/v1/reply` codemodel-v2 + directory + per-target JSON from the lowered graph | COMPLETE & VERIFIED (GCC 16.2, pin `0002e74`; IDE integration test passes, full CTest 8/8) | `src/Editor/CompDb.cpp`, `tests/FullV1Tests.cpp`, docs |
| Wave 102 (VoidLibrary migration trial) | Separate-clone `build.cpp` builds and tests VoidLibrary with VBS; assets in `contrib/voidlibrary-migration/`; upstream issue #61 | VERIFIED IN CLONE (23 actions, `vbs test` PASSED; no CMake) | `contrib/voidlibrary-migration/`, docs |
| Wave 103 (JUnit & test timeout) | `vbs test --junit FILE --test-timeout SECONDS` with aggregated JUnit XML | COMPLETE & VERIFIED (GCC 16.2, pin `0002e74`; JUnit assertions and CLI contract pass, full CTest 8/8) | `src/Main.cpp`, `tests/{FullV1Tests,CliContracts}.cpp/cmake`, docs |
| Wave 104 (Competitor benchmark harness) | `benchmarks/compare.sh` timing VBS vs CMake/Ninja vs Meson; baseline recorded | COMPLETE & VERIFIED (baseline observed; VBS 2578/209 ms vs CMake 98/9 ms on a 20-source fixture) | `benchmarks/compare.sh`, `docs/roadmap/22-superiority-and-gaps.md`, docs |
| Future (Plan 20 Slice 3 / Tracks C, E3 editor extensions) |"}] Live `conan` CLI verification; macOS/Windows/cross-compile; binary-variant signing and key distribution; daemon-side dependency materialization and editor plugins; `Void::Net`/`Void::Sqlite` alignment | PLANNED (unimplemented) | [21-expansion-roadmap.md](../roadmap/21-expansion-roadmap.md), [20-future-translation-platforms.md](../roadmap/20-future-translation-platforms.md) |
+19
View File
@@ -1456,6 +1456,25 @@ vbs test --project /tmp/opencode/vl-migrate --build-dir /tmp/opencode/vl-migrat
work (CLI contract).
- Full CTest: **8 / 8 passed** after both slices.
## Competitor Benchmark Baseline (GCC 16.2, pin `0002e74`)
```sh
dev cpp-gcc -c bash benchmarks/compare.sh 20 --vbs build/pinned/bin/vbs
```
Observed on this host (x86_64, 32 jobs, Debug, 20 generated sources):
```
vbs-cold 2578 vbs-warm 209
cmake-config 234 cmake-cold 98 cmake-warm 9
meson-setup 438 meson-cold 232 meson-warm 166
```
The harness (`benchmarks/compare.sh`) generates one project and times each tool's cold and warm
invocations. VBS is slower on this small fixture because every invocation recompiles/probes the
description; the numbers are recorded in [22](../roadmap/22-superiority-and-gaps.md) as the
optimization target.
## Limits and Unrun Checks
1. **HTTPS git fetch**: the host shell is proxy-restricted, but the Docker container could clone `https://git.faumaray.com/Void/VoidLibrary.git`; the pinned commit `3e254055e081a104f08df68dde39711bc7813518` was fetched directly for the verification above. A separate configure against the local `/home/faumaray/Projects/Library` checkout via `VBS_VOID_SOURCE_DIR` also succeeded (development-only override, checkout unmodified).
+17 -1
View File
@@ -85,7 +85,23 @@ Concrete work this implies:
8. CI on real runners, sanitizer jobs, parser fuzzing.
9. Remote execution workers.
## 6. Acceptance gates
## 6. Observed baseline (2026-12-05, x86_64, GCC 16.2, Debug, `benchmarks/compare.sh 20`)
20 generated sources, 32 cores, wall-clock milliseconds:
| Tool | cold | warm/no-op |
| --- | --- | --- |
| VBS (`vbs build`) | 2578 | 209 |
| CMake + Ninja (configure / build) | 234 (configure) | 98 cold build, 9 warm |
| Meson (`setup` / `compile`) | 438 (setup) | 232 cold, 166 warm |
Interpretation: for a tiny project VBS pays for descriptor compilation, snapshot capture and
toolchain probing on every CI invocation, so its cold and warm times are higher than Ninja's
no-op. This is the clear performance target: cache the compiled descriptor and toolchain probe
across invocations, and keep snapshot work proportional to changed files. Larger fixtures are
needed before drawing scaling conclusions.
## 7. Acceptance gates
- Every platform claim has an observed run on that platform (or under Wine, clearly labelled).
- A package generator is accepted only when its output installs and runs from a clean machine image.