Method and reproduction

The harness ran serial paired processes in shuffled order with seed 539: five rounds for geometry and pending pages, seven for ownership. It required exact-output markers and identical workload dimensions, and checked executable identity and SHA-256 before and after each run. Shared libraries were held fixed, but were not hashed. Builds and other timing jobs were stopped during these measurements. Geometry uses clock() CPU time. Each pending-page sample is already the median of five internal clock() loops. Ownership sums timespec_get(TIME_UTC) wall intervals around cuts, excluding map resets. These different timers and workloads must not be combined into one score.

Build both fixture versions before timing. The historical baseline executables used the old component implementations with the synthetic benchmark workloads. cpu-baseline/ below stands for those prepared executables; the baseline revision alone does not contain all newly added fixture modes. For geometry, construct a compatibility fixture from the baseline's tests/nvn_draw_banks.c: add the current geometry_records, apply_geometry_records, bench_geometry functions and --bench-geometry dispatch, retaining all timed state/generation checks. The later equal-geometry and partial-viewport regression functions belong only in the candidate's full regression fixture. Use the compatible current header for both implementations; the old implementation ignores its two added metadata fields. Its original implementation source SHA-256 was 955e1bc7e7fcb680cf3c848b7e9eecceb7873a20c84ea7db99937d1a979cca5b.

The historical baseline used a manual -std=gnu11 -O2 -Wall -Wextra -Werror build. The formal candidate used CMake's -O2 -g, -UNDEBUG and OS defines. The complete historical compatibility-fixture snapshot was not retained. For a new comparison, compile the same compatibility fixture against both implementations with identical flags and generated headers, then run the candidate's complete regression fixture separately. These commands reproduce the harness arguments, not the original executable hashes:

python3 tools/bench_gpu_hotpaths.py --kind hotpath \
  --baseline cpu-baseline/snx-test-nvn-draw-banks \
  --candidate optimized=build/tests/snx-test-nvn-draw-banks --arg=--bench-geometry \
  --rounds 5 --seed 539 --out .cache/nvn-proof-geometry
python3 tools/bench_gpu_hotpaths.py --kind hotpath \
  --baseline cpu-baseline/snx-test-pending-pages \
  --candidate optimized=build/tests/snx-test-pending-pages --arg=--bench \
  --rounds 5 --seed 539 --out .cache/nvn-proof-pending
python3 tools/bench_gpu_hotpaths.py --kind hotpath \
  --baseline cpu-baseline/snx-test-memory-own-cut \
  --candidate bulk=build/tests/snx-test-memory-own-cut --arg=--bench \
  --rounds 7 --seed 539 --out .cache/nvn-proof-ownership

Use fresh output directories. See the harness guide for construction and rejection rules.


Made from docs/history/nvn-vulkan-optimization.md at 69237645142c. GPL-3.0-or-later.