Re: [RFC PATCH 1/2] x86: Fix rbp saving in pt_regs on irq entry

From: Frederic Weisbecker
Date: Fri Jan 07 2011 - 12:17:20 EST


On Fri, Jan 07, 2011 at 05:58:43PM +0100, Ingo Molnar wrote:
>
> * Frederic Weisbecker <fweisbec@xxxxxxxxx> wrote:
>
> > On Fri, Jan 07, 2011 at 04:13:58PM +0000, Jan Beulich wrote:
> > > >>> On 07.01.11 at 17:05, Frederic Weisbecker <fweisbec@xxxxxxxxx> wrote:
> > > > Once I'll have perf callchain based on CFI ready, we'll perhaps find some
> > > > issues
> > > > there. Although I guess there are already tools that can make use of that.
> > >
> > > Is this to read that you're planning to do a re-spin of the CFI
> > > unwinding code (which I'm not allowed to submit another time,
> > > but which we've been using for years in SuSE distros) then?
> >
> > An in-kernel CFI unwinder?
> >
> > No the intended CFI unwinding that I'm working on for perf is made
> > on post-processing, on top of partial stack and regs snapshots.
> >
> > The true unwinding is computed in userspace.
>
> I think that design will be fundamentally more robust and more flexible than an
> in-kernel unwinder.

But in fact for the kernel unwinding it still uses frame pointers which is certainly
the fastest and lightest way to unwind a stack. Very nice for our profiling.

Now one may argue about the loss of a register and its associated overhead, not
sure it's always noticeable though...
--
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/