FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Continuous benchmarking with google benchmark and bencher.dev by biddisco · Pull Request #596 · IPPL-framework/ippl · GitHub

Continuous benchmarking with google benchmark and bencher.dev - #596

Open
biddisco wants to merge 9 commits into
masterfrom
continuous-benchmarking
Open

Continuous benchmarking with google benchmark and bencher.dev#596
biddisco wants to merge 9 commits into
masterfrom
continuous-benchmarking

Conversation

Copy link
Copy Markdown
Collaborator

Summary

Introduces continuous benchmarking for IPPL using Google Benchmark and bencher.dev.

What's added

  • IPPL_ENABLE_BENCHMARK CMake option that fetches Google Benchmark v1.9.4 via FetchContent.
  • add_ippl_benchmark() CMake helper with REPORT_TIMERS/IGNORE_TIMERS support and a generated compile-time timer-whitelist header (<name>_timers.h).
  • src/Utility/BenchmarkMetrics.h — bridges existing IpplTimings measurements to bencher.dev's Benchmark Metric Format (BMF) JSON.
  • LandauDampingBench — first real benchmark in demos/alpine/, measuring LandauDampingManager::advance() per Google Benchmark iteration.
  • CI jobs for OpenMP (Eiger), CUDA (Daint GH200), and ROCm (Beverin MI300) under ci/cscs/benchmark/benchmark.yml.
  • ci/scripts/install_bencher.sh — installs the bencher.dev CLI in CI.

- Add CMake option IPPL_ENABLE_BENCHMARK (default OFF).
- Fetch Google Benchmark v1.9.4 via FetchContent when enabled.
- Add minimal BenchmarkSmoke executable to verify the integration.

Part of continuous-benchmarking spec.
- Add cmake/AddIpplBenchmark.cmake defining add_ippl_benchmark().
- Support REPORT_TIMERS whitelist and IGNORE_TIMERS blacklist.
- Generate <name>_timers.h with constexpr reportedTimers array.
- Make REPORT_TIMERS and IGNORE_TIMERS mutually exclusive.
- Register benchmark targets with ctest when BUILD_TESTING is ON.
- Convert BenchmarkSmoke to use the helper.
- Add src/Utility/BenchmarkMetrics.h to bridge IpplTimings to bencher.dev BMF.
- Compute latency (mean/min/max) and count per timer.
- Filter emitted timers against the generated whitelist.
- Update BenchmarkSmoke to use a Google Benchmark fixture, collect
  IpplTimings samples, and write BenchmarkSmoke.bmf.json.
- Add ippl::initialize/finalize around the benchmark main.

Part of continuous-benchmarking spec.
- Add demos/alpine/LandauDampingBench.cpp as the first real IPPL benchmark.
- Use add_ippl_benchmark() with a REPORT_TIMERS whitelist (solve,
  pushVelocity, pushPosition, update, loadBalance).
- Run pre_run() once as warmup, reset IpplTimings, then benchmark
  manager->advance() per Google Benchmark iteration.
- Write BMF JSON via BenchmarkMetrics in TearDown.
- Destroy the manager in TearDown before ippl::finalize() to avoid
  Kokkos deallocation-after-finalize warnings.
- Consume demo-specific flags (--overallocate, --info) and pass the
  remaining args to Google Benchmark.

Part of continuous-benchmarking spec.
- Add ci/scripts/install_bencher.sh to install the bencher.dev CLI.
- Add ci/cscs/benchmark/benchmark.yml with per-platform benchmark jobs:
  - OpenMP on Eiger
  - CUDA on Daint GH200
  - ROCm on Beverin MI300
- Each job builds with IPPL_ENABLE_BENCHMARK=ON, runs LandauDampingBench,
  saves JSON/BMF artifacts, and submits to bencher.dev only when
  BENCHER_API_TOKEN is set.
- Jobs are non-blocking (allow_failure: true) and gated by
  IPPL_ENABLE_BENCHMARK variable.
- Bencher project slug is set to ippl-opalx (TBD).

Part of continuous-benchmarking spec.
Use IPPL_RUN_BENCHMARKS to control whether benchmark jobs run,
keeping IPPL_ENABLE_BENCHMARK as the CMake build option only.
This avoids confusion between the build-time and CI-time switches.
biddisco force-pushed the continuous-benchmarking branch 3 times, most recently from ca2a29b to 4cdffd8 Compare August 28, 2026 15:33
- Add a 'benchmark' stage after 'ippl_test' in ci/cscs/common.yml.
- Add -DIPPL_ENABLE_BENCHMARK=ON to the release build jobs for OpenMP,
  CUDA, and ROCm so LandauDampingBench is built with the normal build
  artifact.
- Replace the standalone ci/cscs/benchmark/benchmark.yml with
  platform-specific files:
  - benchmark-common.yml: shared template and bencher submission logic
  - benchmark-openmp.yml / benchmark-cuda.yml / benchmark-rocm.yml:
    one job per platform that reuses the release build artifact
- Each platform top-level YAML (cscs-openmp.yml, cscs-gh200.yml,
  cscs-mi300.yml) now includes its matching benchmark job file.
- Benchmark jobs depend on the release build job and the 4-rank release
  test job via 'needs', and run with SLURM_NTASKS=4 so there is exactly
  one benchmark data point per platform.
- Detect the LandauDampingBench binary at either bin/LandauDampingBench
  (IPPL_USE_STANDARD_FOLDERS=ON) or demos/alpine/LandauDampingBench
  (default layout) so both layouts work.

biddisco commented Aug 28, 2026
edited
Loading

Copy link
Copy Markdown
Collaborator Author

cscs-ci run cscs-ci-gh200

biddisco force-pushed the continuous-benchmarking branch from 4cdffd8 to 33445be Compare August 28, 2026 15:53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant


Back | FazBrowse Home | New Git URL