Fixed build problems with BigNetSim which was found to be using
[charm.git] / src / ck-perf / trace-projectionsBOC.h
1 #include "envelope.h"
2 #include "register.h"
3 #include "trace-common.h"
4
5 #include "TraceProjections.decl.h"
6
7 extern CkGroupID traceProjectionsGID;
8
9 class TraceProjectionsInit : public Chare {
10   public:
11   TraceProjectionsInit(CkArgMsg*) {
12     traceProjectionsGID = CProxy_TraceProjectionsBOC::ckNew();
13   }
14   TraceProjectionsInit(CkMigrateMessage *m):Chare(m) {}
15 };
16
17 class OutlierStatsMessage : public CMessage_OutlierStatsMessage {
18  public:
19   double *stats;
20 };
21
22 class OutlierWeightMessage : public CMessage_OutlierWeightMessage {
23  public:
24   int sourcePe;
25   double weight;
26 };
27
28 class OutlierThresholdMessage : public CMessage_OutlierThresholdMessage {
29  public:
30   double threshold;
31 };
32
33 class TraceProjectionsBOC : public CBase_TraceProjectionsBOC {
34 private:
35   double dummy;
36   double endTime;
37   double analysisStartTime;
38   double *execTimes;
39   double weight;
40   int encounteredWeights;
41   double *weightArray;
42   int *mapArray;
43
44   FILE *outlierfp;
45   
46 public:
47   TraceProjectionsBOC(void) {};
48   TraceProjectionsBOC(CkMigrateMessage *m):CBase_TraceProjectionsBOC(m) {};
49   void startOutlierAnalysis();
50   void outlierAverageReduction(CkReductionMsg *);
51   void calculateWeights(OutlierStatsMessage *);
52   void determineOutliers(OutlierWeightMessage *);
53   void setOutliers(OutlierThresholdMessage *);
54   void startEndTimeAnalysis();
55   void endTimeReduction(CkReductionMsg *);
56   void finalReduction(CkReductionMsg *);
57   void shutdownAnalysis(void);
58   void closeTrace(void);
59 };
60
61