Skip to contentSkip to conversation

Perf framework : Cluster based counter support

DISCUSSION Mukesh Ojha 2 participants 4 messages Jun 28, 2019 – Jul 1, 2019

lore
Share & tools
lore
#0 lore raw

Hi All,

Is it looks considerable to add cluster based event support to add in current perf event framework and later in userspace perf to support such events ?

Thanks,
Mukesh

#1 lore raw
Quoted 1 line · Mukesh Ojha

Hi All,

Hi Mukesh,

Quoted 3 lines

Is it looks considerable to add cluster based event support to add in current perf event framework and later in userspace perf to support such events ?

Could you elaborate on what you mean by "cluster based event"?

I assume you mean something like events for a cluster-affine shared resource like some level of cache?

If so, there's a standard pattern for supporting such system/uncore PMUs, see drivers/perf/qcom_l2_pmu.c and friends for examples.

Thanks,
Mark.

#2 lore raw
Quoted 7 lines · Mark Rutland
Quoted 1 line · Mukesh Ojha

Hi All,

Hi Mukesh,

Quoted 3 lines

Is it looks considerable to add cluster based event support to add in current perf event framework and later in userspace perf to support such events ?

Quoted 7 lines

Could you elaborate on what you mean by "cluster based event"?

I assume you mean something like events for a cluster-affine shared resource like some level of cache?

If so, there's a standard pattern for supporting such system/uncore PMUs, see drivers/perf/qcom_l2_pmu.c and friends for examples.

Thanks Mark for pointing it out.
Also What is stopping us in adding cluster based event e.g L2 cache hit/miss or some other type raw events  in core framework ?

Thanks.
Mukesh

Quoted 3 lines

Thanks,
Mark.

#3 lore raw
Quoted 14 lines · Mukesh Ojha
Quoted 12 lines · Mark Rutland
Quoted 1 line · Mukesh Ojha

Hi All,

Hi Mukesh,

Quoted 3 lines

Is it looks considerable to add cluster based event support to add in current perf event framework and later in userspace perf to support such events ?

Could you elaborate on what you mean by "cluster based event"?

I assume you mean something like events for a cluster-affine shared resource like some level of cache?

Quoted 6 lines
Quoted 2 lines

If so, there's a standard pattern for supporting such system/uncore PMUs, see drivers/perf/qcom_l2_pmu.c and friends for examples.

Thanks Mark for pointing it out.
Also What is stopping us in adding cluster based event e.g L2 cache hit/miss or some other type raw events  in core framework ?

That depends on how the event is exposed.

If it's exposed via the architectural PMU, then it's already accessible as a raw (cpu-affine) event, regardless of whether that makes sense.

If it's a separate PMU (as I suspect is the case), then it simply has to be a separate PMU driver.

Thanks,
Mark.