mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-08-24 17:59:32 +00:00
![Andi Kleen](/assets/img/avatar_default.png)
The ftrace function tracer self tests calls some functions to verify the get traced. This relies on them not being inlined. Previously this was ensured by putting them into another file, but with LTO the compiler can inline across files, which makes the tests fail. Mark these functions as noinline and noclone. Link: http://lkml.kernel.org/r/20171221233732.31896-1-andi@firstfloor.org Signed-off-by: Andi Kleen <ak@linux.intel.com> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
15 lines
270 B
C
15 lines
270 B
C
// SPDX-License-Identifier: GPL-2.0
|
|
#include <linux/compiler.h>
|
|
#include "trace.h"
|
|
|
|
noinline __noclone int DYN_FTRACE_TEST_NAME(void)
|
|
{
|
|
/* used to call mcount */
|
|
return 0;
|
|
}
|
|
|
|
noinline __noclone int DYN_FTRACE_TEST_NAME2(void)
|
|
{
|
|
/* used to call mcount */
|
|
return 0;
|
|
}
|