RE: [PATCH 00/12] Cqm2: Intel Cache quality monitoring fixes

From: Luck, Tony
Date: Thu Feb 02 2017 - 12:39:41 EST


>> 7) Must be able to measure based on existing resctrl CAT group
>> 8) Can get measurements for subsets of tasks in a CAT group (to find the guys hogging the resources)
>> 9) Measure per logical CPU (pick active RMID in same precedence for task/cpu as CAT picks CLOSID)
>
> I agree that "Measure per logical CPU" is a requirement, but why is
> "pick active RMID in same precedence for task/cpu as CAT picks CLOSID"
> one as well? Are we set on handling RMIDs the way CLOSIDs are
> handled? there are drawbacks to do so, one is that it would make
> impossible to do CPU monitoring and CPU filtering the way is done for
> all other PMUs.

I'm too focused on monitoring existing CAT groups. If we move the parenthetical remark
from item 9, to item 7, then I think it is better. When monitoring a CAT group we need to
monitor exactly the processes that are controlled by the CAT group. So RMID must match
CLOSID, and the precedence rules make that work.

For other monitoring cases we can do things differently - so long as we have a way
to express what we want, and we don't pile a ton of code into context switch to figure
out which RMID is to be loaded into PQR_ASSOC.

I thought of another requirement this morning:

N+1) When we set up monitoring we must allocate all the resources we need (or fail the setup
if we can't get them). Not allowed to error in the middle of monitoring because we can't
find a free RMID)

-Tony