Re: [RFC 4/5] x86, perf: implements lwp-perf-integration (rc1)

From: Gleb Natapov
Date: Wed Dec 21 2011 - 06:46:33 EST


On Tue, Dec 20, 2011 at 07:40:04PM +0100, Ingo Molnar wrote:
> > The point is, if user-space re-programs LWP it will continue
> > to write its samples to the new ring-buffer virtual-address
> > set up by user-space. It will still use that virtual address
> > in another address-space after a task-switch. This allows
> > processes to corrupt memory of other processes. [...]
>
> That's nonsense. As i said it my previous mail the LWPC should
> be per task and switched on task switch - just like the DS/PEBS
> context is.
>
Is it? Looking at arch/x86/kernel/cpu/perf_event_intel_ds.c it seems
like DS is per cpu, not per task.

--
Gleb.
--
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/