lkml.org 
[lkml]   [2010]   [Mar]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [RFC][PATCH 2/3] perf: Take a hot regs snapshot for trace events
From
Date
On Wed, 2010-03-03 at 17:37 +0100, Peter Zijlstra wrote:

> > > /* Trace events already protected against recursion */
> > > do_perf_sw_event(PERF_TYPE_TRACEPOINT, event_id, count, 1,
> > > - &data, regs);
> > > + &data, &regs);
> >
> > Off-topic: Why is the above a perf sw event? Couldn't that also be a
> > normal TRACE_EVENT()?
>
> Well, no, this is the stuff that transforms TRACE_EVENT() into perf
> software events ;-)
>

oops, my bad :-), I thought this was in the x86 arch directory. For the
University, I was helping them with adding trace points for page faults
when I came across this in arch/x86/mm/fault.c:

perf_sw_event(PERF_COUNT_SW_PAGE_FAULTS, 1, 0, regs, address);


This is what I actually was wondering about. Why is it a "perf only"
trace point instead of a TRACE_EVENT()?

-- Steve




\
 
 \ /
  Last update: 2010-03-03 18:09    [W:0.072 / U:4.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site