Page MenuHomeFreeBSD

libpmcstat: parse {a,b,c} brace-list event group syntax
Needs ReviewPublic

Authored by afscoelho_gmail.com on Jun 18 2026, 7:06 AM.
Tags
None
Referenced Files
F175370555: D57636.id188463.diff
Sat, Oct 10, 8:50 AM
F175370515: D57636.id188248.diff
Sat, Oct 10, 8:49 AM
F175365313: D57636.id188100.diff
Sat, Oct 10, 7:51 AM
Unknown Object (File)
Thu, Oct 8, 1:43 PM
Unknown Object (File)
Wed, Oct 7, 4:00 AM
Unknown Object (File)
Wed, Oct 7, 4:00 AM
Unknown Object (File)
Wed, Oct 7, 1:29 AM
Unknown Object (File)
Tue, Oct 6, 12:47 AM
Subscribers
None

Details

Summary

Parse the brace-list event syntax "{a,b,c[,...]}" used by pmcstat -b.
The parser splits on commas at the top level of the brace and leaves
every other delimiter (including event qualifier ":" and pmu-event
sub-options) untouched.

For each comma-separated token a pmcstat_ev is built via the new
helper pmcstat_add_one_event(); the leader is marked with
ev_is_leader=1 and all events in the brace share an ev_groupid.
Single events outside any brace fall through unchanged.

Sponsored by: AMD
Signed-off-by: Raghavendra K T <raghavendra.kt@amd.com>

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 77637
Build 74520: arc lint + arc unit

Event Timeline

afscoelho_gmail.com updated this revision to Diff 185750.

Update to the rebuilt PerfMonV2 grouping and multiplexing stack.

Rebase on main (D60141 and D60185 are committed). No change.