-
Notifications
You must be signed in to change notification settings - Fork 25
Expand file tree
/
Copy pathMakefile
More file actions
21 lines (14 loc) · 677 Bytes
/
Makefile
File metadata and controls
21 lines (14 loc) · 677 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
CC = nvcc
CXXFLAGS = -O3
DEPS = gemm_cpu_naive.h gemm_cpu_simd.h gemm_gpu_1thread.h gemm_gpu_mult_thread.h gemm_gpu_mult_block.h gemm_gpu_mult_block_no_restrict.h gemm_gpu_mult_block_no_restrict_reg.h gemm_gpu_tiling.h
OBJS = gemm_cpu_naive.o gemm_cpu_simd.o gemm_test.o gemm_gpu_1thread.o gemm_gpu_mult_thread.o gemm_gpu_mult_block.o gemm_gpu_mult_block_no_restrict.o gemm_gpu_mult_block_no_restrict_reg.o gemm_gpu_tiling.o
.PHONY: all clean
all: gemm_test
%.o: %.cc $(DEPS) # for .cc files
$(CC) -c $(CXXFLAGS) $< -o $@
%.o: %.cu $(DEPS) # for .cu files
$(CC) -c $(CXXFLAGS) $< -o $@
gemm_test: $(OBJS)
$(CC) $(CXXFLAGS) $^ -o gemm_test
clean:
rm -f *.o gemm_test