Skip to content

ci(benchmark): Add help task configuration benchmark on PRs#1244

Draft
runningcode wants to merge 2 commits into
mainfrom
no/benchmark-help-config-cache
Draft

ci(benchmark): Add help task configuration benchmark on PRs#1244
runningcode wants to merge 2 commits into
mainfrom
no/benchmark-help-config-cache

Conversation

@runningcode
Copy link
Copy Markdown
Contributor

Adds a pull_request workflow that benchmarks this project's help task with the configuration cache disabled, comparing the PR base commit against the head commit.

What it does

  • Runs gradle-profiler against the help task with --no-configuration-cache, 2 warm-ups + 5 builds.
  • Uses the git-checkout mutator to benchmark the PR base and head commits in a single run (help_base vs help_pr scenarios).
  • Uploads the full results directory (HTML + CSV) as an artifact.
  • Posts/updates a sticky PR comment with the mean build time for base vs head and the delta.

How it differs from the existing benchmark

The existing Benchmark build speed workflow profiles the runtime cost of applying the plugin to the duckduckgo sample app and is workflow_dispatch only. This one profiles the configuration time of this project itself and runs automatically on every PR.

Notes

  • Uses commit SHAs (base.sha / head.sha) with fetch-depth: 0 so both are reachable from the PR merge commit.
  • Reports total help build time (dominated by configuration with the config cache off); the HTML artifact has the full breakdown.

Files

  • .github/workflows/benchmark-help-config.yml — the workflow
  • scripts/benchmark/help-config-cache.scenarios — gradle-profiler scenarios
  • scripts/benchmark/help-config-comment.py — renders benchmark.csv into the comment table

🤖 Generated with Claude Code

Add a pull_request workflow that benchmarks this project's `help` task
with the configuration cache disabled (2 warm-ups, 5 builds), comparing
the PR base commit against the head commit in a single gradle-profiler
run via the git-checkout mutator.

This is separate from the existing duckduckgo benchmark build: it
profiles configuration time of this project rather than the runtime cost
of applying the plugin to a sample app, and it runs automatically on
every PR. Results are uploaded as an artifact and summarized as a sticky
PR comment.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 29, 2026

help configuration benchmark (configuration cache disabled)

Mean of 5 builds after 2 warm-ups.

Scenario Mean build time
Base (help base) 1778 ms
PR (help PR) 1777 ms
Difference ✅ -1 ms (-0.1%)

gradle-profiler does not write summary rows (mean, min, max) to
benchmark.csv; those only appear in the HTML report. The comment parser
looked for a non-existent `mean` row and always fell back to "Could not
parse benchmark results". Average the `measured build #N` rows instead.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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