Update Makefile for the Cuda kernels
This commit is contained in:
parent
0fd8363adc
commit
54a63c10e8
1 changed files with 9 additions and 2 deletions
11
Makefile
11
Makefile
|
@ -108,8 +108,15 @@ ggml-cuda.o: ggml-cuda.cu ggml-cuda.h
|
|||
nvcc -arch=native -c -o $@ $<
|
||||
endif
|
||||
ifdef LLAMA_HIPBLAS
|
||||
CFLAGS += -DGGML_USE_HIPBLAS -D__HIP_PLATFORM_AMD__ -I/opt/rocm/include
|
||||
LDFLAGS += -lhipblas -lamdhip64 -L/opt/rocm/lib
|
||||
ROCMPATH?= /opt/rocm
|
||||
CFLAGS += -DGGML_USE_HIPBLAS -D__HIP_PLATFORM_AMD__ -I$(ROCMPATH)/include
|
||||
CXXFLAGS+= -D__HIP_PLATFORM_AMD__ -I$(ROCMPATH)/include
|
||||
HIPFLAGS?= -amdgpu-early-inline-all=true -amdgpu-function-calls=false -march=native
|
||||
LDFLAGS += -lhipblas -lamdhip64 -L$(ROCMPATH)/lib
|
||||
HIPCC ?= $(ROCMPATH)/bin/hipcc
|
||||
OBJS += ggml-cuda.o
|
||||
ggml-cuda.o: ggml-cuda.cu ggml-cuda.h
|
||||
$(HIPCC) $(CXXFLAGS) -x hip $(HIPFLAGS) -c -o $@ $<
|
||||
endif
|
||||
ifdef LLAMA_GPROF
|
||||
CFLAGS += -pg
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue