-
Notifications
You must be signed in to change notification settings - Fork 12
Expand file tree
/
Copy pathMakefile
More file actions
34 lines (23 loc) · 743 Bytes
/
Makefile
File metadata and controls
34 lines (23 loc) · 743 Bytes
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
CFLAGS=-Wno-unused-result -mavx -O3 -std=c99 -fopenmp
all: cnn cnnModule.so
cnn: src/cnn.c src/util.c src/main.c
gcc $(CFLAGS) src/cnn.c -lm -o cnn
cnnModule.so: src/cnn.c src/python.c src/util.c
gcc $(CFLAGS) -shared -fPIC -I/usr/include/python2.7 -o cnnModule.so src/python.c src/cnn.c
run: cnnModule.so
@python cnn.py
benchmark: cnn
@cd test ; ../cnn benchmark 2400
benchmark-small: cnn
@cd test ; ../cnn benchmark 1200
benchmark-large: cnn
@cd test ; ../cnn benchmark 12000
benchmark-huge: cnn
@cd test ; ../cnn benchmark 24000
test: cnn
@cd test ; bash run_test.sh
test-huge: cnn
@cd test ; bash huge_test.sh
clean:
rm cnn cnnModule.so
.PHONY: run clean benchmark benchmark-small benchmark-large benchmark-huge test