Skip to content

Commit fc899ce

Browse files
committed
fix(rocm): add gfx1151 support and expose AMDGPU_TARGETS build-arg
Add gfx1151 (AMD Strix Halo / Ryzen AI MAX) to the default AMDGPU_TARGETS list in the llama-cpp backend Makefile. ROCm 7.2.1 ships with gfx1151 Tensile libraries, so this architecture should be included in default builds. Also expose AMDGPU_TARGETS as an ARG/ENV in Dockerfile.llama-cpp so that users building for non-default GPU architectures can override the target list via --build-arg AMDGPU_TARGETS=<arch>. Previously, passing -DAMDGPU_TARGETS=<arch> through CMAKE_ARGS was silently overridden by the Makefile's own append of the default target list. Fixes #9374 Signed-off-by: Keith Mattix <keithmattix2@gmail.com>
1 parent 86c673f commit fc899ce

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

backend/Dockerfile.llama-cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,8 @@ ARG CUDA_DOCKER_ARCH
5858
ENV CUDA_DOCKER_ARCH=${CUDA_DOCKER_ARCH}
5959
ARG CMAKE_ARGS
6060
ENV CMAKE_ARGS=${CMAKE_ARGS}
61+
ARG AMDGPU_TARGETS
62+
ENV AMDGPU_TARGETS=${AMDGPU_TARGETS}
6163
ARG BACKEND=rerankers
6264
ARG BUILD_TYPE
6365
ENV BUILD_TYPE=${BUILD_TYPE}

backend/cpp/llama-cpp/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ else ifeq ($(BUILD_TYPE),hipblas)
3333
ROCM_PATH ?= /opt/rocm
3434
export CXX=$(ROCM_HOME)/llvm/bin/clang++
3535
export CC=$(ROCM_HOME)/llvm/bin/clang
36-
AMDGPU_TARGETS?=gfx908,gfx90a,gfx942,gfx950,gfx1030,gfx1100,gfx1101,gfx1102,gfx1200,gfx1201
36+
AMDGPU_TARGETS?=gfx908,gfx90a,gfx942,gfx950,gfx1030,gfx1100,gfx1101,gfx1102,gfx1151,gfx1200,gfx1201
3737
CMAKE_ARGS+=-DGGML_HIP=ON -DAMDGPU_TARGETS=$(AMDGPU_TARGETS)
3838
else ifeq ($(BUILD_TYPE),vulkan)
3939
CMAKE_ARGS+=-DGGML_VULKAN=1

0 commit comments

Comments
 (0)