aboutsummaryrefslogtreecommitdiffstats
path: root/arch/Kconfig
diff options
context:
space:
mode:
authorMasami Hiramatsu <mhiramat@redhat.com>2010-02-25 08:34:07 -0500
committerIngo Molnar <mingo@elte.hu>2010-02-25 11:49:24 -0500
commitafd66255b9a48f5851326ddae50e2203fbf71dc9 (patch)
tree32c7a36a8e2c740b989f16b3e2878f8c565d57f8 /arch/Kconfig
parent4610ee1d3638fa05ba8e87ccfa971db8e4033ae7 (diff)
kprobes: Introduce kprobes jump optimization
Introduce kprobes jump optimization arch-independent parts. Kprobes uses breakpoint instruction for interrupting execution flow, on some architectures, it can be replaced by a jump instruction and interruption emulation code. This gains kprobs' performance drastically. To enable this feature, set CONFIG_OPTPROBES=y (default y if the arch supports OPTPROBE). Changes in v9: - Fix a bug to optimize probe when enabling. - Check nearby probes can be optimize/unoptimize when disarming/arming kprobes, instead of registering/unregistering. This will help kprobe-tracer because most of probes on it are usually disabled. Changes in v6: - Cleanup coding style for readability. - Add comments around get/put_online_cpus(). Changes in v5: - Use get_online_cpus()/put_online_cpus() for avoiding text_mutex deadlock. Signed-off-by: Masami Hiramatsu <mhiramat@redhat.com> Cc: systemtap <systemtap@sources.redhat.com> Cc: DLE <dle-develop@lists.sourceforge.net> Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com> Cc: Jim Keniston <jkenisto@us.ibm.com> Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com> Cc: Christoph Hellwig <hch@infradead.org> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Anders Kaseorg <andersk@ksplice.com> Cc: Tim Abbott <tabbott@ksplice.com> Cc: Andi Kleen <andi@firstfloor.org> Cc: Jason Baron <jbaron@redhat.com> Cc: Mathieu Desnoyers <compudj@krystal.dyndns.org> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com> LKML-Reference: <20100225133407.6725.81992.stgit@localhost6.localdomain6> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/Kconfig')
-rw-r--r--arch/Kconfig13
1 files changed, 13 insertions, 0 deletions
diff --git a/arch/Kconfig b/arch/Kconfig
index 9d055b4f0585..e0ad3caf16d9 100644
--- a/arch/Kconfig
+++ b/arch/Kconfig
@@ -57,6 +57,17 @@ config KPROBES
57 for kernel debugging, non-intrusive instrumentation and testing. 57 for kernel debugging, non-intrusive instrumentation and testing.
58 If in doubt, say "N". 58 If in doubt, say "N".
59 59
60config OPTPROBES
61 bool "Kprobes jump optimization support (EXPERIMENTAL)"
62 default y
63 depends on KPROBES
64 depends on !PREEMPT
65 depends on HAVE_OPTPROBES
66 select KALLSYMS_ALL
67 help
68 This option will allow kprobes to optimize breakpoint to
69 a jump for reducing its overhead.
70
60config HAVE_EFFICIENT_UNALIGNED_ACCESS 71config HAVE_EFFICIENT_UNALIGNED_ACCESS
61 bool 72 bool
62 help 73 help
@@ -99,6 +110,8 @@ config HAVE_KPROBES
99config HAVE_KRETPROBES 110config HAVE_KRETPROBES
100 bool 111 bool
101 112
113config HAVE_OPTPROBES
114 bool
102# 115#
103# An arch should select this if it provides all these things: 116# An arch should select this if it provides all these things:
104# 117#