Repository navigation
Replace the benchmarks with a suite for the JuliaGPU benchmark history - #932
Merged
Merged
Conversation
The old suite (AirspeedVelocity on GitHub runners) only measured steady-state kernel times, mostly saxpy over a grid of sizes, and missed the regressions of the last releases: time to the first kernel (#816), load time (#889), launch overhead, 4-d ranges (#913) or state across barriers (#893). perf/ follows CUDA.jl's: a BenchmarkTools suite run in fresh processes, whose results (every statistic, and the environment) are published to the benchmark history at juliagpu.org/perf. Every benchmark isolates one mechanism, in three categories: - latency: Julia start-up, precompiling and loading the package, the first kernel with a cold and a warm PoCL cache, compiling further kernels, and launch overhead; - performance: streaming, indexing, narrow workgroups, scheduling, `@Const`, math functions and contraction, local memory, private state across barriers, collectives, atomics and utilities, plus serial Julia loops for reference; - applications: three of the DGSEM volume integrals and a stencil time-stepping loop. Benchmarks run with one PoCL worker (serial) or one per physical core (parallel), with fixed sample counts instead of tuning, so that runs are comparable.
The benchmarks run on the benchmark agent, which runs one job at a time, for every commit on main and every non-draft pull request (`[only benchmarks]` and `[skip benchmarks]` select them). When the job has succeeded, the Benchmarks workflow publishes its results with JuliaGPU/benchmark-action: commits on main go into the history on gh-pages, pull requests get a comment comparing them with it. This replaces the AirspeedVelocity workflow, which benchmarked pull requests and their base on a shared GitHub runner.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #932 +/- ##
==========================================
+ Coverage 83.13% 83.17% +0.03%
==========================================
Files 31 31
Lines 2568 2568
==========================================
+ Hits 2135 2136 +1
+ Misses 433 432 -1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This replaces
benchmark/and its AirspeedVelocity workflow with aperf/suite like CUDA.jl's, Metal.jl's and AMDGPU.jl's. Its results are published to the history at https://juliagpu.org/perf/, and pull requests get a comment comparing them with it.The old suite measured steady-state kernel times, mostly saxpy over a grid of sizes, on shared GitHub runners. It missed the regressions of the 0.10 cycle:
ndrangemakes kernels up to 100× slower #913);@synchronize()in a loop make a kernel 14–78× slower #893).Each benchmark in the new suite isolates one mechanism. There are 50, in three categories:
@groupreduce) and launching at a new workgroup size;@Const,exp/sin, contraction vs.muladd(POCL: contract fast-math flags lost through SPIR-V, no FMAs emitted #865), with serial Julia loops for reference;@groupreduce,@groupscan, a histogram with atomics;zerosandcopyto!.benchmark/dgsem.jl), and a 3-d stencil time-stepping loop.How it measures:
serial) or one per physical core (parallel).tune!.It runs on Buildkite, on gpuci1 (i7-9700K, the CUDA benchmark machine), with Julia 1.13, for commits on main and non-draft PRs (
[only benchmarks]/[skip benchmarks]). A run takes about 10.5 minutes there. Three consecutive runs with nothing else on the machine took 623, 624 and 622 s. Across those runs, the minimum of 33 of the 50 rows varied by less than 3%, and every latency row except the launches by less than 2%. A few parallel kernels vary much more:dgsem/fluxdiff-nodeby 45%, andindexing/linear3dandlocalmem/transpose-tiledby 27%. The history learns each benchmark's own noise, so those will only flag larger changes. I dropped three launch benchmarks that varied by 11–17%.Some numbers from gpuci1, as a baseline:
using KernelAbstractions@groupreduce