Page MenuHomeFreeBSD

hwpmc: add PMC_OP_GETCPUMASK
AcceptedPublic

Authored by ojanerif_amd.com on Fri, Oct 16, 12:21 PM.
Tags
None
Referenced Files
F176387637: D60767.diff
Sun, Oct 18, 11:27 AM
Unknown Object (File)
Sat, Oct 17, 7:22 AM
Unknown Object (File)
Sat, Oct 17, 7:22 AM
Unknown Object (File)
Fri, Oct 16, 11:59 PM
Unknown Object (File)
Fri, Oct 16, 11:52 PM
Unknown Object (File)
Fri, Oct 16, 9:56 PM
Unknown Object (File)
Fri, Oct 16, 7:56 PM
Unknown Object (File)
Fri, Oct 16, 4:37 PM
Subscribers

Details

Summary

pmcstat derives the CPUs for system-mode PMCs from PMC_CAP_SYSWIDE and
PMC_CAP_DOMWIDE, which cannot describe AMD L3 counters (per L3 cache)
or DF and UMC counters (per package), so it counted one L3 cache per
NUMA domain.

Add PMC_OP_GETCPUMASK and pmc_cpumask(3) to return those CPUs, with a
default derived from the capabilities and a pcd_get_cpumask override.
Implement it for AMD and use it in pmcstat.

Sponsored by: AMD
Signed-off-by: Osvaldo Janeri Filho <ojanerif@amd.com>

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

@ali_mashtizadeh.com, this is the CPU mask interface we discussed: hwpmc reports the CPUs to allocate each system-mode PMC on (one per L3 cache for L3, one per package for DF and UMC) and pmcstat uses them. Is this what you had in mind? L3 events count all slices by default; tell me if you need per-slice control.

As soon you confirm, we can ask others reviewers to take a look

bcr added a subscriber: bcr.

OK from manpages.

This revision is now accepted and ready to land.Sat, Oct 17, 6:24 PM