#include <unistd.h>
#include "event_analysis.h"
-#include "sync_chain_lttv.h"
+#include "sync_chain.h"
#include "event_matching_tcp.h"
static MatchingModule matchingModuleTCP = {
.name= "TCP",
+ .canMatch[TCP]= true,
+ .canMatch[UDP]= false,
.initMatching= &initMatchingTCP,
.destroyMatching= &destroyMatchingTCP,
.matchEvent= &matchEventTCP,
* Args:
* syncState container for synchronization data.
* event new event to match
- * eventType type of event to match
*/
static void matchEventTCP(SyncState* const syncState, Event* const event)
{
MatchingDataTCP* matchingData;
+ g_assert(event->type == TCP);
+
matchingData= (MatchingDataTCP*) syncState->matchingData;
if (event->event.tcpEvent->direction == IN)
if (message->inE->traceNum < message->outE->traceNum)
{
// CA is inE->traceNum
- x= message->inE->time;
- y= message->outE->time;
+ x= message->inE->cpuTime;
+ y= message->outE->cpuTime;
}
else
{
// CA is outE->traceNum
- x= message->outE->time;
- y= message->inE->time;
+ x= message->outE->cpuTime;
+ y= message->inE->cpuTime;
}
fprintf(stream, "%20llu %20llu\n", x, y);