-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconga-topology.h
44 lines (32 loc) · 1.28 KB
/
conga-topology.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
42
43
44
#include "pipe.h"
#include "logfile.h"
#include "loggers.h"
#include "test.h"
#include "aprx-fairqueue.h"
#include "fairqueue.h"
#include "priorityqueue.h"
#include "stoc-fairqueue.h"
class CongaTopology {
public:
constexpr static int N_CORE = 12; // In full network
constexpr static int N_LEAF = 24; // In full network
constexpr static int N_SERVER = 32; // Per leaf
constexpr static int N_NODES = N_SERVER * N_LEAF;
constexpr static uint64_t LEAF_BUFFER = 512000;
constexpr static uint64_t CORE_BUFFER = 1024000;
constexpr static uint64_t ENDH_BUFFER = 8192000;
constexpr static uint64_t LEAF_SPEED = 10000000000; // 10gbps
constexpr static uint64_t CORE_SPEED = 40000000000; // 40gbps
constexpr static double LINK_DELAY = 0.1; // in microsec
Pipe *pCoreLeaf[N_CORE][N_LEAF];
Queue *qCoreLeaf[N_CORE][N_LEAF];
Pipe *pLeafCore[N_CORE][N_LEAF];
Queue *qLeafCore[N_CORE][N_LEAF];
Pipe *pLeafServer[N_LEAF][N_SERVER];
Queue *qLeafServer[N_LEAF][N_SERVER];
Pipe *pServerLeaf[N_LEAF][N_SERVER];
Queue *qServerLeaf[N_LEAF][N_SERVER];
void genTopology(std::string &queueType, Logfile &logfile);
private:
void createQueue(std::string &qType, Queue *&queue, uint64_t speed, uint64_t buffer, Logfile &lf);
};