resourceview: cpu: add softirq state
[lttv.git] / ltt / branches / poly / lttv / modules / gui / controlflow / eventhooks.c
index 7e2cc1d062479abb7bfd94b07a5cbf3bbd884e88..cde8be6baab95c0352e550eb0162e6bf28490b00 100644 (file)
@@ -61,7 +61,6 @@
 
 #include <ltt/event.h>
 #include <ltt/time.h>
-#include <ltt/type.h>
 #include <ltt/trace.h>
 
 #include <lttv/lttv.h>
@@ -79,6 +78,8 @@
 
 
 #define MAX_PATH_LEN 256
+#define STATE_LINE_WIDTH 4
+#define COLLISION_POSITION(height) (((height - STATE_LINE_WIDTH)/2) -3)
 
 extern GSList *g_legend_list;
 
@@ -120,6 +121,7 @@ static void request_background_data(ControlFlowData *control_flow_data)
   gint num_traces = lttv_traceset_number(tsc->ts);
   gint i;
   LttvTrace *trace;
+  LttvTraceState *tstate;
 
   LttvHooks *background_ready_hook = 
     lttv_hooks_new();
@@ -129,8 +131,10 @@ static void request_background_data(ControlFlowData *control_flow_data)
   
   for(i=0;i<num_traces;i++) {
     trace = lttv_traceset_get(tsc->ts, i);
+    tstate = LTTV_TRACE_STATE(tsc->traces[i]);
 
-    if(lttvwindowtraces_get_ready(g_quark_from_string("state"),trace)==FALSE) {
+    if(lttvwindowtraces_get_ready(g_quark_from_string("state"),trace)==FALSE
+        && !tstate->has_precomputed_states) {
 
       if(lttvwindowtraces_get_in_progress(g_quark_from_string("state"),
                                           trace) == FALSE) {
@@ -157,7 +161,7 @@ static void request_background_data(ControlFlowData *control_flow_data)
         control_flow_data->background_info_waiting++;
       }
     } else {
-      /* Data ready. Be its nature, this viewer doesn't need to have
+      /* Data ready. By its nature, this viewer doesn't need to have
        * its data ready hook called there, because a background
        * request is always linked with a redraw.
        */
@@ -213,48 +217,6 @@ h_guicontrolflow(LttvPlugin *plugin)
   
 }
 
-void legend_destructor(GtkWindow *legend)
-{
-  g_legend_list = g_slist_remove(g_legend_list, legend);
-}
-
-/* Create a popup legend */
-GtkWidget *
-h_legend(LttvPlugin *plugin)
-{
-  LttvPluginTab *ptab = LTTV_PLUGIN_TAB(plugin);
-  Tab *tab = ptab->tab;
-  g_info("h_legend, %p", tab);
-
-  GtkWindow *legend = GTK_WINDOW(gtk_window_new(GTK_WINDOW_TOPLEVEL));
-  g_legend_list = g_slist_append(
-      g_legend_list,
-      legend);
-  g_object_set_data_full(
-      G_OBJECT(legend),
-      "legend",
-      legend,
-      (GDestroyNotify)legend_destructor);
-  
-  gtk_window_set_title(legend, "Control Flow View Legend");
-
-  GtkWidget *pixmap = create_pixmap(GTK_WIDGET(legend), "lttv-color-list.png");
-  
- // GtkImage *image = GTK_IMAGE(gtk_image_new_from_pixmap(
- //                               GDK_PIXMAP(pixmap), NULL));
-  
-  gtk_container_add(GTK_CONTAINER(legend), GTK_WIDGET(pixmap));
-
-  gtk_widget_show(GTK_WIDGET(pixmap));
-  gtk_widget_show(GTK_WIDGET(legend));
-  
-
-  return NULL; /* This is a popup window */
-}
-
-
 int event_selected_hook(void *hook_data, void *call_data)
 {
   ControlFlowData *control_flow_data = (ControlFlowData*) hook_data;
@@ -269,7 +231,7 @@ int event_selected_hook(void *hook_data, void *call_data)
 static inline PropertiesLine prepare_s_e_line(LttvProcessState *process)
 {
   PropertiesLine prop_line;
-  prop_line.line_width = 2;
+  prop_line.line_width = STATE_LINE_WIDTH;
   prop_line.style = GDK_LINE_SOLID;
   prop_line.y = MIDDLE;
   //GdkColormap *colormap = gdk_colormap_get_system();
@@ -334,8 +296,8 @@ static inline PropertiesLine prepare_s_e_line(LttvProcessState *process)
 
 int before_schedchange_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -345,8 +307,10 @@ int before_schedchange_hook(void *hook_data, void *call_data)
 
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
+  gint target_pid_saved = tfc->target_pid;
 
   LttTime evtime = ltt_event_time(e);
+  LttvFilter *filter = control_flow_data->filter;
 
   /* we are in a schedchange, before the state update. We must draw the
    * items corresponding to the state before it changes : now is the right
@@ -356,11 +320,14 @@ int before_schedchange_hook(void *hook_data, void *call_data)
   guint pid_out;
   guint pid_in;
   {
-    pid_out = ltt_event_get_long_unsigned(e, thf->f1);
-    pid_in = ltt_event_get_long_unsigned(e, thf->f2);
+    pid_out = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 0));
+    pid_in = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 1));
   }
   
-  { 
+  tfc->target_pid = pid_out;
+  if(!filter || !filter->head ||
+    lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL)) { 
     /* For the pid_out */
     /* First, check if the current process is in the state computation
      * process list. If it is there, that means we must add it right now and
@@ -368,6 +335,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
      * present, it's a new process and it was not present : it will
      * be added after the state update.  */
     guint cpu = tfs->cpu;
+    guint trace_num = ts->parent.index;
     LttvProcessState *process = ts->running_process[cpu];
     /* unknown state, bad current pid */
     if(process->pid != pid_out)
@@ -388,7 +356,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
               pid_out,
               process->cpu,
               &birth,
-              tfc->t_context->index);
+              trace_num);
       if(hashed_process_data == NULL)
       {
         g_assert(pid_out == 0 || pid_out != process->ppid);
@@ -402,7 +370,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
             process->cpu,
             process->ppid,
             &birth,
-            tfc->t_context->index,
+            trace_num,
             process->name,
             process->brand,
             &pl_height,
@@ -429,7 +397,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
           if(ltt_time_compare(evtime, time_window.start_time) == -1
                 || ltt_time_compare(evtime, time_window.end_time) == 1)
-                    return;
+                    return FALSE;
 #endif //EXTRA_CHECK
           Drawing_t *drawing = control_flow_data->drawing;
           guint width = drawing->width;
@@ -445,7 +413,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
           gdk_draw_point(hashed_process_data->pixmap,
                          drawing->gc,
                          x,
-                         (hashed_process_data->height/2)-3);
+                         COLLISION_POSITION(hashed_process_data->height));
           hashed_process_data->x.middle_marked = TRUE;
         }
       } else {
@@ -454,7 +422,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
         if(ltt_time_compare(evtime, time_window.start_time) == -1
               || ltt_time_compare(evtime, time_window.end_time) == 1)
-                  return;
+                  return FALSE;
 #endif //EXTRA_CHECK
         Drawing_t *drawing = control_flow_data->drawing;
         guint width = drawing->width;
@@ -476,7 +444,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
             gdk_draw_point(hashed_process_data->pixmap,
                            drawing->gc,
                            x,
-                           (hashed_process_data->height/2)-3);
+                           COLLISION_POSITION(hashed_process_data->height));
             hashed_process_data->x.middle_marked = TRUE;
           }
           /* jump */
@@ -521,7 +489,10 @@ int before_schedchange_hook(void *hook_data, void *call_data)
     }
   }
 
-  {
+  tfc->target_pid = pid_in;
+  if(!filter || !filter->head ||
+    lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL)) { 
     /* For the pid_in */
     /* First, check if the current process is in the state computation
      * process list. If it is there, that means we must add it right now and
@@ -531,6 +502,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
     LttvProcessState *process;
     process = lttv_state_find_process(ts,
         tfs->cpu, pid_in);
+    guint trace_num = ts->parent.index;
     
     if(process != NULL) {
       /* Well, the process existed : we must get it in the process hash
@@ -546,7 +518,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
               pid_in,
               tfs->cpu,
               &birth,
-              tfc->t_context->index);
+              trace_num);
       if(hashed_process_data == NULL)
       {
         g_assert(pid_in == 0 || pid_in != process->ppid);
@@ -560,7 +532,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
             tfs->cpu,
             process->ppid,
             &birth,
-            tfc->t_context->index,
+            trace_num,
             process->name,
             process->brand,
             &pl_height,
@@ -589,7 +561,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
           if(ltt_time_compare(evtime, time_window.start_time) == -1
                 || ltt_time_compare(evtime, time_window.end_time) == 1)
-                    return;
+                    return FALSE;
 #endif //EXTRA_CHECK
           Drawing_t *drawing = control_flow_data->drawing;
           guint width = drawing->width;
@@ -605,7 +577,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
           gdk_draw_point(hashed_process_data->pixmap,
                          drawing->gc,
                          x,
-                         (hashed_process_data->height/2)-3);
+                         COLLISION_POSITION(hashed_process_data->height));
           hashed_process_data->x.middle_marked = TRUE;
         }
       } else {
@@ -614,7 +586,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
         if(ltt_time_compare(evtime, time_window.start_time) == -1
               || ltt_time_compare(evtime, time_window.end_time) == 1)
-                  return;
+                  return FALSE;
 #endif //EXTRA_CHECK
         Drawing_t *drawing = control_flow_data->drawing;
         guint width = drawing->width;
@@ -637,7 +609,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
             gdk_draw_point(hashed_process_data->pixmap,
                            drawing->gc,
                            x,
-                           (hashed_process_data->height/2)-3);
+                           COLLISION_POSITION(hashed_process_data->height));
             hashed_process_data->x.middle_marked = TRUE;
           }
           /* jump */
@@ -683,6 +655,7 @@ int before_schedchange_hook(void *hook_data, void *call_data)
     } else
       g_warning("Cannot find pin_in in schedchange %u", pid_in);
   }
+  tfc->target_pid = target_pid_saved;
   return 0;
 
 
@@ -722,8 +695,8 @@ int before_schedchange_hook(void *hook_data, void *call_data)
  */
 int after_schedchange_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -735,6 +708,12 @@ int after_schedchange_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   /* Add process to process list (if not present) */
@@ -748,8 +727,8 @@ int after_schedchange_hook(void *hook_data, void *call_data)
   guint pid_in;
   {
     guint pid_out;
-    pid_out = ltt_event_get_long_unsigned(e, thf->f1);
-    pid_in = ltt_event_get_long_unsigned(e, thf->f2);
+    pid_out = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 0));
+    pid_in = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 1));
   }
 
 
@@ -757,6 +736,7 @@ int after_schedchange_hook(void *hook_data, void *call_data)
   //process_in = lttv_state_find_process(ts, ANY_CPU, pid_in);
   //process_in = tfs->process;
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   process_in = ts->running_process[cpu];
   /* It should exist, because we are after the state update. */
 #ifdef EXTRA_CHECK
@@ -768,7 +748,7 @@ int after_schedchange_hook(void *hook_data, void *call_data)
           pid_in,
           process_in->cpu,
           &birth,
-          tfc->t_context->index);
+          trace_num);
   if(hashed_process_data_in == NULL)
   {
     g_assert(pid_in == 0 || pid_in != process_in->ppid);
@@ -782,7 +762,7 @@ int after_schedchange_hook(void *hook_data, void *call_data)
         process_in->cpu,
         process_in->ppid,
         &birth,
-        tfc->t_context->index,
+        trace_num,
         process_in->name,
         process_in->brand,
         &pl_height,
@@ -794,7 +774,7 @@ int after_schedchange_hook(void *hook_data, void *call_data)
         gtk_widget_queue_draw(drawing->drawing_area);
   }
   /* Set the current process */
-  process_list->current_hash_data[process_in->cpu] =
+  process_list->current_hash_data[trace_num][process_in->cpu] =
                                              hashed_process_data_in;
 
   if(ltt_time_compare(hashed_process_data_in->next_good_time,
@@ -806,7 +786,7 @@ int after_schedchange_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
     if(ltt_time_compare(evtime, time_window.start_time) == -1
         || ltt_time_compare(evtime, time_window.end_time) == 1)
-            return;
+            return FALSE;
 #endif //EXTRA_CHECK
     Drawing_t *drawing = control_flow_data->drawing;
     guint width = drawing->width;
@@ -850,8 +830,8 @@ int after_schedchange_hook(void *hook_data, void *call_data)
 
 int before_execmode_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -863,6 +843,12 @@ int before_execmode_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   /* we are in a execmode, before the state update. We must draw the
@@ -872,6 +858,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
   /* For the pid */
   //LttvProcessState *process = tfs->process;
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   LttvProcessState *process = ts->running_process[cpu];
   g_assert(process != NULL);
 
@@ -886,14 +873,14 @@ int before_execmode_hook(void *hook_data, void *call_data)
   ProcessList *process_list = control_flow_data->process_list;
   LttTime birth = process->creation_time;
  
-  if(likely(process_list->current_hash_data[cpu] != NULL)) {
-    hashed_process_data = process_list->current_hash_data[cpu];
+  if(likely(process_list->current_hash_data[trace_num][cpu] != NULL)) {
+    hashed_process_data = process_list->current_hash_data[trace_num][cpu];
   } else {
     hashed_process_data = processlist_get_process_data(process_list,
             pid,
             process->cpu,
             &birth,
-            tfc->t_context->index);
+            trace_num);
     if(unlikely(hashed_process_data == NULL))
     {
       g_assert(pid == 0 || pid != process->ppid);
@@ -907,7 +894,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
           process->cpu,
           process->ppid,
           &birth,
-          tfc->t_context->index,
+          trace_num,
           process->name,
           process->brand,
           &pl_height,
@@ -919,7 +906,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
         gtk_widget_queue_draw(drawing->drawing_area);
     }
     /* Set the current process */
-    process_list->current_hash_data[process->cpu] =
+    process_list->current_hash_data[trace_num][process->cpu] =
                                                hashed_process_data;
   }
 
@@ -937,7 +924,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
       if(ltt_time_compare(evtime, time_window.start_time) == -1
             || ltt_time_compare(evtime, time_window.end_time) == 1)
-                return;
+                return FALSE;
 #endif //EXTRA_CHECK
       Drawing_t *drawing = control_flow_data->drawing;
       guint width = drawing->width;
@@ -953,7 +940,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
       gdk_draw_point(hashed_process_data->pixmap,
                      drawing->gc,
                      x,
-                     (hashed_process_data->height/2)-3);
+                     COLLISION_POSITION(hashed_process_data->height));
       hashed_process_data->x.middle_marked = TRUE;
     }
   } else {
@@ -963,7 +950,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
     if(ltt_time_compare(evtime, time_window.start_time) == -1
           || ltt_time_compare(evtime, time_window.end_time) == 1)
-              return;
+              return FALSE;
 #endif //EXTRA_CHECK
     Drawing_t *drawing = control_flow_data->drawing;
     guint width = drawing->width;
@@ -986,7 +973,7 @@ int before_execmode_hook(void *hook_data, void *call_data)
         gdk_draw_point(hashed_process_data->pixmap,
                        drawing->gc,
                        x,
-                       (hashed_process_data->height/2)-3);
+                       COLLISION_POSITION(hashed_process_data->height));
         hashed_process_data->x.middle_marked = TRUE;
       }
       /* jump */
@@ -1046,8 +1033,8 @@ int before_execmode_hook(void *hook_data, void *call_data)
 
 int before_process_exit_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
 
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
@@ -1060,11 +1047,18 @@ int before_process_exit_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   /* Add process to process list (if not present) */
   //LttvProcessState *process = tfs->process;
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   LttvProcessState *process = ts->running_process[cpu];
   guint pid = process->pid;
   LttTime birth;
@@ -1077,14 +1071,14 @@ int before_process_exit_hook(void *hook_data, void *call_data)
 
   birth = process->creation_time;
 
-  if(likely(process_list->current_hash_data[cpu] != NULL)) {
-    hashed_process_data = process_list->current_hash_data[cpu];
+  if(likely(process_list->current_hash_data[trace_num][cpu] != NULL)) {
+    hashed_process_data = process_list->current_hash_data[trace_num][cpu];
   } else {
     hashed_process_data = processlist_get_process_data(process_list,
           pid,
           process->cpu,
           &birth,
-          tfc->t_context->index);
+          trace_num);
     if(unlikely(hashed_process_data == NULL))
     {
       g_assert(pid == 0 || pid != process->ppid);
@@ -1098,7 +1092,7 @@ int before_process_exit_hook(void *hook_data, void *call_data)
           process->cpu,
           process->ppid,
           &birth,
-          tfc->t_context->index,
+          trace_num,
           process->name,
           process->brand,
           &pl_height,
@@ -1125,7 +1119,7 @@ int before_process_exit_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
       if(ltt_time_compare(evtime, time_window.start_time) == -1
             || ltt_time_compare(evtime, time_window.end_time) == 1)
-                return;
+                return FALSE;
 #endif //EXTRA_CHECK
       Drawing_t *drawing = control_flow_data->drawing;
       guint width = drawing->width;
@@ -1141,7 +1135,7 @@ int before_process_exit_hook(void *hook_data, void *call_data)
       gdk_draw_point(hashed_process_data->pixmap,
                      drawing->gc,
                      x,
-                     (hashed_process_data->height/2)-3);
+                     COLLISION_POSITION(hashed_process_data->height));
       hashed_process_data->x.middle_marked = TRUE;
     }
   } else {
@@ -1151,7 +1145,7 @@ int before_process_exit_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
     if(ltt_time_compare(evtime, time_window.start_time) == -1
           || ltt_time_compare(evtime, time_window.end_time) == 1)
-              return;
+              return FALSE;
 #endif //EXTRA_CHECK
     Drawing_t *drawing = control_flow_data->drawing;
     guint width = drawing->width;
@@ -1174,7 +1168,7 @@ int before_process_exit_hook(void *hook_data, void *call_data)
         gdk_draw_point(hashed_process_data->pixmap,
                        drawing->gc,
                        x,
-                       (hashed_process_data->height/2)-3);
+                       COLLISION_POSITION(hashed_process_data->height));
         hashed_process_data->x.middle_marked = TRUE;
       }
       /* jump */
@@ -1237,8 +1231,8 @@ int before_process_exit_hook(void *hook_data, void *call_data)
 
 int before_process_release_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
 
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
@@ -1251,12 +1245,19 @@ int before_process_release_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
+  guint trace_num = ts->parent.index;
 
   guint pid;
   {
-    pid = ltt_event_get_long_unsigned(e, thf->f1);
+    pid = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 0));
   }
 
   /* Add process to process list (if not present) */
@@ -1280,31 +1281,13 @@ int before_process_release_hook(void *hook_data, void *call_data)
           pid,
           process->cpu,
           &birth,
-          tfc->t_context->index);
+          trace_num);
     if(unlikely(hashed_process_data == NULL))
-    {
-      g_assert(pid == 0 || pid != process->ppid);
-      /* Process not present */
-      Drawing_t *drawing = control_flow_data->drawing;
-      ProcessInfo *process_info;
-      processlist_add(process_list,
-          drawing,
-          pid,
-          process->tgid,
-          process->cpu,
-          process->ppid,
-          &birth,
-          tfc->t_context->index,
-          process->name,
-          process->brand,
-          &pl_height,
-          &process_info,
-          &hashed_process_data);
-      gtk_widget_set_size_request(drawing->drawing_area,
-                                  -1,
-                                  pl_height);
-      gtk_widget_queue_draw(drawing->drawing_area);
-    }
+      /*
+       * Process already been scheduled out EXIT_DEAD, not in the process list
+       * anymore. Just return.
+       */
+      return FALSE;
 
     /* Now, the process is in the state hash and our own process hash.
      * We definitely can draw the items related to the ending state.
@@ -1320,7 +1303,7 @@ int before_process_release_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
         if(ltt_time_compare(evtime, time_window.start_time) == -1
               || ltt_time_compare(evtime, time_window.end_time) == 1)
-                  return;
+                  return FALSE;
 #endif //EXTRA_CHECK
         Drawing_t *drawing = control_flow_data->drawing;
         guint width = drawing->width;
@@ -1336,7 +1319,7 @@ int before_process_release_hook(void *hook_data, void *call_data)
         gdk_draw_point(hashed_process_data->pixmap,
                        drawing->gc,
                        x,
-                       (hashed_process_data->height/2)-3);
+                       COLLISION_POSITION(hashed_process_data->height));
         hashed_process_data->x.middle_marked = TRUE;
       }
     } else {
@@ -1346,7 +1329,7 @@ int before_process_release_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
       if(ltt_time_compare(evtime, time_window.start_time) == -1
             || ltt_time_compare(evtime, time_window.end_time) == 1)
-                return;
+                return FALSE;
 #endif //EXTRA_CHECK
       Drawing_t *drawing = control_flow_data->drawing;
       guint width = drawing->width;
@@ -1369,7 +1352,7 @@ int before_process_release_hook(void *hook_data, void *call_data)
           gdk_draw_point(hashed_process_data->pixmap,
                          drawing->gc,
                          x,
-                         (hashed_process_data->height/2)-3);
+                         COLLISION_POSITION(hashed_process_data->height));
           hashed_process_data->x.middle_marked = TRUE;
         }
         /* jump */
@@ -1433,8 +1416,8 @@ int before_process_release_hook(void *hook_data, void *call_data)
  */
 int after_process_fork_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -1446,11 +1429,17 @@ int after_process_fork_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   guint child_pid;
   {
-    child_pid = ltt_event_get_long_unsigned(e, thf->f2);
+    child_pid = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 1));
   }
 
   /* Add process to process list (if not present) */
@@ -1467,6 +1456,7 @@ int after_process_fork_hook(void *hook_data, void *call_data)
   g_assert(process_child != NULL);
 
   birth = process_child->creation_time;
+  guint trace_num = ts->parent.index;
 
   /* Cannot use current process, because this action is done by the parent
    * on its child. */
@@ -1474,7 +1464,7 @@ int after_process_fork_hook(void *hook_data, void *call_data)
           child_pid,
           process_child->cpu,
           &birth,
-          tfc->t_context->index);
+          trace_num);
   if(likely(hashed_process_data_child == NULL))
   {
     g_assert(child_pid == 0 || child_pid != process_child->ppid);
@@ -1488,7 +1478,7 @@ int after_process_fork_hook(void *hook_data, void *call_data)
         process_child->cpu,
         process_child->ppid,
         &birth,
-        tfc->t_context->index,
+        trace_num,
         process_child->name,
         process_child->brand,
         &pl_height,
@@ -1515,7 +1505,7 @@ int after_process_fork_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
     if(ltt_time_compare(evtime, time_window.start_time) == -1
           || ltt_time_compare(evtime, time_window.end_time) == 1)
-              return;
+              return FALSE;
 #endif //EXTRA_CHECK
     Drawing_t *drawing = control_flow_data->drawing;
     guint width = drawing->width;
@@ -1542,7 +1532,7 @@ int after_process_fork_hook(void *hook_data, void *call_data)
       hashed_process_data_child->x.under_marked = FALSE;
     }
   }
-  return 0;
+  return FALSE;
 }
 
 
@@ -1560,8 +1550,8 @@ int after_process_fork_hook(void *hook_data, void *call_data)
  */
 int after_process_exit_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -1573,11 +1563,18 @@ int after_process_exit_hook(void *hook_data, void *call_data)
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   /* Add process to process list (if not present) */
   //LttvProcessState *process = tfs->process;
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   LttvProcessState *process = ts->running_process[cpu];
 
   /* It should exist, because we are after the state update. */
@@ -1592,14 +1589,14 @@ int after_process_exit_hook(void *hook_data, void *call_data)
 
   birth = process->creation_time;
 
-  if(likely(process_list->current_hash_data[cpu] != NULL) ){
-    hashed_process_data = process_list->current_hash_data[cpu];
+  if(likely(process_list->current_hash_data[trace_num][cpu] != NULL) ){
+    hashed_process_data = process_list->current_hash_data[trace_num][cpu];
   } else {
     hashed_process_data = processlist_get_process_data(process_list,
             pid,
             process->cpu,
             &birth,
-            tfc->t_context->index);
+            trace_num);
     if(unlikely(hashed_process_data == NULL))
     {
       g_assert(pid == 0 || pid != process->ppid);
@@ -1613,7 +1610,7 @@ int after_process_exit_hook(void *hook_data, void *call_data)
           process->cpu,
           process->ppid,
           &birth,
-          tfc->t_context->index,
+          trace_num,
           process->name,
           process->brand,
           &pl_height,
@@ -1626,7 +1623,7 @@ int after_process_exit_hook(void *hook_data, void *call_data)
     }
 
     /* Set the current process */
-    process_list->current_hash_data[process->cpu] =
+    process_list->current_hash_data[trace_num][process->cpu] =
                                              hashed_process_data;
   }
 
@@ -1639,7 +1636,7 @@ int after_process_exit_hook(void *hook_data, void *call_data)
 #ifdef EXTRA_CHECK
     if(ltt_time_compare(evtime, time_window.start_time) == -1
           || ltt_time_compare(evtime, time_window.end_time) == 1)
-              return;
+              return FALSE;
 #endif //EXTRA_CHECK
     Drawing_t *drawing = control_flow_data->drawing;
     guint width = drawing->width;
@@ -1656,15 +1653,15 @@ int after_process_exit_hook(void *hook_data, void *call_data)
     }
   }
 
-  return 0;
+  return FALSE;
 }
 
 
 /* Get the filename of the process to print */
 int after_fs_exec_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -1673,7 +1670,17 @@ int after_fs_exec_hook(void *hook_data, void *call_data)
 
   LttvTraceState *ts = (LttvTraceState *)tfc->t_context;
 
+  LttEvent *e;
+  e = ltt_tracefile_get_event(tfc->tf);
+
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   LttvProcessState *process = ts->running_process[cpu];
   g_assert(process != NULL);
 
@@ -1688,14 +1695,14 @@ int after_fs_exec_hook(void *hook_data, void *call_data)
   ProcessList *process_list = control_flow_data->process_list;
   LttTime birth = process->creation_time;
  
-  if(likely(process_list->current_hash_data[cpu] != NULL)) {
-    hashed_process_data = process_list->current_hash_data[cpu];
+  if(likely(process_list->current_hash_data[trace_num][cpu] != NULL)) {
+    hashed_process_data = process_list->current_hash_data[trace_num][cpu];
   } else {
     hashed_process_data = processlist_get_process_data(process_list,
             pid,
             process->cpu,
             &birth,
-            tfc->t_context->index);
+            trace_num);
     if(unlikely(hashed_process_data == NULL))
     {
       g_assert(pid == 0 || pid != process->ppid);
@@ -1709,7 +1716,7 @@ int after_fs_exec_hook(void *hook_data, void *call_data)
           process->cpu,
           process->ppid,
           &birth,
-          tfc->t_context->index,
+          trace_num,
           process->name,
           process->brand,
           &pl_height,
@@ -1721,7 +1728,7 @@ int after_fs_exec_hook(void *hook_data, void *call_data)
         gtk_widget_queue_draw(drawing->drawing_area);
     }
     /* Set the current process */
-    process_list->current_hash_data[process->cpu] =
+    process_list->current_hash_data[trace_num][process->cpu] =
                                                hashed_process_data;
   }
 
@@ -1734,8 +1741,8 @@ int after_fs_exec_hook(void *hook_data, void *call_data)
 /* Get the filename of the process to print */
 int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -1744,7 +1751,17 @@ int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
 
   LttvTraceState *ts = (LttvTraceState *)tfc->t_context;
 
+  LttEvent *e;
+  e = ltt_tracefile_get_event(tfc->tf);
+
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   guint cpu = tfs->cpu;
+  guint trace_num = ts->parent.index;
   LttvProcessState *process = ts->running_process[cpu];
   g_assert(process != NULL);
 
@@ -1759,14 +1776,14 @@ int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
   ProcessList *process_list = control_flow_data->process_list;
   LttTime birth = process->creation_time;
  
-  if(likely(process_list->current_hash_data[cpu] != NULL)) {
-    hashed_process_data = process_list->current_hash_data[cpu];
+  if(likely(process_list->current_hash_data[trace_num][cpu] != NULL)) {
+    hashed_process_data = process_list->current_hash_data[trace_num][cpu];
   } else {
     hashed_process_data = processlist_get_process_data(process_list,
             pid,
             process->cpu,
             &birth,
-            tfc->t_context->index);
+            trace_num);
     if(unlikely(hashed_process_data == NULL))
     {
       g_assert(pid == 0 || pid != process->ppid);
@@ -1780,7 +1797,7 @@ int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
           process->cpu,
           process->ppid,
           &birth,
-          tfc->t_context->index,
+          trace_num,
           process->name,
          process->brand,
           &pl_height,
@@ -1792,7 +1809,7 @@ int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
         gtk_widget_queue_draw(drawing->drawing_area);
     }
     /* Set the current process */
-    process_list->current_hash_data[process->cpu] =
+    process_list->current_hash_data[trace_num][process->cpu] =
                                                hashed_process_data;
   }
 
@@ -1816,8 +1833,8 @@ int after_user_generic_thread_brand_hook(void *hook_data, void *call_data)
  */
 int after_event_enum_process_hook(void *hook_data, void *call_data)
 {
-  LttvTraceHookByFacility *thf = (LttvTraceHookByFacility*)hook_data;
-  EventsRequest *events_request = (EventsRequest*)thf->hook_data;
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
   ControlFlowData *control_flow_data = events_request->viewer_data;
 
   LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
@@ -1826,9 +1843,17 @@ int after_event_enum_process_hook(void *hook_data, void *call_data)
 
   LttvTraceState *ts = (LttvTraceState *)tfc->t_context;
 
+  guint first_cpu, nb_cpus, cpu;
+
   LttEvent *e;
   e = ltt_tracefile_get_event(tfc->tf);
 
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
   LttTime evtime = ltt_event_time(e);
 
   /* Add process to process list (if not present) */
@@ -1838,62 +1863,73 @@ int after_event_enum_process_hook(void *hook_data, void *call_data)
   HashedProcessData *hashed_process_data_in = NULL;
 
   ProcessList *process_list = control_flow_data->process_list;
+  guint trace_num = ts->parent.index;
   
   guint pid_in;
   {
-    pid_in = ltt_event_get_long_unsigned(e, thf->f1);
+    pid_in = ltt_event_get_long_unsigned(e, lttv_trace_get_hook_field(th, 0));
+  }
+  
+  if(pid_in == 0) {
+    first_cpu = 0;
+    nb_cpus = ltt_trace_get_num_cpu(ts->parent.t);
+  } else {
+    first_cpu = ANY_CPU;
+    nb_cpus = ANY_CPU+1;
   }
 
-
-  /* Find process pid_in in the list... */
-  process_in = lttv_state_find_process(ts, ANY_CPU, pid_in);
-  //process_in = tfs->process;
-  //guint cpu = tfs->cpu;
-  //process_in = ts->running_process[cpu];
-  /* It should exist, because we are after the state update. */
-#ifdef EXTRA_CHECK
-  //g_assert(process_in != NULL);
-#endif //EXTRA_CHECK
-  birth = process_in->creation_time;
-
-  hashed_process_data_in = processlist_get_process_data(process_list,
+  for(cpu = first_cpu; cpu < nb_cpus; cpu++) {
+    /* Find process pid_in in the list... */
+    process_in = lttv_state_find_process(ts, cpu, pid_in);
+    //process_in = tfs->process;
+    //guint cpu = tfs->cpu;
+    //guint trace_num = ts->parent.index;
+    //process_in = ts->running_process[cpu];
+    /* It should exist, because we are after the state update. */
+  #ifdef EXTRA_CHECK
+    //g_assert(process_in != NULL);
+  #endif //EXTRA_CHECK
+    birth = process_in->creation_time;
+
+    hashed_process_data_in = processlist_get_process_data(process_list,
+            pid_in,
+            process_in->cpu,
+            &birth,
+            trace_num);
+    if(hashed_process_data_in == NULL)
+    {
+      if(pid_in != 0 && pid_in == process_in->ppid)
+        g_critical("TEST %u , %u", pid_in, process_in->ppid);
+      g_assert(pid_in == 0 || pid_in != process_in->ppid);
+      ProcessInfo *process_info;
+      Drawing_t *drawing = control_flow_data->drawing;
+      /* Process not present */
+      processlist_add(process_list,
+          drawing,
           pid_in,
+          process_in->tgid,
           process_in->cpu,
+          process_in->ppid,
           &birth,
-          tfc->t_context->index);
-  if(hashed_process_data_in == NULL)
-  {
-               if(pid_in != 0 && pid_in == process_in->ppid)
-                       g_critical("TEST %u , %u", pid_in, process_in->ppid);
-    g_assert(pid_in == 0 || pid_in != process_in->ppid);
-    ProcessInfo *process_info;
-    Drawing_t *drawing = control_flow_data->drawing;
-    /* Process not present */
-    processlist_add(process_list,
-        drawing,
-        pid_in,
-        process_in->tgid,
-        process_in->cpu,
-        process_in->ppid,
-        &birth,
-        tfc->t_context->index,
-        process_in->name,
-        process_in->brand,
-        &pl_height,
-        &process_info,
-        &hashed_process_data_in);
-        gtk_widget_set_size_request(drawing->drawing_area,
-                                    -1,
-                                    pl_height);
-        gtk_widget_queue_draw(drawing->drawing_area);
-  } else {
-          processlist_set_name(process_list, process_in->name,
-                               hashed_process_data_in);
-          processlist_set_ppid(process_list, process_in->ppid,
-                               hashed_process_data_in);
-          processlist_set_tgid(process_list, process_in->tgid,
-                               hashed_process_data_in);
-       }
+          trace_num,
+          process_in->name,
+          process_in->brand,
+          &pl_height,
+          &process_info,
+          &hashed_process_data_in);
+          gtk_widget_set_size_request(drawing->drawing_area,
+                                      -1,
+                                      pl_height);
+          gtk_widget_queue_draw(drawing->drawing_area);
+    } else {
+      processlist_set_name(process_list, process_in->name,
+                           hashed_process_data_in);
+      processlist_set_ppid(process_list, process_in->ppid,
+                           hashed_process_data_in);
+      processlist_set_tgid(process_list, process_in->tgid,
+                           hashed_process_data_in);
+    }
+  }
   return 0;
 }
 
@@ -2310,6 +2346,8 @@ void draw_closure(gpointer key, gpointer value, gpointer user_data)
 
   LttTime evtime = closure_data->end_time;
 
+  gboolean dodraw = TRUE;
+
   { 
     /* For the process */
     /* First, check if the current process is in the state computation
@@ -2348,6 +2386,12 @@ void draw_closure(gpointer key, gpointer value, gpointer user_data)
 
     if(unlikely(process != NULL)) {
       
+       LttvFilter *filter = control_flow_data->filter;
+       if(filter != NULL && filter->head != NULL)
+         if(!lttv_filter_tree_parse(filter->head,NULL,NULL,
+             tc->t,NULL,process,tc))
+           dodraw = FALSE;
+
       /* Only draw for processes that are currently in the trace states */
 
       ProcessList *process_list = control_flow_data->process_list;
@@ -2429,8 +2473,10 @@ void draw_closure(gpointer key, gpointer value, gpointer user_data)
         } else {
           draw_context.drawinfo.start.x = hashed_process_data->x.middle;
           /* Draw the line */
-          PropertiesLine prop_line = prepare_s_e_line(process);
-          draw_line((void*)&prop_line, (void*)&draw_context);
+          if(dodraw) {
+                  PropertiesLine prop_line = prepare_s_e_line(process);
+                  draw_line((void*)&prop_line, (void*)&draw_context);
+          }
 
            /* become the last x position */
           if(likely(x != hashed_process_data->x.middle)) {
@@ -2535,10 +2581,19 @@ int after_chunk(void *hook_data, void *call_data)
   LttTime end_time;
   
   ProcessList *process_list = control_flow_data->process_list;
+  guint i;
+  LttvTraceset *traceset = tsc->ts;
+  guint nb_trace = lttv_traceset_number(traceset);
+
+  /* Only execute when called for the first trace's events request */
+  if(!process_list->current_hash_data) return;
 
+  for(i = 0 ; i < nb_trace ; i++) {
+    g_free(process_list->current_hash_data[i]);
+  }
   g_free(process_list->current_hash_data);
   process_list->current_hash_data = NULL;
-  
+
   if(tfc != NULL)
     end_time = LTT_TIME_MIN(tfc->timestamp, events_request->end_time);
   else /* end of traceset, or position now out of request : end */
@@ -2578,3 +2633,70 @@ int after_chunk(void *hook_data, void *call_data)
   return 0;
 }
 
+/* after_statedump_end
+ * 
+ * @param hook_data ControlFlowData structure of the viewer. 
+ * @param call_data Event context.
+ *
+ * This function adds items to be drawn in a queue for each process.
+ * 
+ */
+int before_statedump_end(void *hook_data, void *call_data)
+{
+  LttvTraceHook *th = (LttvTraceHook*)hook_data;
+  EventsRequest *events_request = (EventsRequest*)th->hook_data;
+  ControlFlowData *control_flow_data = events_request->viewer_data;
+
+  LttvTracefileContext *tfc = (LttvTracefileContext *)call_data;
+
+  LttvTracefileState *tfs = (LttvTracefileState *)call_data;
+
+  LttvTraceState *ts = (LttvTraceState *)tfc->t_context;
+
+  LttvTracesetState *tss = (LttvTracesetState*)tfc->t_context->ts_context;
+  ProcessList *process_list = control_flow_data->process_list;
+
+  LttEvent *e;
+  e = ltt_tracefile_get_event(tfc->tf);
+
+  LttvFilter *filter = control_flow_data->filter;
+  if(filter != NULL && filter->head != NULL)
+    if(!lttv_filter_tree_parse(filter->head,e,tfc->tf,
+          tfc->t_context->t,tfc,NULL,NULL))
+      return FALSE;
+
+  LttTime evtime = ltt_event_time(e);
+
+  ClosureData closure_data;
+  closure_data.events_request = events_request;
+  closure_data.tss = tss;
+  closure_data.end_time = evtime;
+
+  TimeWindow time_window = 
+          lttvwindow_get_time_window(control_flow_data->tab);
+  guint width = control_flow_data->drawing->width;
+  convert_time_to_pixels(
+            time_window,
+            evtime,
+            width,
+            &closure_data.x_end);
+
+  /* Draw last items */
+  g_hash_table_foreach(process_list->process_hash, draw_closure,
+                        (void*)&closure_data);
+#if 0
+  /* Reactivate sort */
+  gtk_tree_sortable_set_sort_column_id(
+      GTK_TREE_SORTABLE(control_flow_data->process_list->list_store),
+      GTK_TREE_SORTABLE_DEFAULT_SORT_COLUMN_ID,
+      GTK_SORT_ASCENDING);
+
+  update_index_to_pixmap(control_flow_data->process_list);
+  /* Request a full expose : drawing scrambled */
+  gtk_widget_queue_draw(control_flow_data->drawing->drawing_area);
+#endif //0
+  /* Request expose (updates damages zone also) */
+  drawing_request_expose(events_request, tss, evtime);
+
+  return 0;
+}
This page took 0.040977 seconds and 4 git commands to generate.