Repository navigation
Conversation
|
Understand this PR’s impact Explore downstream dependencies and potential security impact with Blast Radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: pnpm/pnpm/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (6)
Included review availability: Your plan provides up to 10 included reviews per hour; 4 remain after this review. 📝 WalkthroughWalkthroughThe change adds confirmation runs for suspected integrated benchmark regressions. It introduces a Node benchmark runner, updates comparison handling, changes workflow invocations, expands tests, and documents reversed-order confirmation behavior. ChangesBenchmark confirmation
Priority: ⬇️ Low Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Bug fix Sequence Diagram(s)sequenceDiagram
participant Workflow
participant runBenchmark
participant integratedBenchmark
participant compare
Workflow->>runBenchmark: invoke benchmark scenario
runBenchmark->>integratedBenchmark: execute target arguments
integratedBenchmark-->>runBenchmark: write benchmark reports
runBenchmark->>compare: evaluate regression status
runBenchmark->>integratedBenchmark: rerun with reversed target order when needed
integratedBenchmark-->>runBenchmark: write confirmation report
runBenchmark-->>Workflow: return status and reports
Suggested labels: ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Warning Some tools did not complete. Review the errors below. 🔧 ESLint
.github/scripts/compare-integrated-benchmarks.mjsESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox. .github/scripts/compare-integrated-benchmarks.test.mjsESLint skipped: the matched ESLint configuration already failed (missing-dependency). .github/scripts/run-integrated-benchmark.mjsESLint skipped: the matched ESLint configuration already failed (missing-dependency).
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Same-run regression checkHEAD and main are measured on the same runner. The tolerance is 5% of the main median or 2 ms, whichever is larger. A regression requires both the median slowdown and the gap between the fastest retained HEAD sample and slowest retained main sample to exceed this tolerance, after trimming up to 10% from each tail. This conservative noise guard is not a statistical confidence interval. Inconclusive rows do not fail the check. They remain visible for performance review. Bencher retains absolute minimum timings for historical tracking; historical alerts do not gate this PR. Sequential measurements can still be affected by runner drift.
Integrated-Benchmark Report (Linux)Commit: Regular scenarios report direct and pnpr installs. The peer-heavy resolver scenario compares current Rust, main Rust, and TypeScript pnpm; the linked-workspace scenario compares current Rust against main Rust. Bencher consumes pacquet@HEAD and pnpr@HEAD. The tables below show mean ± σ. Bencher tracks absolute minimum latency; PR regression checks compare HEAD and main samples from the same runner. Historical timing alerts do not gate PRs. Scenario: Isolated linker: fresh restore, cold cache + cold store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 2.4684210583599997,
"stddev": 0.14541786767686832,
"median": 2.4330276724599997,
"user": 1.6203549599999998,
"system": 1.68338024,
"min": 2.3050643749599997,
"max": 2.71637813196
},
{
"command": "pacquet@main",
"mean": 2.47936871096,
"stddev": 0.13758863189458184,
"median": 2.42855221446,
"user": 1.67372546,
"system": 1.7683199400000003,
"min": 2.3528464909599998,
"max": 2.7685177079599996
},
{
"command": "pnpr@HEAD",
"mean": 1.49681110886,
"stddev": 0.12283549200275239,
"median": 1.4770882864600001,
"user": 1.4811952599999998,
"system": 1.53606664,
"min": 1.3153443789600001,
"max": 1.71817864196
},
{
"command": "pnpr@main",
"mean": 1.45844431736,
"stddev": 0.08682063992600603,
"median": 1.46706502846,
"user": 1.4772065599999997,
"system": 1.6216670400000002,
"min": 1.32887170596,
"max": 1.5587527439600002
}
]
}Scenario: Isolated linker: fresh restore, hot cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.26800296042,
"stddev": 0.011165445989097684,
"median": 0.26418276412,
"user": 0.29764673999999997,
"system": 0.6608880399999999,
"min": 0.25630106262,
"max": 0.29257341862
},
{
"command": "pacquet@main",
"mean": 0.25419876242000006,
"stddev": 0.012299158388920036,
"median": 0.24818907462,
"user": 0.28087504,
"system": 0.6277747399999999,
"min": 0.24289413162,
"max": 0.27705594262
},
{
"command": "pnpr@HEAD",
"mean": 0.29947132912,
"stddev": 0.03132067863321331,
"median": 0.29338841362,
"user": 0.31881013999999996,
"system": 0.6593435399999998,
"min": 0.26026612362,
"max": 0.35531978762
},
{
"command": "pnpr@main",
"mean": 0.29113634762,
"stddev": 0.012705916279966851,
"median": 0.28810892062000004,
"user": 0.32894253999999995,
"system": 0.63291464,
"min": 0.27879512462,
"max": 0.32183477762
}
]
}Scenario: Isolated linker: repeat install, hot cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.007009401843126682,
"stddev": 0.0005997368719853851,
"median": 0.0068672298,
"user": 0.004270112075471694,
"system": 0.0031568840970350428,
"min": 0.0060926568,
"max": 0.009394671799999999
},
{
"command": "pacquet@main",
"mean": 0.0074639313109890115,
"stddev": 0.001037208628279773,
"median": 0.0071658288,
"user": 0.00454499648351648,
"system": 0.0033854601648351645,
"min": 0.006009328800000001,
"max": 0.0141629588
},
{
"command": "pnpr@HEAD",
"mean": 0.007309313927999992,
"stddev": 0.0008632270031618606,
"median": 0.0071239718,
"user": 0.004630161333333335,
"system": 0.0030809525333333316,
"min": 0.006084309800000001,
"max": 0.0139810778
},
{
"command": "pnpr@main",
"mean": 0.007749114509779187,
"stddev": 0.0013642034059321792,
"median": 0.007482644800000001,
"user": 0.0047987592429022076,
"system": 0.0034037053627760253,
"min": 0.005814803800000001,
"max": 0.0138763318
}
]
}Scenario: Isolated linker: repeat install, cold cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.01044337226076923,
"stddev": 0.001470540022822435,
"median": 0.010435438180000001,
"user": 0.005959316923076919,
"system": 0.005216042076923075,
"min": 0.00736132618,
"max": 0.015161151180000002
},
{
"command": "pacquet@main",
"mean": 0.009975634689433964,
"stddev": 0.0011156467356497521,
"median": 0.00993397168,
"user": 0.005703698490566035,
"system": 0.004998001320754716,
"min": 0.007131507180000001,
"max": 0.013497220180000002
},
{
"command": "pnpr@HEAD",
"mean": 0.00928937421686636,
"stddev": 0.0007913666067203097,
"median": 0.00926232318,
"user": 0.005421471336405528,
"system": 0.004561499447004607,
"min": 0.00744604918,
"max": 0.011973007180000002
},
{
"command": "pnpr@main",
"mean": 0.0096015260290566,
"stddev": 0.0009213430727058066,
"median": 0.00940726318,
"user": 0.005227898415094342,
"system": 0.005072160754716979,
"min": 0.00781451818,
"max": 0.012377445180000002
}
]
}Scenario: Isolated linker: fresh install, cold cache + cold store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 2.7360324548400006,
"stddev": 0.060080567959761376,
"median": 2.7390852899400002,
"user": 2.8980190199999996,
"system": 2.3276355000000004,
"min": 2.61966015944,
"max": 2.8219009954400005
},
{
"command": "pacquet@main",
"mean": 2.84569669574,
"stddev": 0.17375747635231129,
"median": 2.7822348864400004,
"user": 3.07618782,
"system": 2.4891174,
"min": 2.62041650544,
"max": 3.13323568844
},
{
"command": "pnpr@HEAD",
"mean": 1.75740036804,
"stddev": 0.15965736360235241,
"median": 1.73421682444,
"user": 2.12467282,
"system": 2.1222385,
"min": 1.56148107144,
"max": 2.0253343694400003
},
{
"command": "pnpr@main",
"mean": 1.6923473178400001,
"stddev": 0.11877158062633882,
"median": 1.7088429494400001,
"user": 1.98757132,
"system": 1.9018799000000002,
"min": 1.52169483844,
"max": 1.90004228244
}
]
}Scenario: Isolated linker: fresh install, hot cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.52011855864,
"stddev": 0.08351352934542618,
"median": 0.51946641904,
"user": 0.8373946199999999,
"system": 1.0803667200000002,
"min": 0.41261993454,
"max": 0.71334478554
},
{
"command": "pacquet@main",
"mean": 0.62129652164,
"stddev": 0.10600427250052198,
"median": 0.63011275554,
"user": 0.9996061199999999,
"system": 1.17128952,
"min": 0.48934687654000003,
"max": 0.82460464254
},
{
"command": "pnpr@HEAD",
"mean": 0.3503312605400001,
"stddev": 0.029738265105355856,
"median": 0.35446159304,
"user": 0.29128111999999995,
"system": 0.6485547199999999,
"min": 0.30054409654,
"max": 0.39455183354
},
{
"command": "pnpr@main",
"mean": 0.37627366544,
"stddev": 0.03141348352690973,
"median": 0.37423430254,
"user": 0.34162412,
"system": 0.6329086199999999,
"min": 0.31543352554,
"max": 0.42560285654
}
]
}Scenario: Isolated linker: fresh install, cold cache + hot store
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 1.61175679154,
"stddev": 0.03234808349130026,
"median": 1.60677873324,
"user": 0.9513906999999999,
"system": 1.0031570000000003,
"min": 1.57852085924,
"max": 1.65740306624
},
{
"command": "pacquet@main",
"mean": 1.65119705274,
"stddev": 0.08410726474890566,
"median": 1.6304736962400002,
"user": 1.0158112,
"system": 1.0845529,
"min": 1.57284139624,
"max": 1.87821885624
},
{
"command": "pnpr@HEAD",
"mean": 0.30965944244,
"stddev": 0.01899630505164965,
"median": 0.30495266574,
"user": 0.2562774,
"system": 0.5852797,
"min": 0.28027672024,
"max": 0.34465563724
},
{
"command": "pnpr@main",
"mean": 0.30603009074,
"stddev": 0.018476284783803303,
"median": 0.30030847074,
"user": 0.2701935999999999,
"system": 0.5561310999999999,
"min": 0.28472208824,
"max": 0.34907755024
}
]
}Scenario: Isolated linker: fresh resolve, hot cache, offline
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.2573652675709091,
"stddev": 0.028899168588994842,
"median": 0.25335024648,
"user": 0.28097969636363634,
"system": 0.08828227454545452,
"min": 0.21929680948000002,
"max": 0.33565319248000003
},
{
"command": "pacquet@main",
"mean": 0.24581033848000003,
"stddev": 0.01592435510032277,
"median": 0.24543326748,
"user": 0.2614137266666667,
"system": 0.08693890333333332,
"min": 0.21526730448,
"max": 0.27048010848000004
},
{
"command": "pnpr@HEAD",
"mean": 0.10250067810500002,
"stddev": 0.0043955091819693,
"median": 0.10225835148,
"user": 0.043006684999999996,
"system": 0.017114653333333334,
"min": 0.09367046248,
"max": 0.11535075848
},
{
"command": "pnpr@main",
"mean": 0.1017866906585714,
"stddev": 0.008953900797518045,
"median": 0.10031365998,
"user": 0.04327077428571429,
"system": 0.01585617714285714,
"min": 0.09366785648,
"max": 0.14540336348
}
]
}Scenario: Isolated linker: peer-heavy resolve, hot cache, offline
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 1.2286172719355557,
"stddev": 0.3300595319675424,
"median": 1.23634336538,
"user": 1.2437899866666668,
"system": 0.2870500333333334,
"min": 0.5541908803800001,
"max": 1.67052812138
},
{
"command": "pacquet@main",
"mean": 1.1425618868244445,
"stddev": 0.3012251831310384,
"median": 1.1195455003800001,
"user": 1.1729999866666665,
"system": 0.25535336666666664,
"min": 0.65434392438,
"max": 1.7154208213800002
},
{
"command": "pnpm@HEAD",
"mean": 4.140096077491111,
"stddev": 0.45027660617141363,
"median": 4.00071913138,
"user": 6.5173570977777775,
"system": 0.2868019222222223,
"min": 3.6673046803799996,
"max": 5.15889194238
}
]
}Scenario: Isolated linker: linked-workspace resolve, hot cache, offline
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.17361211283882355,
"stddev": 0.004652352542781336,
"median": 0.17217216478,
"user": 0.12678388,
"system": 0.08320622352941176,
"min": 0.16739986878000002,
"max": 0.18663991878000002
},
{
"command": "pacquet@main",
"mean": 0.17383930354470586,
"stddev": 0.013354207639560266,
"median": 0.17044986678000001,
"user": 0.12465623294117648,
"system": 0.08323263529411765,
"min": 0.16477623978,
"max": 0.22195421178000002
}
]
}Scenario: Isolated linker: fresh restore, cold cache + cold store + cold pnpr
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 4.52547976704,
"stddev": 0.16052673766239428,
"median": 4.475575683840001,
"user": 1.7248686399999997,
"system": 1.8149896799999996,
"min": 4.30701549884,
"max": 4.82737597384
},
{
"command": "pacquet@main",
"mean": 4.7304766017399995,
"stddev": 0.3429687356731427,
"median": 4.71740622584,
"user": 2.0420832399999993,
"system": 2.04424978,
"min": 4.34064837684,
"max": 5.4734034758400005
},
{
"command": "pnpr@HEAD",
"mean": 3.6300258939399996,
"stddev": 0.15270367910252386,
"median": 3.64720253734,
"user": 1.9252913399999998,
"system": 1.9228395799999998,
"min": 3.41890650984,
"max": 3.90069399584
},
{
"command": "pnpr@main",
"mean": 3.56844907594,
"stddev": 0.13602675155970034,
"median": 3.55261135184,
"user": 1.7675128399999995,
"system": 1.86083128,
"min": 3.39413232384,
"max": 3.86334997484
}
]
}Scenario: GVS linker: fresh restore, hot cache + hot storeSame install as the isolated fresh-restore hot/hot scenario, into the shared virtual store, the layout pnpm 12 installs into by default. Scenarios run on separate machines, so compare main and branch within each table.
BENCHMARK_REPORT.json{
"results": [
{
"command": "pacquet@HEAD",
"mean": 0.12540446530000002,
"stddev": 0.006729852278377258,
"median": 0.1255383113,
"user": 0.15184060210526312,
"system": 0.13955636315789474,
"min": 0.1134699233,
"max": 0.1360527263
},
{
"command": "pacquet@main",
"mean": 0.12531208772857147,
"stddev": 0.01028007821862727,
"median": 0.12225539930000001,
"user": 0.15259628380952378,
"system": 0.1399876238095238,
"min": 0.11343306430000001,
"max": 0.1580296983
},
{
"command": "pnpr@HEAD",
"mean": 0.1305602885941177,
"stddev": 0.008473294570933874,
"median": 0.1257377953,
"user": 0.14968611294117648,
"system": 0.13596345294117648,
"min": 0.1214055193,
"max": 0.1510422653
},
{
"command": "pnpr@main",
"mean": 0.12476865970000002,
"stddev": 0.008034839272394055,
"median": 0.12083162580000001,
"user": 0.14086495999999998,
"system": 0.1359488,
"min": 0.1160262963,
"max": 0.1420161703
}
]
} |
PR Summary by QodoConfirm benchmark regressions with reversed-order reruns
AI Description
Diagram
High-Level Assessment
Files changed (6)
|
|
Code Review by Qodo🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)
Great, no issues found!Qodo reviewed your code and found no material issues that require reviewTip of the day💡 Did you know, you can add REVIEW.md to your repo root and Qodo follows it on every PR |
PR Code Suggestions ✨Warning
No code suggestions found for the PR. |
…pm#15231) Confirm suspected integrated benchmark regressions once with target order reversed. Same-run measurements can still be biased by sustained runner drift: a control run on identical Rust sources produced a 29% apparent pnpr slowdown. Keep the 5% tolerance with a 2 ms floor and the retained-sample noise guard. Require the regression to reproduce in the confirmation, preserve both sets of measurements in the artifact and report, and keep the initial timings for historical Bencher uploads. Missing required confirmations fail the check. The wrapper preserves the existing harness arguments and assertions. It does not retry command failures, and confirmation failures propagate. Main-only runs and scenarios without suspected regressions execute once. Related to pnpm#15228.
Summary
Follow-up to #15228. Its final benchmark run reported a 29% pnpr slowdown despite identical benchmarked Rust sources in HEAD and main. Same-run comparison removes cross-machine differences, but sequential measurements can still drift enough to produce a false regression.
Automatically repeat a suspected regression once with target order reversed. Fail the comparison only if the slowdown appears in both runs. Keep the agreed 5% tolerance with a 2 ms floor, preserve both reports, and continue uploading the initial timing to Bencher. Initial command failures are not retried, and confirmation failures propagate.
Validation: 18 Node tests pass, including transient and sustained slowdowns, reversed target order, no retry for stable/main-only runs, missing confirmations, and command failures. Workflow YAML and shell syntax checks pass. CI passed the full Rust and TypeScript matrices and all 12 benchmark scenarios. The new comparator passes the artifact with 20 rows within tolerance and two inconclusive rows. No scenario required a confirmation in this run; the confirmation branches are covered by the Node tests. The trusted comparison in the comment workflow takes effect after merge; this PR's comment workflow still runs the default-branch comparator.
Squash Commit Body
Checklist
No published packages change, so no changeset is needed.
Written by an agent (Codex, gpt-6).
Summary by CodeRabbit
Bug Fixes
Documentation
Chores