Benchmark the verified archive on release staging branches
This commit is contained in:
1 parent
58fccae303
commit
af1e07f3d7
3 files changed
+19
-7
No files matched your search
@@ -2,15 +2,15 @@
|
||||
# Shared-node measurements may support an explicitly approved RC WARN.
|
||||
when:
|
||||
event: [manual]
|
||||
branch: [master]
|
||||
branch: [master, "release/*"]
|
||||
|
||||
steps:
|
||||
measure:
|
||||
image: rust:1.100-bookworm
|
||||
commands:
|
||||
- apt-get update
|
||||
- apt-get install -y --no-install-recommends python3 util-linux ca-certificates git build-essential
|
||||
- cargo build --release --locked -p marqdo-cli
|
||||
- apt-get install -y --no-install-recommends python3 util-linux ca-certificates git openssl build-essential
|
||||
- cargo build --release --locked -p marqdo-cli -p marqdo-provider-worker
|
||||
- |
|
||||
set -eu
|
||||
baseline_sha=2c7c4f31e7a388d3fcfa717a77067e696ed13854
|
||||
@@ -21,6 +21,14 @@ steps:
|
||||
trap 'git worktree remove --force "$perf_dir/beta"; rm -rf "$perf_dir"' EXIT
|
||||
(cd "$perf_dir/beta" && cargo build --release --locked -p marqdo-cli)
|
||||
|
||||
version="$(target/release/marqdo --version | cut -d ' ' -f 2)"
|
||||
python3 tools/release/package.py --version "$version" --source-sha "$CI_COMMIT_SHA" --out-dir "$perf_dir"
|
||||
archive="$perf_dir/marqdo-$version-x86_64-unknown-linux-gnu.tar.gz"
|
||||
(cd "$perf_dir" && sha256sum -c "$(basename "$archive.sha256")")
|
||||
tar -xzf "$archive" -C "$perf_dir"
|
||||
candidate="$perf_dir/marqdo-$version-x86_64-unknown-linux-gnu"
|
||||
test "$(cat "$candidate/SOURCE_SHA")" = "$CI_COMMIT_SHA"
|
||||
|
||||
allowed="$(awk '/^Cpus_allowed_list:/ {print $2}' /proc/self/status)"
|
||||
cpu_list="${MARQDO_PERF_CPU_LIST:-$(printf '%s' "$allowed" | cut -d, -f1 | cut -d- -f1)}"
|
||||
echo "G4_NODE host=$(uname -n) kernel=$(uname -r) arch=$(uname -m) allowed_cpus=$allowed pin=$cpu_list"
|
||||
@@ -29,7 +37,7 @@ steps:
|
||||
(cd "$perf_dir/beta" && python3 tools/perf/runner.py --no-build \
|
||||
--warmups 5 --samples 20 --platform-id woodpecker-agent-1 \
|
||||
--cpu-list "$cpu_list" --out "$perf_dir/beta.json" > /dev/null)
|
||||
python3 tools/perf/runner.py --no-build --warmups 5 --samples 20 \
|
||||
python3 tools/perf/runner.py --no-build --binary "$candidate/marqdo" --warmups 5 --samples 20 \
|
||||
--platform-id woodpecker-agent-1 --cpu-list "$cpu_list" \
|
||||
--baseline "$perf_dir/beta.json" --out perf.json > /dev/null
|
||||
python3 - <<'PY'
|
||||
|
||||
@@ -55,5 +55,7 @@ candidate checkout. Use the same toolchain, CPU list and platform ID in both
|
||||
commands. Pass the extracted, verified candidate CLI via `--no-build --binary`
|
||||
and add `--baseline /path/to/beta.json` to the candidate command. Keep both
|
||||
reports and confirm all nine comparisons are present and correctness-verified.
|
||||
The shared Woodpecker manual workflow can reproduce the comparison and
|
||||
produces SMOKE reports.
|
||||
The shared Woodpecker manual workflow runs on master and release branches.
|
||||
It packages the candidate, checks its checksum and source SHA, then measures
|
||||
the extracted binary with the shipped stdlib. Shared-node runs produce SMOKE
|
||||
reports for review under the release policy.
|
||||
@@ -244,7 +244,9 @@ def run_workload(
|
||||
prefix = [shutil.which("taskset") or "taskset", "-c", cpu_list]
|
||||
argv = prefix + [str(binary)] + workload["argv"]
|
||||
env = dict(os.environ)
|
||||
env["MARQDO_STDLIB_DIR"] = str(ROOT / "stdlib")
|
||||
env.pop("MARQDO_STDLIB_DIR", None)
|
||||
if not (binary.parent / "stdlib" / "stdlib.json").is_file():
|
||||
env["MARQDO_STDLIB_DIR"] = str(ROOT / "stdlib")
|
||||
env.setdefault("NO_COLOR", "1")
|
||||
expected = load_expected(name)
|
||||
result = {
|
||||
|
||||
Reference in new issue
Block a user