[Top] [All Lists]

Re: [PATCH -v4 9/9] tracing: add function graph tracer support for MIPS

Subject: Re: [PATCH -v4 9/9] tracing: add function graph tracer support for MIPS
From: Steven Rostedt <>
Date: Thu, 22 Oct 2009 11:20:22 -0400
Cc: David Daney <>,,, Thomas Gleixner <>, Ralf Baechle <>, Nicholas Mc Guire <>
In-reply-to: <1256218263.3852.115.camel@falcon>
Organization: Kihon Technologies Inc.
Original-recipient: rfc822;
References: <> <> <> <> <> <> <> <> <> <> <> <> <> <> <1256211516.3852.47.camel@falcon> <> <1256218263.3852.115.camel@falcon>
On Thu, 2009-10-22 at 21:31 +0800, Wu Zhangjin wrote:

> > If we don't stop at just one save, but look for the saving of ra, it
> > should not fail.
> > 
> We can not look for the saving of ra continuously(when should we stop?

When we hit something other than sw .... I'm sure we will get to
something other than a store. ;-)

> if with -fno-omit-fram-pointer, we have "move s8,sp" or "addiu sp, sp,
> -offset", but without it, we have no "guideboard" to know that is the
> beginning of the function!), 'Cause we may find the saving of ra of
> another function, which will fail at that time.

But that other function should have a jump to mcount before it, or some
other kind of return. A function that has _mcount attached, can not be
inlined. So something must have jumped to it. There should be no cases
where code from above just "falls" into the leaf function.

> BTW: Just replace probe_kernel_read() and tracing_stop/tracing_start by
> asm, it works in 32bit, but fails in 64bit, I'm trying to find why!(TLB
> miss on load or ifetch, will fix it asap! and resend the patchset out!)


-- Steve

Note, I'm going to try booting a vanilla kernel on the notebook. If it
works, I'll start applying your patches and playing with it too. But I
also have some other work to do first.

<Prev in Thread] Current Thread [Next in Thread>