[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <56D8EBA4.5090807@gmail.com>
Date: Fri, 4 Mar 2016 12:57:56 +1100
From: Balbir Singh <bsingharora@...il.com>
To: Michael Ellerman <mpe@...erman.id.au>, linuxppc-dev@...abs.org
Cc: duwe@....de, linux-kernel@...r.kernel.org, rostedt@...dmis.org,
kamalesh@...ux.vnet.ibm.com, pmladek@...e.com, jeyu@...hat.com,
jkosina@...e.cz, live-patching@...r.kernel.org, mbenes@...e.cz
Subject: Re: [PATCH v3 7/8] powerpc/ftrace: Add support for -mprofile-kernel
ftrace ABI
On 03/03/16 15:26, Michael Ellerman wrote:
> From: Torsten Duwe <duwe@...e.de>
>
> The gcc switch -mprofile-kernel defines a new ABI for calling _mcount()
> very early in the function with minimal overhead.
>
> Although mprofile-kernel has been available since GCC 3.4, there were
> bugs which were only fixed recently. Currently it is known to work in
> GCC 4.9, 5 and 6.
>
> Additionally there are two possible code sequences generated by the
> flag, the first uses mflr/std/bl and the second is optimised to omit the
> std. Currently only gcc 6 has the optimised sequence. This patch
> supports both sequences.
>
> Initial work started by Vojtech Pavlik, used with permission.
>
> Key changes:
> - rework _mcount() to work for both the old and new ABIs.
> - implement new versions of ftrace_caller() and ftrace_graph_caller()
> which deal with the new ABI.
> - updates to __ftrace_make_nop() to recognise the new mcount calling
> sequence.
> - updates to __ftrace_make_call() to recognise the nop'ed sequence.
> - implement ftrace_modify_call().
> - updates to the module loader to surpress the toc save in the module
> stub when calling mcount with the new ABI.
>
> Signed-off-by: Torsten Duwe <duwe@...e.de>
> Signed-off-by: Michael Ellerman <mpe@...erman.id.au>
> ---
>
Reviewed-by: Balbir Singh <bsingharora@...il.com>
Powered by blists - more mailing lists