X-Git-Url: http://git.lttng.org/?a=blobdiff_plain;f=lttv%2Flttv%2Fsync%2Fevent_analysis.h;h=da26cf35715cdb5ab759c749a0aeb217f83c34bd;hb=eb8e0e6fa27e4cfe25138d8275ee6f686ee2b32d;hp=146b9b62a025c85c94ba382f1b4f6dbcdb6b3ecf;hpb=336e21a5943e770da94553fa9559b891e0155da5;p=lttv.git diff --git a/lttv/lttv/sync/event_analysis.h b/lttv/lttv/sync/event_analysis.h index 146b9b62..da26cf35 100644 --- a/lttv/lttv/sync/event_analysis.h +++ b/lttv/lttv/sync/event_analysis.h @@ -31,18 +31,51 @@ typedef struct { char* name; + /* + * This function is called at the beginning of a synchronization run for a set + * of traces. Allocate analysis specific data structures. + */ void (*initAnalysis)(struct _SyncState* const syncState); + + /* + * Free the analysis specific data structures. + */ void (*destroyAnalysis)(struct _SyncState* const syncState); + /* + * Perform analysis on an event pair. + */ void (*analyzeMessage)(struct _SyncState* const syncState, Message* const message); + + /* + * Perform analysis on multiple messages. + */ void (*analyzeExchange)(struct _SyncState* const syncState, Exchange* const exchange); + + /* + * Perform analysis on muliple events. + */ void (*analyzeBroadcast)(struct _SyncState* const syncState, Broadcast* const broadcast); + + /* + * Finalize the factor calculations. Return synchronization factors + * between trace pairs. + */ AllFactors* (*finalizeAnalysis)(struct _SyncState* const syncState); + /* + * Print statistics related to analysis. Is always called after + * finalizeAnalysis. + */ void (*printAnalysisStats)(struct _SyncState* const syncState); + + /* + * Write the analysis-specific options and graph commands in the gnuplot + * script. Is always called after finalizeAnalysis. + */ GraphFunctions graphFunctions; } AnalysisModule;