Page MenuHomeFreeBSD

hwpmc: multiplex system-mode groups per CPU
DraftPublic

Authored by afscoelho_gmail.com on Thu, Sep 3, 9:32 PM.
Tags
None
Referenced Files
F170547983: D59359.id185756.diff
Sat, Sep 5, 8:44 AM
F170531630: D59359.id.diff
Sat, Sep 5, 6:45 AM
Unknown Object (File)
Fri, Sep 4, 10:11 PM
Unknown Object (File)
Fri, Sep 4, 9:05 PM
Unknown Object (File)
Fri, Sep 4, 8:01 PM
Unknown Object (File)
Fri, Sep 4, 7:33 AM
Subscribers
This is a draft revision that has not yet been submitted for review.

Details

Summary

Add grouping and multiplexing for system-mode (PMC_MODE_SC) groups. A
system group counts on one CPU and has no target process, so it needs a
per-CPU rotation list and a per-CPU rotation thread instead of the
per-process ones that a virtual group uses.

pmu_sys_schedule_in checks the owner's allocation permission, assigns
the rows, and starts every member. If a member fails to start, it stops
the members that already started and releases the rows, so a row does
not stay running unpublished. pmu_sys_schedule_out stops the rows,
drains the samples of the group, and releases the rows.

pmu_syscpu_rotate_one runs one rotation tick for a CPU. Group release
now calls pmu_sys_group_pre_release first, so that a system group leaves
the per-CPU list before the rest of the release runs.

Sponsored by: AMD

Diff Detail

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