Fix name table expend in state.c
[lttv.git] / lttv / lttv / state.h
index ad7f9e064693f59590e9629ff52261a2001dfad2..afaf36a905362dcefd9a439ffc9f04bf1ecd0caa 100644 (file)
@@ -90,6 +90,7 @@ extern GQuark
     LTT_EVENT_SOFT_IRQ_ENTRY,
     LTT_EVENT_SOFT_IRQ_EXIT,
     LTT_EVENT_SCHED_SCHEDULE,
+    LTT_EVENT_SCHED_TRY_WAKEUP,
     LTT_EVENT_PROCESS_FORK,
     LTT_EVENT_KTHREAD_CREATE,
     LTT_EVENT_PROCESS_EXIT,
@@ -106,7 +107,10 @@ extern GQuark
     LTT_EVENT_SYS_CALL_TABLE,
     LTT_EVENT_SOFTIRQ_VEC,
     LTT_EVENT_KPROBE_TABLE,
-    LTT_EVENT_KPROBE;
+    LTT_EVENT_KPROBE,
+    LTT_EVENT_OPEN,
+    LTT_EVENT_READ,
+    LTT_EVENT_POLL_EVENT;
 
 /* Fields Quarks */
 
@@ -137,7 +141,8 @@ extern GQuark
     LTT_FIELD_ID,
     LTT_FIELD_ADDRESS,
     LTT_FIELD_SYMBOL,
-    LTT_FIELD_IP;
+    LTT_FIELD_IP,
+    LTT_FIELD_FD;
 
 typedef struct _LttvTracesetState LttvTracesetState;
 typedef struct _LttvTracesetStateClass LttvTracesetStateClass;
@@ -284,6 +289,7 @@ typedef struct _LttvProcessState {
   LttvProcessType type;        /* kernel thread or user space ? */
   guint target_pid; /* target PID of the current event. */
   guint free_events; /* 0 : none, 1 : free or exit dead, 2 : should delete */
+  GHashTable *fds; /* hash table of int (file descriptor) -> GQuark (file name) */
 } LttvProcessState;
 
 #define ANY_CPU 0 /* For clarity sake : a call to lttv_state_find_process for
@@ -355,6 +361,18 @@ typedef struct _LttvBdevState {
   GArray *mode_stack;
 } LttvBdevState;
 
+typedef struct _LttvNameTables {
+  GQuark *syscall_names;
+  guint nb_syscalls;
+  GQuark *trap_names;
+  guint nb_traps;
+  GQuark *irq_names;
+  guint nb_irqs;
+  GQuark *soft_irq_names;
+  guint nb_soft_irqs;
+  GHashTable *kprobe_hash;
+} LttvNameTables;
+
 struct _LttvTraceState {
   LttvTraceContext parent;
 
@@ -365,14 +383,7 @@ struct _LttvTraceState {
   guint nb_event, save_interval;
   /* Block/char devices, locks, memory pages... */
   GQuark *eventtype_names;
-  GQuark *syscall_names;
-  guint  nb_syscalls;
-  GQuark *trap_names;
-  guint  nb_traps;
-  guint  nb_irqs;
-  guint  nb_soft_irqs;
-  GQuark *irq_names;
-  GQuark *soft_irq_names;
+  LttvNameTables *name_tables;
   LttTime *max_time_state_recomputed_in_seek;
   GHashTable *kprobe_hash;
 
This page took 0.023333 seconds and 4 git commands to generate.