Skip to content

Commit 4bff751

Browse files
committed
misc: Add CI performance PR reporting skill
Change-Id: I84469b96bbc9f70c84d0d4ddc70f939f0034b9c5
1 parent 9e9e4bc commit 4bff751

2 files changed

Lines changed: 75 additions & 0 deletions

File tree

Lines changed: 71 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
---
2+
name: ci-perf-pr-report
3+
description: 用于在 OpenXiangShan/GEM5 手动性能 CI 完成后,选择严格可比的 baseline,汇总总分、benchmark 子项和关键性能计数器,并生成或发布 PR 性能评论。适用于用户给出 candidate/baseline run、要求分析 CI 性能收益、准备会议数据,或要求把分析更新到 PR 时。
4+
---
5+
6+
# CI 性能 PR 报告
7+
8+
把已完成的性能 CI 转成可审阅、可追溯的 PR 评论。复用相邻的
9+
`ci-perf-analysis` skill 取数;不包含 RTL 对齐或特定 predictor 分析。
10+
11+
## 输入
12+
13+
尽量取得:
14+
15+
- candidate run URL/ID;
16+
- baseline run URL/ID,或足以定位 baseline 的 commit/config/profile;
17+
- 目标 PR;
18+
- feature 说明,以及是否明确授权发布评论。
19+
20+
缺少 baseline 时可以搜索,但不得静默选择口径不一致的 run。
21+
22+
## 工作流
23+
24+
1. 完整读取 `../ci-perf-analysis/SKILL.md`,按其中流程定位归档并处理数据。
25+
2. 检查 candidate 和 baseline 的 `status``conclusion`、SHA、workflow、配置、
26+
benchmark/profile、coverage、extra args 和 abort 数。run 未完成时继续监控;不要把
27+
“已创建”写成“已通过”。
28+
3. baseline 优先级:用户明确指定 > 同 SHA 的 feature-off control > 同配置的相邻
29+
main/weekly baseline。若编译器、checkpoint、coverage 或关键参数不同,明确标注
30+
confounder,不做严格因果归因。
31+
4. 从原始 `score.txt` 和处理后的 CSV 交叉核对 Overall、SPECint、SPECfp;展开
32+
benchmark 子项的 raw delta 和相对变化,不只报告总分。
33+
5. 只选择能解释 feature 的少量 stats:
34+
- 通用:IPC/CPI、Topdown frontend/bad-spec/backend/memory;
35+
- 前端:fetch/recovery bubble、fragment stall、branch miss;
36+
- 后端/访存:dispatch stall、core/memory bound、cache MPKI/latency。
37+
优先比较 rate、MPKI 或 weighted 指标;指令数不同时不要直接解释 raw count。
38+
6. 用重点 benchmark 和计数器证据解释收益/回退,区分确认事实、合理推断和未决问题。
39+
7. 生成简洁的英文 PR 评论;用户明确要求发布时再执行外部写入,并回查评论 URL。
40+
41+
## PR 评论结构
42+
43+
```markdown
44+
## Performance result
45+
46+
- Candidate: <run, SHA, config/profile>
47+
- Baseline: <run, SHA, config/profile>
48+
- Completeness: <coverage, aborts>
49+
50+
### Score
51+
| Suite | Baseline | Candidate | Change |
52+
53+
### Benchmark breakdown
54+
<主要收益、回退及完整 suite 子项>
55+
56+
### Counter evidence
57+
<少量与 feature 直接相关的 weighted stats>
58+
59+
### Interpretation
60+
<结论、因果边界和剩余风险>
61+
```
62+
63+
PR 评论中直接链接 Actions run;不要包含 Codex memory citation。若数据不完整,发布
64+
状态更新而非最终性能结论。除非用户明确要求更新既有评论,否则发布一条新评论。
65+
66+
## 完成标准
67+
68+
- 两组数据的比较口径已审计;
69+
- score 与 benchmark 子项已交叉核对;
70+
- 有可比 stats 时,至少一组相关计数器支持或限制结论;否则明确数据缺口;
71+
- 已授权时评论发布成功并返回 URL,否则提供可直接发布的 draft。
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
interface:
2+
display_name: "CI Perf PR Report"
3+
short_description: "Compare gem5 CI runs and publish a PR report"
4+
default_prompt: "Use $ci-perf-pr-report to compare a completed gem5 performance CI run with its baseline, analyze key counters, and post the result to the target PR."

0 commit comments

Comments
 (0)