Commit Graph

8 Commits

Author SHA1 Message Date
Kazuki Yamada d2563188c0 style(perf-benchmark): Format regex with Biome
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 21:15:31 +09:00
Kazuki Yamada 362a8ebe7c fix(perf-benchmark): Make regex backwards-compatible with old <code> format
Make <code> tags optional in the commit SHA regex so existing benchmark
comments with the old format are still parsed correctly during transition.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 21:05:20 +09:00
Kazuki Yamada 86a4208f02 ci(perf-benchmark): Remove <code> tags from commit SHAs for GitHub autolink
GitHub auto-links 7+ char commit SHAs in PR comments, but wrapping them
in <code> HTML tags prevented this. Remove the tags so SHAs become
clickable links automatically.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-29 17:00:48 +09:00
Kazuki Yamada 50a2cc0f2e fix(ci): Exit with error when all benchmark runs fail
Add early exit guard matching bench-run-history.mjs behavior, so a
broken build fails the workflow step instead of silently reporting 0ms.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 23:54:29 +09:00
Kazuki Yamada 1dbaebc884 refactor(ci): Address review feedback and fix lint errors
- Alternate PR/main execution order on even/odd iterations to neutralize
  ordering bias from CPU/filesystem cache warming
- Add try/catch in measurement loops so a single failure doesn't lose
  all data; abort if all runs fail
- Extract shared esc(), extractHistory(), renderHistory() into
  bench-utils.mjs to eliminate duplication between pending and comment
- Add error logging for JSON parse failures instead of silent catch
- Fix biome lint: use template literals, sort imports, expand
  single-line try/catch blocks, avoid assignment in expressions

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 23:49:18 +09:00
Kazuki Yamada 8e7cfe9b78 refactor(ci): Move history benchmark script to perf-benchmark-history/
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 23:37:22 +09:00
Kazuki Yamada d19065e14a perf(ci): Extract benchmark-history script and increase runs
- Extract inline benchmark script to bench-run-history.mjs
- Increase measurement runs from 10/20/10 to 20/30/20 to match
  perf-benchmark.yml for consistency

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 23:36:54 +09:00
Kazuki Yamada d3153e9c45 perf(ci): Improve benchmark stability with interleaved execution and extract scripts
- Switch from sequential (all PR then all main) to interleaved execution
  (PR→main alternating) so both branches experience similar runner load
  conditions, reducing variance in the measured difference
- Increase measurement runs from 10/20/10 to 20/30/20 for better
  statistical stability
- Extract inline Node.js scripts from YAML into separate .mjs files
  under .github/scripts/perf-benchmark/ for maintainability
- Use sparse-checkout for jobs that only need the scripts

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-28 23:35:19 +09:00