mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[PR #3343] [Engine] rocBLAS table for gfx1030 with rocBLAS 5.4.0 (TheRock gfx103X-all 7.13 wheels): short follow-up prompts 12% faster #4581
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#4581
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Niko1221/Strata/pull/3343
Author: @elightcap
Created: 10/20/2026
Status: 🔄 Open
Base:
main← Head:hip-rocblas-table-5.4.0📝 Commits (1)
7094f8frocBLAS table for gfx1030 and rocBLAS 5.4.0.ad84daa81c (TheRock gfx103X-all 7.13.0a20260515, setup's wheels and the rx6900 package)📊 Changes
2 files changed (+121 additions, -1 deletions)
View changed files
📝
docs/AMD_HIP.md(+4 -1)➕
tools/hip/gfx1030-rocblas-5.4.0.ad84daa81c.txt(+117 -0)📄 Description
Problem and result
The rocBLAS tables in
tools/hipcover gfx1030 with rocBLAS 5.6.0.8d1ae90e (ROCm 10.0.0) only. An RX 6000 engine builtagainst TheRock's
gfx103X-all7.13.0a20260515 wheels - what setup installs into.venvwhen the PC has no systemROCm 7 (
ROCM_FAMILY_PINS), and what therx6900package of #3329 carries - loads rocBLAS 5.4.0.ad84daa81c, so withSTRATA_HIP_PROMPT_F16=1the engine logsThis adds that table, made with
tools/hip/tune_rocblason an RX 6900 XT against that rocBLAS, and names it indocs/AMD_HIP.md. With it a 268-395-token follow-up on a cached conversation reads 11.7% faster (median), every pair
10-13%; longer fresh prompts change little (numbers below).
Related: #3329 (the package; independent of this PR). Its docs sentence "The package's rocBLAS (5.4.0) has no table in
tools/hipyet" becomes stale once both are merged; I will update whichever lands second.Approach
Data only: the engine already picks
<arch>-rocblas-<version>.txtfromSTRATA_ROCBLAS_TUNINGfor its own rocBLASbuild and refuses any other, and setup already points
STRATA_ROCBLAS_TUNINGattools/hipwhen a table for thecard's arch exists. Nothing changes for an engine on another rocBLAS build (it keeps refusing this file) or without
STRATA_HIP_PROMPT_F16=1(the table serves that route only). The packaged engines do not carrytools/hiptablesyet, so a Terminal user gets it only with
STRATA_ROCBLAS_TUNINGset by hand until packaging includes the tables.tune_rocblaswas built from this tree against the wheels' rocBLAS and run with the rx6900 package's libraries(
LD_LIBRARY_PATH=<package>;lddshows itslibrocblas.so.5andlibamdhip64.so.7). It ran one token bucket perprocess (
--tokens 256, ...,--tokens 4096) and the 8192 bucket one shape per process (--case 8192,N,K,Nfor the14 default shapes), with pauses between runs; every row is one shape at one bucket, so the parts were merged in the
tuner's own order under one header. 112 rows (the same shape/bucket keys as the 5.6.0 table), 79 with a solution,
33
default.Validation
RX 6900 XT 16 GB (gfx1030), Ryzen 9 5950X, 128 GB DDR4, Arch Linux; engine 0.1.45.3 (
e88ee39d), the rx6900 package of#3329 (rocBLAS 5.4.0.ad84daa81c from
rocm[libraries,devel]==7.13.0a20260515).Passed
hip_prefill_rocblas_gemmbuilt from this tree against the same rocBLAS,STRATA_HIP_PROMPT_F16=1:STRATA_ROCBLAS_TUNING=tools/hip/gfx1030-rocblas-5.4.0.ad84daa81c.txtand=tools/hip(the engine's own pick): 4 of4 cases PASS, "outputs match hipBLASEx within FP16 rounding" (relative_l2 0.000208, max_abs 0.00196, 4 ulp = 0.0156),
exit 0. With the 5.6.0 table: "tuning table rejected: rocBLAS version mismatch: file=5.6.0.8d1ae90e
runtime=5.4.0.ad84daa81c", exit 0.
The engine with the table:
prefill gemm: rocBLAS tuning enabled (112 rows, 79 with a solution, gfx1030, rocBLAS 5.4.0.ad84daa81c).A/B on the server, UD-Q4_K_XL, the same settings in both arms except
STRATA_ROCBLAS_TUNING=tools/hip(
STRATA_HIP_PROMPT_F16=1 STRATA_SH_STREAM=1 STRATA_ROUTE_TAIL_SKIP=7 STRATA_PREFILL_CPU_SHARE=auto STRATA_HIP_ADAPT_KERNEL_COPY=1,--resident-budget-gib 71 --pcie-frac 0.35 --mtp-draft-vocab data/draft_vocab_en.bin --kv int8 --kv-resident 32768 --max-context 131072 --spec 4). Arms in the order without, with, with, without, each ona fresh server; per arm 3 rounds of a fresh prompt, a follow-up on it and a fresh longer prompt, different text per
round, the same text in both arms. Server prompt times in ms:
The first value of each arm is the first request after the load (not a stable measurement); the 5531 is one slow
request in the table arm.
Failed
Not run
shapes against hipBLASEx; every chosen solution passed the tuner's own check against the default kernel's output).
Limits
STRATA_ROCBLAS_TUNINGset by hand until the packages carry thetools/hiptables.Measured and written with Claude Code.
🤖 Generated with Claude Code
https://claude.ai/code/session_012oqtnhtRwYGZ7yDfoVULrX
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.