update version
[lttv.git] / ltt / branches / poly / ltt / event.h
index b45595d9150c2bb4194f6317fc6c28509720aec5..697b400ea4c5a08e1e7a8d2761010bb34870b3fa 100644 (file)
@@ -1,12 +1,13 @@
 #ifndef _LTT_EVENT_H
 #define _LTT_EVENT_H
 
-#include <ltt/time.h>
 #include <glib.h>
 #include <stdint.h>
 #include <sys/types.h>
-#include <ltt/ltt.h>
 #include <endian.h>
+#include <ltt/ltt.h>
+#include <ltt/time.h>
+#include <ltt/marker.h>
 
 /*
  * Structure LttEvent and LttEventPosition must begin with the _exact_ same
@@ -82,4 +83,30 @@ void ltt_event_position_copy(LttEventPosition *dest,
 
 LttTracefile *ltt_event_position_tracefile(LttEventPosition *ep);
 
+/* These functions extract data from an event after architecture specific
+ *    conversions. */
+
+guint32 ltt_event_get_unsigned(LttEvent *e, struct marker_field *f);
+
+gint32 ltt_event_get_int(LttEvent *e, struct marker_field *f);
+
+guint64 ltt_event_get_long_unsigned(LttEvent *e, struct marker_field *f);
+
+gint64 ltt_event_get_long_int(LttEvent *e, struct marker_field *f);
+
+float ltt_event_get_float(LttEvent *e, struct marker_field *f);
+
+double ltt_event_get_double(LttEvent *e, struct marker_field *f);
+
+
+/* The string obtained is only valid until the next read from
+ *    the same tracefile. */
+
+gchar *ltt_event_get_string(LttEvent *e, struct marker_field *f);
+
+static inline LttCycleCount ltt_event_cycle_count(const LttEvent *e)
+{
+  return e->tsc;
+}
+
 #endif //_LTT_EVENT_H
This page took 0.022538 seconds and 4 git commands to generate.