[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1118618: Updating rocr-runtime libraries to 6.4 causes llama.cpp/ggml to fail



Source: rocr-runtime
Version: 7.0.1+dfsg-1
Severity: serious

Dear Maintainer,

my backport of llama.cpp/ggml for trixie starts to fail when upgrading
libraries from rocr-runtime from 6.1 to 6.4.

llama.cpp and ggml were recently removed from testing for dependency
reasons, but since this is nevertheless easily reproducible, I need to
suspect that rocr-runtime is broken, therefore filing with severity:
serious to prevent migration to testing.


Steps to reproduce on a vanilla trixie system with an AMD GPU:

// Prerequisites
# cat /etc/apt/sources.list
deb     http://192.168.0.21:9999/debian trixie main contrib non-free-firmware
deb-src http://192.168.0.21:9999/debian trixie main contrib non-free-firmware
 
deb     http://192.168.0.21:9999/debian unstable main contrib non-free-firmware
deb-src http://192.168.0.21:9999/debian unstable main contrib non-free-firmware

# cat /etc/apt/preferences.d/unstable.pref 
Package: *
Pin: release a=unstable
Pin-Priority: 50


// We need some build dependencies from unstable, primarily for #1116585
# apt-get install -y pkg-rocm-tools/unstable libamdhip64-dev/unstable libhiprtc-builtins5/unstable

// Set to whatever test arch you are using, to speed things up
# export ROCM_TARGET_ARCH_FIXED=gfx1030

// Build the package for trixie
# apt-get build-dep -y ggml
# apt-get source ggml && cd ggml-*
# dpkg-buildpackage

// Install ggml with the right backends
# dpkg -i ../libggml0_*.deb ../libggml0-backend-{cpu,hip}_*.deb

// Install llama.cpp from unstable
# apt-get install -y llama.cpp-tools/unstable

// Download a model
# wget https://huggingface.co/ggml-org/gemma-3-1b-it-GGUF/resolve/main/gemma-3-1b-it-Q4_K_M.gguf

// Known good case produces benchmark statistics
# llama-bench -m gemma-3-1b-it-Q4_K_M.gguf

// Upgrade rocr-runtime
# apt-get install -y libhsa-runtime-dev/unstable libhsa-runtime64-1/unstable libhsakmt1/unstable

// llama-bench now errors out
# llama-bench -m gemma-3-1b-it-Q4_K_M.gguf

KFD does not support xnack mode query.
ROCr must assume xnack is disabled.
free(): invalid pointer
Aborted


Best,
Christian


Reply to: