Messages in this thread Patch in this message |  | | | Subject | Re: [PATCH] tracing: Cleanup the convoluted softirq tracepoints | | From | Steven Rostedt <> | | Date | Tue, 19 Oct 2010 18:33:54 -0400 |
| |
On Wed, 2010-10-20 at 00:04 +0200, Thomas Gleixner wrote:
> hpa just posted code which does the _RIGHT_ _THING_ independent of any > compiler madness and you tracer folks just missed it.
Thomas,
Can you try this patch and see if it makes the object code better?
-- Steve
diff --git a/include/linux/tracepoint.h b/include/linux/tracepoint.h index a4a90b6..6264bd3 100644 --- a/include/linux/tracepoint.h +++ b/include/linux/tracepoint.h @@ -144,14 +144,19 @@ static inline void tracepoint_update_probe_range(struct tracepoint *begin, */ #define __DECLARE_TRACE(name, proto, args, data_proto, data_args) \ extern struct tracepoint __tracepoint_##name; \ - static inline void trace_##name(proto) \ + static __always_inline int __trace_##name(proto) \ { \ JUMP_LABEL(&__tracepoint_##name.state, do_trace); \ - return; \ + return 0; \ do_trace: \ __DO_TRACE(&__tracepoint_##name, \ TP_PROTO(data_proto), \ TP_ARGS(data_args)); \ + return 1; \ + } \ + static inline void trace_##name(proto) \ + { \ + unlikely(__trace_##name(args)); \ } \ static inline int \ register_trace_##name(void (*probe)(data_proto), void *data) \
|  |