From: Eric B Munson <ebmunson@us.ibm.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: mingo@elte.hu, acme@redhat.com, arjan@linux.intel.com,
anton@samba.org, riel@redhat.com, linux-kernel@vger.kernel.org,
linux-mm@kvack.org
Subject: Re: [PATCH] Split executable and non-executable mmap tracking
Date: Mon, 17 May 2010 14:48:03 +0100 [thread overview]
Message-ID: <20100517134803.GC8042@us.ibm.com> (raw)
In-Reply-To: <1274102475.1674.1494.camel@laptop>
[-- Attachment #1: Type: text/plain, Size: 1606 bytes --]
On Mon, 17 May 2010, Peter Zijlstra wrote:
> On Fri, 2010-05-07 at 10:05 +0100, Eric B Munson wrote:
> > This patch splits tracking of executable and non-executable mmaps.
> > Executable mmaps are tracked normally and non-executable are
> > tracked when --data is used.
> >
> > Signed-off-by: Anton Blanchard <anton@samba.org>
> >
> > Updated code for stable perf ABI
> > Signed-off-by: Eric B Munson <ebmunson@us.ibm.com>
>
> > +++ b/include/linux/perf_event.h
> > @@ -197,6 +197,7 @@ struct perf_event_attr {
> > exclude_hv : 1, /* ditto hypervisor */
> > exclude_idle : 1, /* don't count when idle */
> > mmap : 1, /* include mmap data */
> > + mmap_exec : 1, /* include exec mmap data*/
> > comm : 1, /* include comm data */
> > freq : 1, /* use freq, not period */
> > inherit_stat : 1, /* per task counts */
>
> You cannot add a field in the middle, that breaks ABI.
>
> > -static inline void perf_event_mmap(struct vm_area_struct *vma)
> > -{
> > - if (vma->vm_flags & VM_EXEC)
> > - __perf_event_mmap(vma);
> > -}
>
> Also, the current behaviour of perf_event_attr::mmap() is to trace
> VM_EXEC maps only, apps relying on that will be broken after this patch
> because they'd have to set mmap_exec.
>
> If you want to do this, you'll have to add mmap_data (to the tail of the
> bitfield) and have that add !VM_EXEC mmap() tracing.
>
Thanks, I will get right on the changes.
--
Eric B Munson
IBM Linux Technology Center
ebmunson@us.ibm.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
prev parent reply other threads:[~2010-05-17 13:48 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-07 9:05 [PATCH] Split executable and non-executable mmap tracking Eric B Munson
2010-05-07 9:05 ` Eric B Munson
2010-05-17 13:21 ` Peter Zijlstra
2010-05-17 13:21 ` Peter Zijlstra
2010-05-17 13:48 ` Eric B Munson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100517134803.GC8042@us.ibm.com \
--to=ebmunson@us.ibm.com \
--cc=acme@redhat.com \
--cc=anton@samba.org \
--cc=arjan@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mingo@elte.hu \
--cc=peterz@infradead.org \
--cc=riel@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.