linux/include/trace
Steven Rostedt 3fd40d1ee6 tracing: Use helper functions in event assignment to shrink macro size
The functions that assign the contents for the ftrace events are
defined by the TRACE_EVENT() macros. Each event has its own unique
way to assign data to its buffer. When you have over 500 events,
that means there's 500 functions assigning data uniquely for each
event (not really that many, as DECLARE_EVENT_CLASS() and multiple
DEFINE_EVENT()s will only need a single function).

By making helper functions in the core kernel to do some of the work
instead, we can shrink the size of the kernel down a bit.

With a kernel configured with 502 events, the change in size was:

   text    data     bss     dec     hex filename
12987390        1913504 9785344 24686238        178ae9e /tmp/vmlinux
12959102        1913504 9785344 24657950        178401e /tmp/vmlinux.patched

That's a total of 28288 bytes, which comes down to 56 bytes per event.

Link: http://lkml.kernel.org/r/20120810034708.370808175@goodmis.org

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
2014-03-07 10:06:07 -05:00
..
events intel_pstate: Remove energy reporting from pstate_sample tracepoint 2014-02-13 02:11:18 +01:00
define_trace.h tracing: Add DEFINE_EVENT_FN() macro 2013-06-20 22:24:32 -07:00
ftrace.h tracing: Use helper functions in event assignment to shrink macro size 2014-03-07 10:06:07 -05:00
syscall.h tracing: Add missing syscall_metadata comment 2013-07-01 20:34:25 -04:00