Page MenuHomeFreeBSD

libpmc: make pmc_pmu_pmcallocate() machine-independent
ClosedPublic

Authored by mhorne on Jun 24 2023, 7:19 PM.
Tags
None
Referenced Files
F103833174: D40752.diff
Sat, Nov 30, 1:05 AM
Unknown Object (File)
Thu, Nov 21, 2:52 PM
Unknown Object (File)
Thu, Nov 21, 11:55 AM
Unknown Object (File)
Fri, Nov 8, 5:22 AM
Unknown Object (File)
Thu, Nov 7, 9:53 PM
Unknown Object (File)
Thu, Nov 7, 7:33 PM
Unknown Object (File)
Oct 6 2024, 5:58 AM
Unknown Object (File)
Oct 5 2024, 6:20 PM
Subscribers

Details

Summary

Have it call the platform-dependent version. For better layering, move
the reset logic inside the new function. This is mainly to facilitate an
upcoming change.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 52276
Build 49167: arc lint + arc unit

Event Timeline

jkoshy added inline comments.
lib/libpmc/libpmc.c
1053

Not related to this change, but I noticed that the count parameter that was added in 2018 is both undocumented and unnecessary - pmc_set(3)being the recommended way to set or change the counts associated with a PMC.

This revision is now accepted and ready to land.Jul 7 2023, 6:48 AM
lib/libpmc/libpmc.c
1053

It is documented by the pmc_allocate(3) man page at least -- apparently I did this in 50f6c13997008. But to your point, I do not know why it was added.