2 # Architectures that offer an FTRACE implementation should select HAVE_FTRACE:
7 config HAVE_DYNAMIC_FTRACE
10 config HAVE_FTRACE_MCOUNT_RECORD
13 config TRACER_MAX_TRACE
23 bool "Kernel Function Tracer"
24 depends on HAVE_FTRACE
25 depends on DEBUG_KERNEL
28 select CONTEXT_SWITCH_TRACER
30 Enable the kernel to trace every kernel function. This is done
31 by using a compiler feature to insert a small, 5-byte No-Operation
32 instruction to the beginning of every kernel function, which NOP
33 sequence is then dynamically patched into a tracer call when
34 tracing is enabled by the administrator. If it's runtime disabled
35 (the bootup default), then the overhead of the instructions is very
36 small and not measurable even in micro-benchmarks.
39 bool "Interrupts-off Latency Tracer"
41 depends on TRACE_IRQFLAGS_SUPPORT
42 depends on GENERIC_TIME
43 depends on HAVE_FTRACE
44 depends on DEBUG_KERNEL
47 select TRACER_MAX_TRACE
49 This option measures the time spent in irqs-off critical
50 sections, with microsecond accuracy.
52 The default measurement method is a maximum search, which is
53 disabled by default and can be runtime (re-)started
56 echo 0 > /debugfs/tracing/tracing_max_latency
58 (Note that kernel size and overhead increases with this option
59 enabled. This option and the preempt-off timing option can be
60 used together or separately.)
63 bool "Preemption-off Latency Tracer"
65 depends on GENERIC_TIME
67 depends on HAVE_FTRACE
68 depends on DEBUG_KERNEL
70 select TRACER_MAX_TRACE
72 This option measures the time spent in preemption off critical
73 sections, with microsecond accuracy.
75 The default measurement method is a maximum search, which is
76 disabled by default and can be runtime (re-)started
79 echo 0 > /debugfs/tracing/tracing_max_latency
81 (Note that kernel size and overhead increases with this option
82 enabled. This option and the irqs-off timing option can be
83 used together or separately.)
90 This tracer provides the trace needed by the 'Sysprof' userspace
94 bool "Scheduling Latency Tracer"
95 depends on HAVE_FTRACE
96 depends on DEBUG_KERNEL
98 select CONTEXT_SWITCH_TRACER
99 select TRACER_MAX_TRACE
101 This tracer tracks the latency of the highest priority task
102 to be scheduled in, starting from the point it has woken up.
106 depends on HAVE_FTRACE
107 depends on DEBUG_KERNEL
110 This tracer does nothing. The primary purpose for it is to
111 politely print the output of ftrace_printk() calls without
112 the overhead of an irrelevant trace taking place.
114 config CONTEXT_SWITCH_TRACER
115 bool "Trace process context switches"
116 depends on HAVE_FTRACE
117 depends on DEBUG_KERNEL
121 This tracer gets called from the context switch and records
122 all switching of tasks.
125 bool "Trace max stack"
126 depends on HAVE_FTRACE
127 depends on DEBUG_KERNEL
131 This tracer records the max stack of the kernel, and displays
132 it in debugfs/tracing/stack_trace
134 config DYNAMIC_FTRACE
135 bool "enable/disable ftrace tracepoints dynamically"
137 depends on HAVE_DYNAMIC_FTRACE
138 depends on DEBUG_KERNEL
141 This option will modify all the calls to ftrace dynamically
142 (will patch them out of the binary image and replaces them
143 with a No-Op instruction) as they are called. A table is
144 created to dynamically enable them again.
146 This way a CONFIG_FTRACE kernel is slightly larger, but otherwise
147 has native performance as long as no tracing is active.
149 The changes to the code are done by a kernel thread that
150 wakes up once a second and checks to see if any ftrace calls
151 were made. If so, it runs stop_machine (stops all CPUS)
152 and modifies the code to jump over the call to ftrace.
154 config FTRACE_MCOUNT_RECORD
156 depends on DYNAMIC_FTRACE
157 depends on HAVE_FTRACE_MCOUNT_RECORD
159 config FTRACE_SELFTEST
162 config FTRACE_STARTUP_TEST
163 bool "Perform a startup test on ftrace"
165 depends on DEBUG_KERNEL
166 select FTRACE_SELFTEST
168 This option performs a series of startup tests on ftrace. On bootup
169 a series of tests are made to verify that the tracer is
170 functioning properly. It will do tests on all the configured