Re: [PATCH] perf_events: fix validate_event bug

From: Paul Mackerras
Date: Tue Nov 24 2009 - 19:44:15 EST


stephane eranian writes:

> That means we can drop is_software_event() in this code and instead
> define locally
> in x86 a is_hw_pmu_event() function as event->pmu == &pmu.

I'd have to see the patch, but that doesn't feel entirely right,
because there is a unique characteristic of software events, compared
to hardware or breakpoint events: they are never capacity
constrained. In the past, only hardware events were capacity
constrained, which meant that all the decisions about whether a group
could go on could be done in the hardware PMU backend. Now we have
two sources of capacity constraints, so it may be that a group can't
go on even if the hardware PMU has capacity. That's going to be
somewhat interesting to get completely right, I think.

Paul.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/