[GH-ISSUE #4982] [Benchmark] Vega 64 (gfx900, 8 GB) + 32 GB RAM, Qwen3.8-Flash-Next Coder IQ1_M: build notes and load test #2298

Closed
opened 2026-11-04 01:58:15 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @nerdoc on GitHub (Nov 2, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4982

What did you measure, or what went wrong

Strata on a Radeon RX Vega 64 (gfx900, 8 GB HBM2) with 32 GB RAM, running Qwen3.8-Flash-Next Coder IQ1_M through
the gfx906 compat backend. It builds with four small changes and survived a ~2 h load test without a failed request.
Posting the build notes and numbers for other gfx900 owners, plus one scope question (hipBLAS < 1.0).

Environment

  • GPU: Radeon RX Vega 64, gfx900, 8 GB HBM2, PCIe 3.0 x16, Resizable BAR off
  • CPU / RAM: Ryzen 5 1600 (6C/12T), 32 GB DDR4-2666, SATA SSD
  • OS: Debian 13, kernel 6.12, Debian's HIP 5.7.1 / hipBLAS 0.54 / clang 17 (no AMD repo)
  • Strata c62d5e3a (engine 0.1.55), ggml at the pinned 3cf0325
  • Build:
    cmake -S . -B build-gfx900 -DCMAKE_BUILD_TYPE=Release -DSTRATA_HIP_GFX906=ON -DCMAKE_HIP_ARCHITECTURES=gfx900 \
      -DCMAKE_HIP_COMPILER=/usr/lib/llvm-17/bin/clang++ -DCMAKE_HIP_COMPILER_ROCM_ROOT=/usr \
      -DCMAKE_PREFIX_PATH=/usr/lib/x86_64-linux-gnu/cmake -DSTRATA_GGML_DIR=<llama.cpp at 3cf0325> -DSTRATA_BUILD_TESTS=OFF
    cmake --build build-gfx900 --target strata
    
  • Model: Qwen3.8-Flash-Next GSQ-RCO IQ1_M (coder pack), --mmap-experts --expert-profile data/expert-profile-coder.bin --expert-cache auto --prefill auto --spec 4 --spec-min-p 0.5 --mtp <mtp/rt> --max-context 65536 --kv int8 --kv-resident 16384 --vram-reserve-mib 768 --adapt-every 0 --pcie-frac 0, served with serve.server --engine strata

What the gfx900 build needed at c62d5e3a

  1. v_fma_mixlo_f16 inline asm in gdn_out_norm_loop_kernel<false> does not assemble for gfx900 (the mix
    instructions are gfx906+). Fixed in #4983.
  2. __shared__ alignas(16) int4 in iq_kernels.cu (clang 17): covered by open PRs; I use #4600 (drops the
    redundant alignas, alignof(int4) == 16 on HIP), confirmed there.
  3. cudaStreamCreateWithPriority / cudaDeviceGetStreamPriorityRange in dflash2.cpp: I use #4766, confirmed
    there.
  4. hipBLAS 0.54 (what Debian 13 ships) has no hipblasComputeType_t, and hipblasGemmEx takes
    hipblasDatatype_t for every type argument. I mapped CUBLAS_COMPUTE_32F / CUDA_R_32F / CUDA_R_16F /
    CUDA_R_16BF to HIPBLAS_R_32F / HIPBLAS_R_32F / HIPBLAS_R_16F / HIPBLAS_R_16B under
    #if hipblasVersionMajor < 1 in hip_compat/cublas_v2.h. Built against ROCm 6.4 from Debian sid (hipBLAS,
    rocBLAS 6.4.4, HIP 6.4.3, in a container on the same machine) the build needs only changes 1–3, and that binary
    served requests on the card without hipBLAS errors (14–15 t/s decode, a 2,627-token prompt at 116 t/s).
    Question: is hipBLAS < 1.0 in scope for the gfx906 backend? If yes, I can open a PR with this mapping;
    if not, a line in docs/AMD_HIP.md saying "needs hipBLAS ≥ 1.0 / ROCm ≥ 6" would have saved me some time.

Side note for the sid container: GCC 16's libstdc++ <format> uses [[__gnu__::__noinline__]], which collides
with HIP's __noinline__ macro. Building with --gcc-install-dir pointing at GCC 15 avoids it. That is a HIP/GCC
issue, not Strata's.

Load test (2026-11-01/02, single machine, OpenAI API on 127.0.0.1, server-default sampling, enable_thinking: false;
numbers are the server's timings, one run each):

Stage Prompt tokens Prefill t/s Decode t/s Result
Needle at 10 % depth 13,814 130 14.1 found
Needle 27,498 163 16.5 found
Needle 46,421 118 9.6 found
3,000-token output 62 — 12.3 3,000 tokens, length
3 parallel requests, ~5.3k each 5,101 / 5,391 / 5,423 161 / 88 / 90 12–13 all answered, served one after another (41 / 116 / 188 s wall)
45 min soak: one multi-turn conversation up to 33.8k cached tokens + a side request every 4th turn — — 13.1 (first 20 turns) → 16.7 (last 20), min 10.2 463 turns + 115 side requests, 0 errors

Decode is bounded by the expert reads from RAM, not the GPU (VRAM expert cache hit rate ~8–10 %). VRAM in use went from 7,466 to
7,734 MiB in the first 50 min and then stayed there, swap flat, no GPU faults in dmesg. Another client sent two requests during the needle stages, so
those prefill numbers are slightly pessimistic.

After that an agent run (hermes-agent with tools: write a script, run it, write and run a unittest, write a
report): 10 model turns at 9.7k–15.7k tokens of context, 6 min in total, correct result. From the second turn on the
conversation cache leaves 150–2,600 new tokens per turn (4–17 s prefill); decode 14–17 t/s.

Observations

  • dmesg shows amdgpu: init_user_pages: Failed to get user pages: -1 in bursts (~1,900 lines at engine start,
    ~22,500 during the test). As far as I can tell this is pin_blobs() in src/program/generate.cpp:
    cudaHostRegister(..., cudaHostRegisterReadOnly | ...) on the read-only mapped expert files fails on HIP 5.7 and
    the range stays pageable, as the code intends. No request failed; I did not check whether ROCm 6.4 pins them.
  • S3 suspend breaks HIP on this card/kernel: after resume every HIP process dies with GPU memory access fault
    until a reboot, and while the engine runs amdgpu refuses to suspend at all. Hibernate works. (Seen with Strata
    0.2.8 on 2026-10-30; I now stop the engine before sleep and disabled S3.)
  • After a reboot the page cache is cold and the first request reads ~27 GB of experts from the SATA SSD (prefill
    ~3–10 t/s); after that the numbers above apply.

Reproduction status

Measured locally

Originally created by @nerdoc on GitHub (Nov 2, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/4982 ### What did you measure, or what went wrong Strata on a **Radeon RX Vega 64 (gfx900, 8 GB HBM2)** with 32 GB RAM, running Qwen3.8-Flash-Next Coder IQ1_M through the gfx906 compat backend. It builds with four small changes and survived a ~2 h load test without a failed request. Posting the build notes and numbers for other gfx900 owners, plus one scope question (hipBLAS < 1.0). **Environment** - GPU: Radeon RX Vega 64, gfx900, 8 GB HBM2, PCIe 3.0 x16, Resizable BAR off - CPU / RAM: Ryzen 5 1600 (6C/12T), 32 GB DDR4-2666, SATA SSD - OS: Debian 13, kernel 6.12, Debian's HIP 5.7.1 / hipBLAS 0.54 / clang 17 (no AMD repo) - Strata `c62d5e3a` (engine 0.1.55), ggml at the pinned `3cf0325` - Build: ``` cmake -S . -B build-gfx900 -DCMAKE_BUILD_TYPE=Release -DSTRATA_HIP_GFX906=ON -DCMAKE_HIP_ARCHITECTURES=gfx900 \ -DCMAKE_HIP_COMPILER=/usr/lib/llvm-17/bin/clang++ -DCMAKE_HIP_COMPILER_ROCM_ROOT=/usr \ -DCMAKE_PREFIX_PATH=/usr/lib/x86_64-linux-gnu/cmake -DSTRATA_GGML_DIR=<llama.cpp at 3cf0325> -DSTRATA_BUILD_TESTS=OFF cmake --build build-gfx900 --target strata ``` - Model: Qwen3.8-Flash-Next GSQ-RCO IQ1_M (coder pack), `--mmap-experts --expert-profile data/expert-profile-coder.bin --expert-cache auto --prefill auto --spec 4 --spec-min-p 0.5 --mtp <mtp/rt> --max-context 65536 --kv int8 --kv-resident 16384 --vram-reserve-mib 768 --adapt-every 0 --pcie-frac 0`, served with `serve.server --engine strata` **What the gfx900 build needed at `c62d5e3a`** 1. `v_fma_mixlo_f16` inline asm in `gdn_out_norm_loop_kernel<false>` does not assemble for gfx900 (the mix instructions are gfx906+). Fixed in #4983. 2. `__shared__ alignas(16) int4` in `iq_kernels.cu` (clang 17): covered by open PRs; I use #4600 (drops the redundant `alignas`, `alignof(int4) == 16` on HIP), confirmed there. 3. `cudaStreamCreateWithPriority` / `cudaDeviceGetStreamPriorityRange` in `dflash2.cpp`: I use #4766, confirmed there. 4. **hipBLAS 0.54** (what Debian 13 ships) has no `hipblasComputeType_t`, and `hipblasGemmEx` takes `hipblasDatatype_t` for every type argument. I mapped `CUBLAS_COMPUTE_32F` / `CUDA_R_32F` / `CUDA_R_16F` / `CUDA_R_16BF` to `HIPBLAS_R_32F` / `HIPBLAS_R_32F` / `HIPBLAS_R_16F` / `HIPBLAS_R_16B` under `#if hipblasVersionMajor < 1` in `hip_compat/cublas_v2.h`. Built against ROCm 6.4 from Debian sid (hipBLAS, rocBLAS 6.4.4, HIP 6.4.3, in a container on the same machine) the build needs only changes 1–3, and that binary served requests on the card without hipBLAS errors (14–15 t/s decode, a 2,627-token prompt at 116 t/s). **Question:** is hipBLAS < 1.0 in scope for the gfx906 backend? If yes, I can open a PR with this mapping; if not, a line in `docs/AMD_HIP.md` saying "needs hipBLAS ≥ 1.0 / ROCm ≥ 6" would have saved me some time. Side note for the sid container: GCC 16's libstdc++ `<format>` uses `[[__gnu__::__noinline__]]`, which collides with HIP's `__noinline__` macro. Building with `--gcc-install-dir` pointing at GCC 15 avoids it. That is a HIP/GCC issue, not Strata's. **Load test** (2026-11-01/02, single machine, OpenAI API on `127.0.0.1`, server-default sampling, `enable_thinking: false`; numbers are the server's `timings`, one run each): | Stage | Prompt tokens | Prefill t/s | Decode t/s | Result | |---|---|---|---|---| | Needle at 10 % depth | 13,814 | 130 | 14.1 | found | | Needle | 27,498 | 163 | 16.5 | found | | Needle | 46,421 | 118 | 9.6 | found | | 3,000-token output | 62 | — | 12.3 | 3,000 tokens, `length` | | 3 parallel requests, ~5.3k each | 5,101 / 5,391 / 5,423 | 161 / 88 / 90 | 12–13 | all answered, served one after another (41 / 116 / 188 s wall) | | 45 min soak: one multi-turn conversation up to 33.8k cached tokens + a side request every 4th turn | — | — | 13.1 (first 20 turns) → 16.7 (last 20), min 10.2 | 463 turns + 115 side requests, 0 errors | Decode is bounded by the expert reads from RAM, not the GPU (VRAM expert cache hit rate ~8–10 %). VRAM in use went from 7,466 to 7,734 MiB in the first 50 min and then stayed there, swap flat, no GPU faults in `dmesg`. Another client sent two requests during the needle stages, so those prefill numbers are slightly pessimistic. After that an agent run (hermes-agent with tools: write a script, run it, write and run a unittest, write a report): 10 model turns at 9.7k–15.7k tokens of context, 6 min in total, correct result. From the second turn on the conversation cache leaves 150–2,600 new tokens per turn (4–17 s prefill); decode 14–17 t/s. **Observations** - `dmesg` shows `amdgpu: init_user_pages: Failed to get user pages: -1` in bursts (~1,900 lines at engine start, ~22,500 during the test). As far as I can tell this is `pin_blobs()` in `src/program/generate.cpp`: `cudaHostRegister(..., cudaHostRegisterReadOnly | ...)` on the read-only mapped expert files fails on HIP 5.7 and the range stays pageable, as the code intends. No request failed; I did not check whether ROCm 6.4 pins them. - **S3 suspend breaks HIP** on this card/kernel: after resume every HIP process dies with `GPU memory access fault` until a reboot, and while the engine runs amdgpu refuses to suspend at all. Hibernate works. (Seen with Strata 0.2.8 on 2026-10-30; I now stop the engine before sleep and disabled S3.) - After a reboot the page cache is cold and the first request reads ~27 GB of experts from the SATA SSD (prefill ~3–10 t/s); after that the numbers above apply. ### Reproduction status Measured locally
Author
Owner

@Niko1221 commented on GitHub (Nov 5, 2026):

Thank you for the benchmark. We have collected these results for the benchmarks page on the Strata website, so we are closing this here. If you measure again, for example on 0.2.11, you are welcome to open a new report.

The Strata project

<!-- gh-comment-id:6658904154 --> @Niko1221 commented on GitHub (Nov 5, 2026): Thank you for the benchmark. We have collected these results for the benchmarks page on the Strata website, so we are closing this here. If you measure again, for example on 0.2.11, you are welcome to open a new report. The Strata project
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#2298
No description provided.