forked from N-BodyShop/changa
-
Notifications
You must be signed in to change notification settings - Fork 0
/
HierarchOrbLB.h
41 lines (31 loc) · 891 Bytes
/
HierarchOrbLB.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
/**
* Author: [email protected] (Harshitha Menon)
*/
#ifndef HIERARCH_ORBLB_H
#define HIERARCH_ORBLB_H
#include "HierarchOrbLB.decl.h"
#include "HybridBaseLB.h"
#include "CentralLB.h"
void CreateHierarchOrbLB();
class HierarchOrbLB : public CBase_HierarchOrbLB
{
public:
HierarchOrbLB(const CkLBOptions &);
HierarchOrbLB(CkMigrateMessage *m): CBase_HierarchOrbLB(m) {init();}
~HierarchOrbLB();
protected:
CentralLB *orblb;
CentralLB *refinelb;
void init();
virtual bool QueryBalanceNow(int step) {
if(step == 0) return false;
return true;
};
virtual bool QueryMigrateStep(int) { return true; };
virtual void work(LDStats* stats);
virtual void GetObjsToMigrate(int toPe, double load, LDStats *stats,
int atlevel, CkVec<LDCommData>& comms, CkVec<LDObjData>& objs);
private:
CProxy_HierarchOrbLB thisProxy;
};
#endif /* HIERARCH_ORBLB_H */