Skip to content

Handle uppercase cbr state in perf output - #378

Closed
yinli-systems wants to merge 2 commits into
janestreet:masterfrom
yinli-systems:kevin/cbr-uppercase-state
Closed

yinli-systems wants to merge 2 commits into
janestreet:masterfrom
yinli-systems:kevin/cbr-uppercase-state

Conversation

@yinli-systems

@yinli-systems yinli-systems commented Jun 24, 2026 •

Copy link
Copy Markdown

Fixes #324.

Summary

Root cause

perf_cbr_event_re only allowed lowercase letters in the optional text between the event name and frequency payload. Perf can emit uppercase task-state text such as D, so parsing raised before extracting the frequency.

The regression verifies that the reported line parses as a Power event with frequency 3629 MHz.

Validation

Validated in a clean x86_64 Alpine 3.23.5 environment using the repository-pinned OxCaml switch and locked dependencies:

  • opam install . --deps-only --locked --with-test
  • dune build @fmt
  • make PROFILE=static
  • dune runtest --profile=static
  • git diff --check

All commands completed successfully.

AI assistance

AI assistance was used to reproduce the repository's x86 build environment and inspect the validation output. I reviewed the code change, the issue fixture, and the resulting test evidence before submission.

Kevin-Li-2025 and others added 2 commits June 24, 2026 13:57
Signed-off-by: Kevin-Li-2025 <2242139@qq.com>
Signed-off-by: Kevin-Li-2025 <kxl474@student.bham.ac.uk>
@yinli-systems

Copy link
Copy Markdown
Author

@Svetlitski, could you take a look when convenient? This is intentionally narrow: the ignored CBR state field now accepts uppercase letters, and the expect test uses the exact Ubuntu 24.04 / perf 6.8 line from #324 and asserts 3629 MHz. I refreshed the branch on current master; locked dependency install, @fmt, the x86_64 static build, and the full static-profile test suite all pass.

@yinli-systems yinli-systems closed this by deleting the head repository Oct 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

"exception raised while parsing perf output" with "cbr: 36 freq: 3629 MHz (450%)"

1 participant