-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathMakefile
More file actions
executable file
·80 lines (59 loc) · 3.39 KB
/
Copy pathMakefile
File metadata and controls
executable file
·80 lines (59 loc) · 3.39 KB
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
all: fogsim
CC = g++
RFLAGS = -O2 -std=c++11
CFLAGS = -c -g -Wno-sign-compare -std=c++11
DFLAGS = -g -Wall
ROUTING = routing.h min.h minCond.h val.h valAny.h obl.h acor.h pb.h pbAny.h pbAcor.h srcAdp.h tpr.h litpr.h par.h ugal.h ofar.h rlm.h olm.h car.h
ROUTING_FILES = $(addprefix routing/, $(ROUTING))
FLIT = flitModule.h pbFlit.h creditFlit.h caFlit.h
FLIT_FILES = $(addprefix flit/, $(FLIT))
TRAFFIC = steady.h burst.h all2all.h mix.h transient.h cluster.h
TRAFFIC_FOLDERS = $(addprefix generator/, $(addprefix trafficPattern/, $(TRAFFIC)))
GENERATOR = event.h generatorModule.h trace.h traceGenerator.h burstGenerator.h graph500Generator.h stencilGenerator.h
GENERATOR_FILES = $(addprefix generator/, $(GENERATOR)) $(TRAFFIC_FOLDERS)
SWITCH = switchModule.h ioqSwitchModule.h
ARBITER = arbiter.h cosArbiter.h lrsArbiter.h priorityLrsArbiter.h rrArbiter.h priorityRrArbiter.h ageArbiter.h priorityAgeArbiter.h inputArbiter.h outputArbiter.h
PORT = port.h bufferedPort.h inPort.h outPort.h bufferedOutPort.h dynBufInPort.h dynBufOutPort.h dynBufBufferedOutPort.h
BUFFER = buffer.h
VCMNGMT = vcMngmt.h oppVcMngmt.h rlmVcMngmt.h flexVc.h tbFlexVc.h qcnVcMngmt.h
SWITCH_FOLDERS = $(SWITCH) $(ARBITER) $(BUFFER) $(PORT) $(VCMNGMT)
SWITCH_FILES = switch/*.h switch/*/*.h
HEADERS = dgflySimulator.h gModule.h configurationFile.h global.h pbState.h caHandler.h communicator.h generator/dimemas.h $(FLIT_FILES) $(ROUTING_FILES) $(GENERATOR_FILES) $(SWITCH_FILES)
fogsim:
$(CC) $(RFLAGS) dgflySimulator.cc gModule.cc configurationFile.cc global.cc pbState.cc caHandler.cc communicator.cc $(FLIT_FILES:.h=.cc) $(ROUTING_FILES:.h=.cc) $(SWITCH_FILES:.h=.cc) $(GENERATOR_FILES:.h=.cc) -o fogsim
dev: dgflySimulator.o gModule.o configurationFile.o global.o pbState.o caHandler.o communicator.o $(FLIT:.h=.o) $(ROUTING:.h=.o) $(GENERATOR:.h=.o) $(TRAFFIC:.h=.o) $(SWITCH_FOLDERS:.h=.o)
$(CC) $(DFLAGS) dgflySimulator.o gModule.o configurationFile.o global.o pbState.o caHandler.o communicator.o $(FLIT:.h=.o) $(ROUTING:.h=.o) $(GENERATOR:.h=.o) $(TRAFFIC:.h=.o) $(SWITCH_FOLDERS:.h=.o) -o fogsim
dgflySimulator.o: dgflySimulator.cc $(HEADERS)
$(CC) $(CFLAGS) dgflySimulator.cc
gModule.o: gModule.cc $(HEADERS)
$(CC) $(CFLAGS) gModule.cc
configurationFile.o: configurationFile.cc $(HEADERS)
$(CC) $(CFLAGS) configurationFile.cc
global.o: global.cc $(HEADERS)
$(CC) $(CFLAGS) global.cc
pbState.o: pbState.cc $(HEADERS)
$(CC) $(CFLAGS) pbState.cc
caHandler.o: caHandler.cc $(HEADERS)
$(CC) $(CFLAGS) caHandler.cc
communicator.o: communicator.cc $(HEADERS)
$(CC) $(CFLAGS) communicator.cc
$(ROUTING:.h=.o): %.o: routing/%.cc $(HEADERS)
$(CC) $(CFLAGS) routing/$(@:.o=.cc)
$(FLIT:.h=.o): %.o: flit/%.cc $(HEADERS)
$(CC) $(CFLAGS) flit/$(@:.o=.cc)
$(TRAFFIC:.h=.o): %.o: generator/trafficPattern/%.cc $(HEADERS)
$(CC) $(CFLAGS) generator/trafficPattern/$(@:.o=.cc)
$(GENERATOR:.h=.o): %.o: generator/%.cc $(HEADERS)
$(CC) $(CFLAGS) generator/$(@:.o=.cc)
$(SWITCH:.h=.o): %.o: switch/%.cc $(HEADERS)
$(CC) $(CFLAGS) switch/$(@:.o=.cc)
$(ARBITER:.h=.o): %.o: switch/arbiter/%.cc $(HEADERS)
$(CC) $(CFLAGS) switch/arbiter/$(@:.o=.cc)
$(PORT:.h=.o): %.o: switch/port/%.cc $(HEADERS)
$(CC) $(CFLAGS) switch/port/$(@:.o=.cc)
$(BUFFER:.h=.o): %.o: switch/buffer/%.cc $(HEADERS)
$(CC) $(CFLAGS) switch/buffer/$(@:.o=.cc)
$(VCMNGMT:.h=.o): %.o: switch/vcManagement/%.cc $(HEADERS)
$(CC) $(CFLAGS) switch/vcManagement/$(@:.o=.cc)
clean:
rm -f *.o fogsim