Commit 1dc1c6ad authored by Frederic Weisbecker's avatar Frederic Weisbecker Committed by Ingo Molnar

tracing/function-return-tracer: call prepare_ftrace_return by registers

Impact: Optimize a bit the function return tracer

This patch changes the calling convention of prepare_ftrace_return to
pass its arguments by register. This will optimize it a bit and
prepare it to support dynamic tracing.
Signed-off-by: default avatarFrederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
parent 62d59d17
...@@ -1217,12 +1217,9 @@ trace_return: ...@@ -1217,12 +1217,9 @@ trace_return:
pushl %eax pushl %eax
pushl %ecx pushl %ecx
pushl %edx pushl %edx
movl 0xc(%esp), %eax movl 0xc(%esp), %edx
pushl %eax
lea 0x4(%ebp), %eax lea 0x4(%ebp), %eax
pushl %eax
call prepare_ftrace_return call prepare_ftrace_return
addl $8, %esp
popl %edx popl %edx
popl %ecx popl %ecx
popl %eax popl %eax
......
...@@ -95,7 +95,6 @@ unsigned long ftrace_return_to_handler(void) ...@@ -95,7 +95,6 @@ unsigned long ftrace_return_to_handler(void)
* Hook the return address and push it in the stack of return addrs * Hook the return address and push it in the stack of return addrs
* in current thread info. * in current thread info.
*/ */
asmlinkage
void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr) void prepare_ftrace_return(unsigned long *parent, unsigned long self_addr)
{ {
unsigned long old; unsigned long old;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment