All of lore.kernel.org
 help / color / mirror / Atom feed
* notrace missing in lttng-ust
@ 2012-06-29  8:28 Woegerer, Paul
  0 siblings, 0 replies; 11+ messages in thread
From: Woegerer, Paul @ 2012-06-29  8:28 UTC (permalink / raw)
  To: lttng-dev

Hi Mathieu,

libust 0.x uses notrace (__attribute__((no_instrument_function)) for all 
functions that are involved in event emitting.

For example:
./libust/marker.c:122:notrace void __ust_marker_empty_function(const 
struct ust_marker *mdata,
./libust/marker.c:137:notrace void ust_marker_probe_cb(const struct 
ust_marker *mdata,
./libust/marker.c:197:static notrace void 
ust_marker_probe_cb_noarg(const struct ust_marker *mdata,

I just realized that this is no more the case for lttng-ust.
Was it a conscious decision not to use notrace for LTTng 2.0 lttng-ust, 
or is it just missing ?

I would like to have notrace also in lttng-ust, at least for the 
_DECLARE_TRACEPOINT macro in tracepoint.h.
Like this for example:

diff --git a/include/lttng/tracepoint.h b/include/lttng/tracepoint.h
index 5bab476..71665dc 100644
--- a/include/lttng/tracepoint.h
+++ b/include/lttng/tracepoint.h
@@ -137,6 +137,7 @@ extern "C" {

  #define _DECLARE_TRACEPOINT(_provider, _name, ...)     \
  extern struct tracepoint __tracepoint_##_provider##___##_name;         
     \
+static inline void 
__tracepoint_cb_##_provider##___##_name(_TP_ARGS_PROTO(__VA_ARGS__)) 
__attribute__ ((no_instrument_function));    \
  static inline void 
__tracepoint_cb_##_provider##___##_name(_TP_ARGS_PROTO(__VA_ARGS__)) \
  {                                            \
      struct tracepoint_probe *__tp_probe;                        \
@@ -158,12 +159,16 @@ end:     \
      tp_rcu_read_unlock_bp();                            \
  }                                            \
  static inline void __tracepoint_register_##_provider##___##_name(char 
*name,        \
+        void (*func)(void), void *data) __attribute__ 
((no_instrument_function));    \
+static inline void __tracepoint_register_##_provider##___##_name(char 
*name,        \
          void (*func)(void), void *data) \
  {                                            \
      __tracepoint_probe_register(name, func, data,     \
          __tracepoint_##_provider##___##_name.signature); \
  }                                            \
  static inline void 
__tracepoint_unregister_##_provider##___##_name(char *name,        \
+        void (*func)(void), void *data) __attribute__ 
((no_instrument_function));    \
+static inline void __tracepoint_unregister_##_provider##___##_name(char 
*name,        \
          void (*func)(void), void *data) \
  {                                            \
      __tracepoint_probe_unregister(name, func, data); \

Greetings,
Paul

-- 
Paul Woegerer | SW Development Engineer
Mentor Embedded(tm) | Prinz Eugen Straße 72/2/4, Vienna, 1040 Austria
P 43.1.535991320
Nucleus® | Linux® | Android(tm) | Services | UI | Multi-OS

Android is a trademark of Google Inc. Use of this trademark is subject to Google Permissions.
Linux is the registered trademark of Linus Torvalds in the U.S. and other countries.

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2012-10-01 15:29 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <4FED6718.1000205@mentor.com>
2012-06-30 18:16 ` notrace missing in lttng-ust Mathieu Desnoyers
     [not found] ` <20120630181600.GB30747@Krystal>
2012-07-03  7:45   ` Woegerer, Paul
     [not found]   ` <4FF2A31D.9020100@mentor.com>
2012-07-17 13:42     ` Woegerer, Paul
2012-07-17 14:13     ` Mathieu Desnoyers
     [not found]     ` <20120717141301.GA21204@Krystal>
2012-07-18 10:33       ` Woegerer, Paul
     [not found]       ` <500690E4.4020503@mentor.com>
2012-07-18 11:42         ` Mathieu Desnoyers
     [not found]         ` <20120718114216.GA4061@Krystal>
2012-07-18 12:51           ` Woegerer, Paul
     [not found]           ` <5006B15F.30509@mentor.com>
2012-07-18 19:32             ` Mathieu Desnoyers
2012-10-01  4:06       ` Francis Giraldeau
     [not found]       ` <506916A9.2050308@gmail.com>
2012-10-01 15:29         ` Mathieu Desnoyers
2012-06-29  8:28 Woegerer, Paul

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.