Conversation
Add three CodSpeed CI jobs: Criterion CPU simulation, Criterion memory profiling, and macro benchmarks (TPC-H SF1 + ClickBench partitioned) via codspeed exec. Swap workspace criterion dependency to codspeed-criterion-compat. Install protobuf-compiler for substrait builds. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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.
Summary
This PR integrates CodSpeed for continuous performance benchmarking of DataFusion with three modes:
Changes
Workspace dependency update: Replaced
criterion = "0.8"withcodspeed-criterion-compat = "4.3.0"using Cargo dependency renaming (package = "codspeed-criterion-compat"). This is a drop-in replacement that preserves all existinguse criterion::*;imports across the codebase -- no benchmark source code changes required.CI workflow (
.github/workflows/codspeed.yml) with three jobs:codspeed execfor per-query regression trackingREADME badge: Added CodSpeed badge linking to the project dashboard.
Macro benchmark script (
benchmarks/codspeed_macro.sh): Runs each TPC-H and ClickBench query individually throughcodspeed execso each gets tracked as a separate benchmark.How it works
The
codspeed-criterion-compatcrate acts as a passthrough when runningcargo benchnormally, so existing benchmark workflows are unaffected. When benchmarks are run throughcargo codspeedin CI, CodSpeed instruments the execution to produce consistent, hardware-agnostic measurements.Affected crates
All 13 crates with criterion benchmarks are covered automatically via the workspace dependency:
datafusion(core)datafusion-commondatafusion-datasourcedatafusion-datasource-parquetdatafusion-functionsdatafusion-functions-aggregatedatafusion-functions-aggregate-commondatafusion-functions-nesteddatafusion-functions-windowdatafusion-optimizerdatafusion-physical-exprdatafusion-physical-plandatafusion-sparkDesign decisions
ubuntu-latestrunners with <1% variancecodspeed execper query: Gives per-query regression tracking rather than one aggregate measurementTest plan
cargo bench --no-runverifies all criterion benchmarks compile with codspeed-criterion-compat🤖 Generated with Claude Code