The ROCm HIP runtime (libamdhip64) reads the TEMP environment variable as its JIT kernel-cache temp directory. Commitdb3eb01added TEMP=1.0 to the env files as a sampling default; the serve scripts export it via set -a. HIP then used the path "1.0" for its cache, failed, and segfaulted with a NULL-refcount unref (offset 0x446153 in libamdhip64) during model tensor upload (ggml_backend_cuda_buffer_set_tensor). This crashed frank-default- large on every restart from Aug 13 16:22 onward; the earlierc984a3e"fix" (KV/batch changes) was unrelated. Rename the sampling variable TEMP -> TEMPERATURE in both env files and serve scripts. llama-server still receives --temp from the renamed var, so sampling defaults are unchanged. The HIP runtime no longer sees a bogus TEMP value. Affects frank-default-large (dankclaw) and frank-default-small (dankserver).
48 lines
2.1 KiB
Bash
48 lines
2.1 KiB
Bash
# Tunables for frank-default-large (HauhauCS Qwen3.6-27B Q8_K_P, DFlash+ngram-mod, dankclaw)
|
|
# Runtime: llama.cpp llama-server; AMD Strix Halo (gfx1151) 96GB UMA; Ryzen AI MAX+ 395.
|
|
MODEL_DIR=/home/dank/models
|
|
ALIAS=frank-default-large
|
|
HOST=0.0.0.0
|
|
PORT=7770
|
|
# 3 parallel slots x 200700 ctx each = 602100 total context pool.
|
|
CTX_SIZE=602100
|
|
PARALLEL=3
|
|
# Spec: DFlash draft model. Bench (4k, ROCm) showed draft-dflash fastest
|
|
# generation (20.2 t/s): DFlash+ngram 16.9, ngram-only 8.7. ngram layering
|
|
# reduced throughput, so it is not layered in production.
|
|
SPEC_TYPE=draft-dflash
|
|
SPEC_DRAFT_N_MAX=8
|
|
SPEC_NGRAM_MOD_N_MIN=48
|
|
SPEC_NGRAM_MOD_N_MAX=64
|
|
SPEC_NGRAM_MOD_N_MATCH=24
|
|
# Backend device from --list-devices. ROCm wins on generation; Vulkan renders
|
|
# DFlash spec unusable (NONE-op abort) and gen is slower on ngram (6.9 t/s).
|
|
DEVICE=ROCm0
|
|
# Dense model (Qwen3.6-27B, not MoE): no MoE CPU offload. Full offload.
|
|
N_GPU_LAYERS=all
|
|
# KV on GPU, quantized (K q8_0, V q8_0). V MUST match K: this llama.cpp
|
|
# build has GGML_CUDA_FA_ALL_QUANTS=OFF, and Flash Attention requires
|
|
# K type == V type. Mixed q8_0/f16 silently disables FA, collapsing
|
|
# long-context decode to ~1 t/s at 200k ctx. q8_0 V halves V memory too.
|
|
CACHE_TYPE_K=q8_0
|
|
CACHE_TYPE_V=q8_0
|
|
# Batch sizing constrained by ROCm memory at 602100 ctx (3x200700):
|
|
# KV ~50GB + model 29.77GB leave only ~16GB for compute graphs. The compute
|
|
# graph scales with UBATCH, so ubatch must stay ~512; ubatch 2048 OOMs even
|
|
# at batch 2048. Proven-fits config: batch 2048 / ubatch 512.
|
|
# User-specified ubatch 4096 / batch 12288 is not feasible here (see bench).
|
|
BATCH_SIZE=2048
|
|
UBATCH_SIZE=512
|
|
# Sampling settings — per HauhauCS Qwen3.6-27B model card.
|
|
# Thinking-general: temp=1.0, top_p=0.95, top_k=20, min_p=0.
|
|
# Clients may override per-request; these are the server-side defaults.
|
|
# WARNING: do not name this variable TEMP. The ROCm HIP runtime reads the
|
|
# TEMP environment variable (JIT kernel-cache dir); TEMP=1.0 made the HIP
|
|
# runtime SEGV (NULL unref) during model load on Aug 13 2026.
|
|
TEMPERATURE=1.0
|
|
TOP_K=20
|
|
TOP_P=0.95
|
|
MIN_P=0.0
|
|
THREADS=12
|
|
THREADS_HTTP=1
|