Skip to content

test(executor): run the executor tests against an unreleased valgrind - #571

Merged
lvaroqui merged 1 commit into
mainfrom
cod-3781-run-the-executor-tests-against-an-unreleased-valgrind
Oct 7, 2026
Merged

lvaroqui merged 1 commit into
mainfrom
cod-3781-run-the-executor-tests-against-an-unreleased-valgrind

Conversation

@lvaroqui

@lvaroqui lvaroqui commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Run the Docker executor tests against an unreleased valgrind-codspeed:

CODSPEED_VALGRIND_REF=<branch | tag | full commit sha> just test-integ [filter]

The tests install the pinned valgrind-codspeed release through codspeed setup, so a runner change that depends on an unreleased valgrind-codspeed change could not be tested end to end until that release shipped and the pin was bumped.

  • tests/docker/run.sh resolves the ref to a commit on the host (git ls-remote; a full sha is used as-is) and hashes it into the setup image tag, so a push to the branch rebuilds the image and an unchanged ref reuses it.
  • tests/docker/setup.sh builds and installs that commit in the setup container, adds libc6-dbg (without it codspeed setup reinstalls the package), then runs codspeed setup, which keeps an installed build at or above the pinned version. It fails when setup replaced the build, i.e. the ref is older than the pin. Test containers are unchanged.
  • The executor-tests CI job gets a commented-out env: example, to enable while a PR waits on a valgrind-codspeed release.

I first considered teaching codspeed setup itself to build a ref, but only the tests need it, and since every codspeed run runs setup it would have needed per-run commit tracking to avoid rebuilding.

Short shas are not supported: GitHub only serves fetches by full sha.

Verified locally with CODSPEED_VALGRIND_REF=700eb1edb4393e1e964acb4a04c1cc6a7f499911: the setup container built and kept valgrind-3.26.0.codspeed7 from that commit, and simulation_exec_harness_declares_benchmark_pid passed against it. Branch and annotated tag names resolve to their commits, and an unknown name fails before any build.

Closes COD-3781

@lvaroqui
lvaroqui marked this pull request as ready for review October 7, 2026 08:53
@greptile-apps

greptile-apps Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

RetriggerConfidence Score: 5/5

[Medium risk] Adds optional testing against unreleased valgrind builds.

The PR appears safe to merge; no new actionable issues remain.

What we checked:

  • Moving branches use fresh builds: run.sh resolves the branch on each run and includes its commit in the setup image tag.
  • Older builds stop the run: The source build now installs under /usr. Setup replaces an older build there, and the version check stops the run.

Summary

Lets Docker executor tests use an unreleased valgrind-codspeed commit through CODSPEED_VALGRIND_REF.

  • Resolves branches and tags before builds and includes the selected commit in the setup image tag.
  • Builds Valgrind under /usr, installs libc debug symbols, and checks that codspeed setup kept the build.
  • Adds clean-integ and documents the override.
  • Both previous unnumbered findings are addressed: older builds no longer hide under /usr/local, and bad branch or tag names fail before builds.

Reviews (2) · Last reviewed commit: "test(executor): run the executor tests a..." · Reviewed by Greptile

Comment thread tests/docker/setup.sh
Comment thread tests/docker/run.sh Outdated
@codspeed

codspeed Bot commented Oct 7, 2026 •

Copy link
Copy Markdown

Merging this PR will not alter performance

⚠️ Unknown Walltime execution environment detected

Using the Walltime instrument on standard Hosted Runners will lead to inconsistent data.

For the most accurate results, we recommend using CodSpeed Macro Runners: bare-metal machines fine-tuned for performance measurement consistency.

✅ 31 untouched benchmarks
⏩ 6 skipped benchmarks1


Comparing cod-3781-run-the-executor-tests-against-an-unreleased-valgrind (8470cc5) with main (8c603c2)

Open in CodSpeed

Footnotes

  1. 6 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

@GuillaumeLagrange GuillaumeLagrange left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

olgtm, maybe we can add a just clean-integ that would be in charge of clearing all docker volumes, images and so on easily? Dont go too complicated on this

Comment thread tests/docker/run.sh Outdated
The executor tests install the pinned valgrind-codspeed release, so a
runner change that depends on an unreleased valgrind-codspeed change
cannot be tested until that release ships and the pin is bumped.

CODSPEED_VALGRIND_REF=<branch, tag or full commit sha> now builds that
valgrind-codspeed in the setup container before `codspeed setup`, which
keeps an installed build at or above the pinned version. The ref is
resolved to a commit on the host and hashed into the setup image tag, so
a push to the branch rebuilds the image. The setup fails if
`codspeed setup` replaced the build, i.e. the ref is older than the pin.

Add a commented-out example to the executor-tests CI job.

Closes COD-3781
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@lvaroqui
lvaroqui force-pushed the cod-3781-run-the-executor-tests-against-an-unreleased-valgrind branch from 0eea696 to 8470cc5 Compare October 7, 2026 09:20
@lvaroqui
lvaroqui merged commit 8c84fcc into main Oct 7, 2026
57 checks passed
@lvaroqui
lvaroqui deleted the cod-3781-run-the-executor-tests-against-an-unreleased-valgrind branch October 7, 2026 09:36
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.

2 participants