[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <c62985530902040850u5f9e7ca2w6ffbf553ec15eec5@mail.gmail.com>
Date: Wed, 4 Feb 2009 17:50:24 +0100
From: Frédéric Weisbecker <fweisbec@...il.com>
To: avorontsov@...mvista.com, Steven Rostedt <srostedt@...hat.com>
Cc: Ingo Molnar <mingo@...e.hu>, Paul Mackerras <paulus@...ba.org>,
Benjamin Herrenschmidt <benh@...nel.crashing.org>,
linuxppc-dev@...abs.org, linux-kernel@...r.kernel.org,
linux-rt-users@...r.kernel.org
Subject: Re: [PATCH 3/3] tracing: Tracers that use CALLER_ADDR macros should
select FRAME_POINTER
2009/2/4 Steven Rostedt <srostedt@...hat.com>:
>
> >From ftrace.h:
>
> #ifdef CONFIG_FRAME_POINTER
> /* TODO: need to fix this for ARM */
> # define CALLER_ADDR0 ((unsigned long)__builtin_return_address(0))
> # define CALLER_ADDR1 ((unsigned long)__builtin_return_address(1))
> # define CALLER_ADDR2 ((unsigned long)__builtin_return_address(2))
> # define CALLER_ADDR3 ((unsigned long)__builtin_return_address(3))
> # define CALLER_ADDR4 ((unsigned long)__builtin_return_address(4))
> # define CALLER_ADDR5 ((unsigned long)__builtin_return_address(5))
> # define CALLER_ADDR6 ((unsigned long)__builtin_return_address(6))
> #else
> # define CALLER_ADDR0 ((unsigned long)__builtin_return_address(0))
> # define CALLER_ADDR1 0UL
> # define CALLER_ADDR2 0UL
> # define CALLER_ADDR3 0UL
> # define CALLER_ADDR4 0UL
> # define CALLER_ADDR5 0UL
> # define CALLER_ADDR6 0UL
> #endif
>
> Yep!
>
Ok.
2009/2/4 Anton Vorontsov <avorontsov@...mvista.com>:
> It depends on the architecture. On PowerPC we always have frame pointers,
> thus __builtin_return_address(1..) will always work. On x86 it won't work
> that way.
>
> Thanks,
>
> --
> Anton Vorontsov
Thanks for your answers!
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists