Allow a documented shared-node performance exception for a named RC
This commit was merged in pull request #6.
This commit is contained in:
1 parent
22b7757420
commit
f7a5a7b016
5 files changed
+69
-16
No files matched your search
@@ -1,5 +1,5 @@
|
|||||||
# Manual performance comparison on the shared Woodpecker runner.
|
# Manual performance comparison on the shared Woodpecker runner.
|
||||||
# G4 release evidence is measured separately on the approved dedicated node.
|
# Shared-node measurements may support an explicitly approved RC WARN.
|
||||||
when:
|
when:
|
||||||
event: [manual]
|
event: [manual]
|
||||||
branch: [master]
|
branch: [master]
|
||||||
|
|||||||
+14
-5
@@ -13,7 +13,8 @@ Three profiles apply (see
|
|||||||
* **rc** — `-rc.N`. The current target is Linux x86_64 (glibc).
|
* **rc** — `-rc.N`. The current target is Linux x86_64 (glibc).
|
||||||
Record Windows and macOS as UNSUPPORTED for this scope. Require same-SHA
|
Record Windows and macOS as UNSUPPORTED for this scope. Require same-SHA
|
||||||
Linux CI, frozen extensions, clean install, version compatibility, strict
|
Linux CI, frozen extensions, clean install, version compatibility, strict
|
||||||
VM and fixed-node performance PASS.
|
VM PASS. Performance requires fixed-node PASS or the specific shared-node
|
||||||
|
exception documented below.
|
||||||
* **stable** — `3.0.0`/LTS. Not covered by beta exceptions; see
|
* **stable** — `3.0.0`/LTS. Not covered by beta exceptions; see
|
||||||
[`STABLE_RELEASE_IMPLEMENTATION.md`](STABLE_RELEASE_IMPLEMENTATION.md)
|
[`STABLE_RELEASE_IMPLEMENTATION.md`](STABLE_RELEASE_IMPLEMENTATION.md)
|
||||||
(historical roadmap input) and the public support matrix.
|
(historical roadmap input) and the public support matrix.
|
||||||
@@ -79,7 +80,12 @@ Use the frozen-SHA build and archive checks above. Additionally:
|
|||||||
correctness-verified baseline on the same node, CPU affinity, governor,
|
correctness-verified baseline on the same node, CPU affinity, governor,
|
||||||
kernel and toolchain. Record investigation and resolution for any p50
|
kernel and toolchain. Record investigation and resolution for any p50
|
||||||
increase of at least 15% or median peak RSS increase of at least 20%.
|
increase of at least 15% or median peak RSS increase of at least 20%.
|
||||||
Shared-host or unapproved measurements do not satisfy the RC gate.
|
A dedicated node is the default. For a prerelease approved by the
|
||||||
|
maintainer to use a shared node, take at least three paired beta/RC runs
|
||||||
|
under the same measured conditions and keep all reports. Verify all nine
|
||||||
|
workloads and investigate threshold breaches or unstable samples before
|
||||||
|
accepting a `WARN`. Record the approval, runner environment and limits in
|
||||||
|
the release notes. This exception applies to the named RC only.
|
||||||
- Version compatibility covers the locked Rust minimum, CLI and Analysis
|
- Version compatibility covers the locked Rust minimum, CLI and Analysis
|
||||||
product identity, Tool/project prerelease ranges, and beta migration.
|
product identity, Tool/project prerelease ranges, and beta migration.
|
||||||
- Use Ubuntu 24.04 (glibc 2.39) for the independent archive-only runtime
|
- Use Ubuntu 24.04 (glibc 2.39) for the independent archive-only runtime
|
||||||
@@ -183,8 +189,11 @@ python3 tools/ci/release_evidence.py --profile beta --target-sha "$sha" \
|
|||||||
|
|
||||||
`BETA_RELEASE_CANDIDATE` is the only acceptable decision for a beta tag. A
|
`BETA_RELEASE_CANDIDATE` is the only acceptable decision for a beta tag. A
|
||||||
missing, skipped, failed or SHA-mismatched gate is `DO_NOT_RELEASE`; never
|
missing, skipped, failed or SHA-mismatched gate is `DO_NOT_RELEASE`; never
|
||||||
hand-edit a manifest to PASS. For a Linux RC, replace the profile with `--profile rc --require-release`,
|
hand-edit a manifest to PASS. For a Linux RC, use
|
||||||
declare both excluded platforms, and supply PASS for all six Linux and contract gates. Use the generated
|
`--profile rc --require-release` and declare both excluded platforms. If
|
||||||
|
the shared-node exception applies, pass
|
||||||
|
`--rc-shared-performance-approval <release-notes-reference>` and supply
|
||||||
|
`performance=WARN:<candidate-sha>:<comparison-evidence>`. Use the generated
|
||||||
`RC_RELEASE_CANDIDATE` decision before running the tagging commands.
|
`RC_RELEASE_CANDIDATE` decision before running the tagging commands.
|
||||||
Stable releases use `--profile stable --require-release` and require native
|
Stable releases use `--profile stable --require-release` and require native
|
||||||
Windows and macOS PASS in addition to the Linux and contract gates.
|
Windows and macOS PASS in addition to the Linux and contract gates.
|
||||||
@@ -206,7 +215,7 @@ tarball and its `.sha256`, and include the release notes. The notes must state:
|
|||||||
* prerelease status, support lifetime and the Linux x86_64 platform scope;
|
* prerelease status, support lifetime and the Linux x86_64 platform scope;
|
||||||
* the breaking RFC-LANG-0002 language change and no legacy path;
|
* the breaking RFC-LANG-0002 language change and no legacy path;
|
||||||
* the strict policy (same-SHA evidence, or `strict: unsupported` fail-closed);
|
* the strict policy (same-SHA evidence, or `strict: unsupported` fail-closed);
|
||||||
* the G4 result and its fixed-node comparison, or the documented exception for beta;
|
* the G4 result and its comparison, including any approved shared-node exception;
|
||||||
* independently versioned protocols and stdlib/package versions;
|
* independently versioned protocols and stdlib/package versions;
|
||||||
* the checksum-integrity-not-signature caveat and the known-limitations file;
|
* the checksum-integrity-not-signature caveat and the known-limitations file;
|
||||||
* the exact source SHA and links to the evidence manifest.
|
* the exact source SHA and links to the evidence manifest.
|
||||||
|
|||||||
@@ -8,8 +8,9 @@ does not query CI and cannot turn an UNVERIFIED gate into a release.
|
|||||||
The `rc` profile requires every gate on the target SHA. For a Linux-only RC,
|
The `rc` profile requires every gate on the target SHA. For a Linux-only RC,
|
||||||
Windows and macOS must be explicitly UNSUPPORTED; the stable profile requires
|
Windows and macOS must be explicitly UNSUPPORTED; the stable profile requires
|
||||||
both to PASS. Strict VM, extension, clean install, version compatibility and
|
both to PASS. Strict VM, extension, clean install, version compatibility and
|
||||||
performance all require PASS in both profiles. The historical beta profile
|
performance require PASS. RC can record a shared-node performance WARN only
|
||||||
retains its scoped exceptions, including a documented performance WARN.
|
with an explicit maintainer approval reference. The historical beta profile
|
||||||
|
retains its own scoped exceptions.
|
||||||
|
|
||||||
Gate spec: `name=STATE:tested_sha:run_url` (url may contain colons).
|
Gate spec: `name=STATE:tested_sha:run_url` (url may contain colons).
|
||||||
|
|
||||||
@@ -100,13 +101,23 @@ def parse_gate(text: str) -> tuple[str, dict]:
|
|||||||
return name, {"state": state, "tested_sha": tested_sha, "run_url": run_url}
|
return name, {"state": state, "tested_sha": tested_sha, "run_url": run_url}
|
||||||
|
|
||||||
|
|
||||||
def build_manifest(target_sha: str, gates: list[str], profile: str = "stable") -> dict:
|
def build_manifest(
|
||||||
|
target_sha: str,
|
||||||
|
gates: list[str],
|
||||||
|
profile: str = "stable",
|
||||||
|
rc_shared_performance_approval: str = "",
|
||||||
|
) -> dict:
|
||||||
if not SHA_RE.fullmatch(target_sha):
|
if not SHA_RE.fullmatch(target_sha):
|
||||||
raise ValueError(f"target SHA must be 40 lowercase hex characters: {target_sha!r}")
|
raise ValueError(f"target SHA must be 40 lowercase hex characters: {target_sha!r}")
|
||||||
try:
|
try:
|
||||||
release_decision, accepted_states, optional = PROFILES[profile]
|
release_decision, accepted_states, optional = PROFILES[profile]
|
||||||
except KeyError:
|
except KeyError:
|
||||||
raise ValueError(f"unknown profile {profile!r}; expected {sorted(PROFILES)}") from None
|
raise ValueError(f"unknown profile {profile!r}; expected {sorted(PROFILES)}") from None
|
||||||
|
approval = rc_shared_performance_approval.strip()
|
||||||
|
if approval and profile != "rc":
|
||||||
|
raise ValueError("shared-node approval is supported only by the rc profile")
|
||||||
|
if approval:
|
||||||
|
accepted_states = {**accepted_states, "performance": {"PASS", "WARN"}}
|
||||||
parsed = {}
|
parsed = {}
|
||||||
for spec in gates:
|
for spec in gates:
|
||||||
name, gate = parse_gate(spec)
|
name, gate = parse_gate(spec)
|
||||||
@@ -137,6 +148,8 @@ def build_manifest(target_sha: str, gates: list[str], profile: str = "stable") -
|
|||||||
|
|
||||||
decision = release_decision if not reasons else "DO_NOT_RELEASE"
|
decision = release_decision if not reasons else "DO_NOT_RELEASE"
|
||||||
recorded = utc_now()
|
recorded = utc_now()
|
||||||
|
if approval and parsed["performance"]["state"] == "WARN":
|
||||||
|
parsed["performance"]["rc_shared_node_approval"] = approval
|
||||||
return {
|
return {
|
||||||
"schema": SCHEMA,
|
"schema": SCHEMA,
|
||||||
"profile": profile,
|
"profile": profile,
|
||||||
@@ -160,6 +173,11 @@ def main(argv: list[str]) -> int:
|
|||||||
parser.add_argument("--profile", choices=sorted(PROFILES), default="stable")
|
parser.add_argument("--profile", choices=sorted(PROFILES), default="stable")
|
||||||
parser.add_argument("--gate", action="append", default=[])
|
parser.add_argument("--gate", action="append", default=[])
|
||||||
parser.add_argument("--out", default="")
|
parser.add_argument("--out", default="")
|
||||||
|
parser.add_argument(
|
||||||
|
"--rc-shared-performance-approval",
|
||||||
|
default="",
|
||||||
|
help="maintainer approval reference for the measured shared-node RC performance WARN",
|
||||||
|
)
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
"--require-release",
|
"--require-release",
|
||||||
action="store_true",
|
action="store_true",
|
||||||
@@ -167,7 +185,9 @@ def main(argv: list[str]) -> int:
|
|||||||
)
|
)
|
||||||
args = parser.parse_args(argv)
|
args = parser.parse_args(argv)
|
||||||
try:
|
try:
|
||||||
manifest = build_manifest(args.target_sha, args.gate, args.profile)
|
manifest = build_manifest(
|
||||||
|
args.target_sha, args.gate, args.profile, args.rc_shared_performance_approval
|
||||||
|
)
|
||||||
except ValueError as error:
|
except ValueError as error:
|
||||||
print(f"error: {error}", file=sys.stderr)
|
print(f"error: {error}", file=sys.stderr)
|
||||||
return 2
|
return 2
|
||||||
|
|||||||
@@ -73,6 +73,28 @@ class ReleaseEvidenceTests(unittest.TestCase):
|
|||||||
self.assertEqual(manifest["release_decision"], "DO_NOT_RELEASE")
|
self.assertEqual(manifest["release_decision"], "DO_NOT_RELEASE")
|
||||||
self.assertTrue(manifest["reasons"][0].startswith(f"{name}:"))
|
self.assertTrue(manifest["reasons"][0].startswith(f"{name}:"))
|
||||||
|
|
||||||
|
def test_rc_shared_performance_requires_explicit_approval_and_evidence(self) -> None:
|
||||||
|
approval = "release notes: maintainer approved the shared node for this RC"
|
||||||
|
inputs = [spec for spec in self.rc_gates() if not spec.startswith("performance=")]
|
||||||
|
inputs.append(gate("performance", "WARN"))
|
||||||
|
manifest = release_evidence.build_manifest(SHA, inputs, "rc", approval)
|
||||||
|
self.assertEqual(manifest["release_decision"], "RC_RELEASE_CANDIDATE")
|
||||||
|
self.assertEqual(manifest["gates"]["performance"]["rc_shared_node_approval"], approval)
|
||||||
|
manifest = release_evidence.build_manifest(
|
||||||
|
SHA, inputs[:-1] + [gate("performance", "WARN", OTHER)], "rc", approval
|
||||||
|
)
|
||||||
|
self.assertEqual(manifest["release_decision"], "DO_NOT_RELEASE")
|
||||||
|
manifest = release_evidence.build_manifest(
|
||||||
|
SHA, inputs[:-1] + [gate("performance", "WARN", url="")], "rc", approval
|
||||||
|
)
|
||||||
|
self.assertEqual(manifest["release_decision"], "DO_NOT_RELEASE")
|
||||||
|
manifest = release_evidence.build_manifest(
|
||||||
|
SHA, inputs[:-1] + [gate("performance", "FAIL")], "rc", approval
|
||||||
|
)
|
||||||
|
self.assertEqual(manifest["release_decision"], "DO_NOT_RELEASE")
|
||||||
|
with self.assertRaises(ValueError):
|
||||||
|
release_evidence.build_manifest(SHA, inputs, "stable", approval)
|
||||||
|
|
||||||
def test_stable_requires_extension_install_version_and_performance(self) -> None:
|
def test_stable_requires_extension_install_version_and_performance(self) -> None:
|
||||||
names = ("extension", "clean_install", "version_compat", "performance")
|
names = ("extension", "clean_install", "version_compat", "performance")
|
||||||
for name in names:
|
for name in names:
|
||||||
|
|||||||
@@ -10,9 +10,11 @@ workload whose wire output did not match the committed expected digest.
|
|||||||
`Cargo.lock` digest, `rustc -vV`, source SHA and profile.
|
`Cargo.lock` digest, `rustc -vV`, source SHA and profile.
|
||||||
* Correctness comes first: every warmup run is parsed and hashed. A mismatch
|
* Correctness comes first: every warmup run is parsed and hashed. A mismatch
|
||||||
is `CORRECTNESS_FAIL`; its faster wall time is never reported.
|
is `CORRECTNESS_FAIL`; its faster wall time is never reported.
|
||||||
* Release evidence needs at least 5 warmups and 20 samples per workload with
|
* Approved-node release evidence needs at least 5 warmups and 20 samples per
|
||||||
`--approved-node` on a dedicated, stable performance node. Shorter runs are
|
workload on a dedicated, stable node. A maintainer-approved shared-node
|
||||||
`SMOKE` and must not be cited as a release gate.
|
RC comparison needs the same sample counts in at least three paired runs.
|
||||||
|
Shared-node reports stay `SMOKE` and are eligible only for the RC
|
||||||
|
`WARN` exception described in [releasing.md](../../docs/releasing.md).
|
||||||
* `--baseline` checks platform ID, build profile, CPU model, kernel,
|
* `--baseline` checks platform ID, build profile, CPU model, kernel,
|
||||||
governor, CPU affinity and toolchain. For an approved-node comparison
|
governor, CPU affinity and toolchain. For an approved-node comparison
|
||||||
it also requires an approved, correctness-verified MEASURED baseline.
|
it also requires an approved, correctness-verified MEASURED baseline.
|
||||||
@@ -47,11 +49,11 @@ it only when the output change is the intended one.
|
|||||||
|
|
||||||
## RC comparison
|
## RC comparison
|
||||||
|
|
||||||
On the approved dedicated node, run the beta benchmark from a checkout
|
On the designated node, run the beta benchmark from a checkout
|
||||||
pinned to `v3.0.0-beta.1` and the candidate benchmark from the frozen
|
pinned to `v3.0.0-beta.1` and the candidate benchmark from the frozen
|
||||||
candidate checkout. Use the same toolchain, CPU list and platform ID in both
|
candidate checkout. Use the same toolchain, CPU list and platform ID in both
|
||||||
commands. Pass the extracted, verified candidate CLI via `--no-build --binary`
|
commands. Pass the extracted, verified candidate CLI via `--no-build --binary`
|
||||||
and add `--baseline /path/to/beta.json` to the candidate command. Keep both
|
and add `--baseline /path/to/beta.json` to the candidate command. Keep both
|
||||||
reports and confirm all nine comparisons are present and correctness-verified.
|
reports and confirm all nine comparisons are present and correctness-verified.
|
||||||
The shared Woodpecker manual workflow runs the same comparison as a diagnostic
|
The shared Woodpecker manual workflow can reproduce the comparison and
|
||||||
and produces SMOKE reports.
|
produces SMOKE reports.
|
||||||
Reference in new issue
Block a user