summaryrefslogtreecommitdiff
path: root/mydtrace.h
diff options
context:
space:
mode:
authorShawn M Moore <code@sartak.org>2012-08-24 10:35:08 +0200
committerFather Chrysostomos <sprout@cpan.org>2012-08-28 07:13:44 -0700
commitfe83c362fb182e46bac02c1bd1cf0b8d82c9f1bf (patch)
tree9d7da5e5a98ef9a21b90f1067f175b54145e3de6 /mydtrace.h
parent9e7f031c1856270daeb95d2b6db9817469855476 (diff)
downloadperl-fe83c362fb182e46bac02c1bd1cf0b8d82c9f1bf.tar.gz
"op-entry" DTrace probe
Diffstat (limited to 'mydtrace.h')
-rw-r--r--mydtrace.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/mydtrace.h b/mydtrace.h
index 1c969ee604..8ee130f609 100644
--- a/mydtrace.h
+++ b/mydtrace.h
@@ -32,6 +32,12 @@
PERL_SUB_RETURN(tmp_func, file, line, stash); \
}
+# define OP_ENTRY_PROBE(name) \
+ if (PERL_OP_ENTRY_ENABLED()) { \
+ const char *tmp_name = name; \
+ PERL_OP_ENTRY(tmp_name, file, line, stash); \
+ }
+
# else
# define ENTRY_PROBE(func, file, line, stash) \
@@ -44,6 +50,11 @@
PERL_SUB_RETURN(func, file, line, stash); \
}
+# define OP_ENTRY_PROBE(name) \
+ if (PERL_OP_ENTRY_ENABLED()) { \
+ PERL_OP_ENTRY(name); \
+ }
+
# endif
# define PHASE_CHANGE_PROBE(new_phase, old_phase) \
@@ -57,6 +68,7 @@
# define ENTRY_PROBE(func, file, line, stash)
# define RETURN_PROBE(func, file, line, stash)
# define PHASE_CHANGE_PROBE(new_phase, old_phase)
+# define OP_ENTRY_PROBE(name)
#endif