lkml.org 
[lkml]   [2013]   [Mar]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 22/29] locking, tsx: Add a trace point for elision skipping
Date
From: Andi Kleen <ak@linux.intel.com>

For tuning the adaptive locking algorithms it's useful to trace adaptive
elision skipping. Add a trace point for this case.

Used in followon patches

Signed-off-by: Andi Kleen <ak@linux.intel.com>
---
include/trace/events/elision.h | 31 +++++++++++++++++++++++++++++++
1 files changed, 31 insertions(+), 0 deletions(-)
create mode 100644 include/trace/events/elision.h

diff --git a/include/trace/events/elision.h b/include/trace/events/elision.h
new file mode 100644
index 0000000..5d16d02
--- /dev/null
+++ b/include/trace/events/elision.h
@@ -0,0 +1,31 @@
+#undef TRACE_SYSTEM
+#define TRACE_SYSTEM elision
+
+#if !defined(_TRACE_ELISION_H) || defined(TRACE_HEADER_MULTI_READ)
+#define _TRACE_ELISION_H
+
+#include <linux/lockdep.h>
+#include <linux/tracepoint.h>
+
+#ifdef CONFIG_RTM_LOCKS
+
+TRACE_EVENT(elision_skip_start,
+ TP_PROTO(void *lock, u32 status),
+ TP_ARGS(lock, status),
+ TP_STRUCT__entry(
+ __field(void *, lock)
+ __field(u32, status)
+ ),
+ TP_fast_assign(
+ __entry->lock = lock;
+ __entry->status = status;
+ ),
+ TP_printk("%p %x", __entry->lock, __entry->status)
+);
+
+#endif
+
+#endif
+
+/* This part must be outside protection */
+#include <trace/define_trace.h>
--
1.7.7.6


\
 
 \ /
  Last update: 2013-03-23 02:41    [W:0.162 / U:1.756 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site