-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
47 lines (34 loc) · 799 Bytes
/
Makefile
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
# C++ proyect
###
######## [email protected]
###
# Makefile logic:
# To create this file you need these files:
# $ @ replace left
# $ ^ right
### Command requested
# gunzip -c branch-trace-gcc.trace.gz | branch -s < # > -bp < # > -gh < # > -ph < # >
# Folders
INCLUDE = ./include/
INPUT = ./input/
RESULT = ./results/
SRC = ./src/
#######
S = 4
BP = 0
GH = 4
PH = 3
.PHONY: all run
all: branch
# buil run
CPP_FLAGS = -std=c++1y -I$(PWD)/include #search includes dir include
%.o: $(SRC)%.cpp
g++ -c $^ -o $@ $(CPP_FLAGS)
branch: main.o pBimodal.o pPHistory.o pGHistory.o pTournament.o # all compile
g++ $^ -o $@
.PHONY: run
run: branch
gunzip -c $(INPUT)branch-trace-gcc.trace.gz | ./branch -s $(S) -bp $(BP) -gh $(GH) -ph $(PH)
.PHONY: clean
clean:
rm -f *.o branch