lkml.org 
[lkml]   [2010]   [May]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/5] perf: Disallow mmap() on per-task inherited events
From
Date
On Tue, 2010-05-25 at 10:55 +1000, Paul Mackerras wrote:
> On Tue, May 18, 2010 at 03:32:59PM +0200, Peter Zijlstra wrote:
>
> > Since we now have working per-task-per-cpu events for a while,
> > disallow mmap() on per-task inherited events. Those things were
> > a performance problem anyway, and doing away with it allows
> > us to optimize the buffer somewhat by assuming there is only a single
> > writer.
>
> This also disallows user-space access to hardware counter for this
> event -- which is arguably OK, since doing the userspace read would
> give a different answer to read() on the event fd, as the read() sums
> up all the child counters for us. Nevertheless, I think this
> side-effect is worth mentioning.

Right, using rdpmc (and similar) should be strictly limited to strict
self-monitoring.


\
 
 \ /
  Last update: 2010-05-25 10:23    [W:0.119 / U:4.064 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site