#define g_debug(format...) g_log (G_LOG_DOMAIN, G_LOG_LEVEL_DEBUG, format)
//FIXME
-#define TRACE_NUMBER 0
+// fixed #define TRACE_NUMBER 0
#define EXTRA_ALLOC 1024 // pixels
#define padding_width 50
}
- void histo_drawing_chunk_begin(EventsRequest *events_request, LttvTracesetState *tss)
+void histo_drawing_chunk_begin(EventsRequest *events_request, LttvTracesetState *tss)
{
g_debug("Begin of chunk");
HistoControlFlowData *cfd = events_request->viewer_data;
LttvTracesetContext *tsc = LTTV_TRACESET_CONTEXT(tss);
- //LttTime current_time = lttv_traceset_context_get_current_tfc(tsc)->timestamp;
- guint num_cpu =
- ltt_trace_get_num_cpu(tss->parent.traces[TRACE_NUMBER]->t);
-
- /* //disabled for histogram
- cfd->process_list->current_hash_data = g_new(HashedProcessData*,num_cpu);
- memset(cfd->process_list->current_hash_data, 0,
- sizeof(HashedProcessData*)*num_cpu);*/
- //cfd->drawing->last_start = LTT_TIME_MIN(current_time,
- // events_request->end_time);
+
+ if(cfd->chunk_has_begun) return;
+
+ cfd->chunk_has_begun = TRUE;
}
#define MAX_PATH_LEN 256
#define g_info(format...) g_log (G_LOG_DOMAIN, G_LOG_LEVEL_INFO, format)
//FIXME
-#define TRACE_NUMBER 0
+// fixed #define TRACE_NUMBER 0
#define EXTRA_ALLOC 1024 // pixels
/* Action to do when background computation completed.
// LttvHooksById *histo_event_by_id = lttv_hooks_by_id_new();//if necessary for filter!
// FIXME : eventually request for more traces
- for(i = 0; i<MIN(TRACE_NUMBER+1, nb_trace);i++)
- {
+ // fixed for(i = 0; i<MIN(TRACE_NUMBER+1, nb_trace);i++) {
+ for(i=0;i<nb_trace;i++) {
//should be in the loop or before?
EventsRequest *histo_events_request = g_new(EventsRequest, 1);
histoDrawing_t *drawing = histocontrol_flow_data->drawing;
+ if(!histocontrol_flow_data->chunk_has_begun) return;
+ histocontrol_flow_data->chunk_has_begun = TRUE;
+
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 */