Hey folks,
I’m building an open-source LLM inference engine that runs entirely on Vulkan compute shaders — no CUDA, no ROCm/HIP, no Python. Just Rust + GLSL + SPIR-V. It’s called VulkanForge and it targets AMD RDNA4 specifically (RX 9070 XT, gfx1201):
https://github.com/maeddesg/vulkanforge
We’ve got native FP8 E4M3 inference working (SafeTensors, per-channel + per-tensor scaling), including a 14B parameter model running coherently on 16 GB VRAM. This engine is doing native FP8 over Vulkan on consumer AMD hardware.
Recently got a nice +113% prefill speedup by going from BN=16 to BN=32 tiling in our CoopMat GEMM kernel (Sprint 32 for those following the repo). But after reading through the RDNA4 ISA doc pretty carefully, I’ve got a few questions where I’m hitting the limits of what the public docs tell me. Would really appreciate any pointers from AMD engineers or anyone who’s been poking at gfx12 compute.
Our current setup:
-
VK_KHR_cooperative_matrix for WMMA, Wave64, requiredSubgroupSize=64
-
FP8 weights get converted to BF16 before WMMA (V_WMMA_F32_16X16X16_BF16), because GL_KHR_cooperative_matrix doesn’t seem to expose FP8 component types
-
Activations are FP32, loaded into LDS, then fed to coopMatLoad
-
14B decode sits at ~14 tok/s, prefill at ~338 tok/s (pp=512) after the BN=32 fix
-
FFN GEMM is at roughly 15% TFLOPS efficiency — clearly lots of room
Question 1: Native FP8 WMMA through Vulkan?
The ISA lists V_WMMA_F32_16X16X16_FP8_FP8 (Table 41) which would let us skip the FP8->BF16 conversion entirely. But VK_KHR_cooperative_matrix / GL_KHR_cooperative_matrix doesn’t seem to list float8 as a supported component type. Is there any extension (GL_AMD_, VK_EXT_, draft spec?) that exposes native FP8 cooperative matrix ops on RDNA4? Or is this something that would need ACO/Mesa work first?
This is probably our biggest potential win — we’re burning cycles on BF16 narrowing that the hardware could skip entirely.
Question 2: GLOBAL_LOAD_TR_B64 — does ACO emit this?
Section 11.6 describes GLOBAL_LOAD_TR_B64 which loads a 16×16 matrix of 8-bit data and transposes it in hardware. That’s exactly what we need for the FP8 A-matrix (weights are row-major in memory, WMMA wants column-major for A).
Right now we do: global_load → LDS store → coopMatLoad from LDS (which handles the transpose implicitly). If coopMatLoad from a buffer (not LDS) triggers GLOBAL_LOAD_TR_B64 through ACO, we could skip the entire LDS round-trip.
Does anyone know if ACO on Mesa 26.0+ actually emits GLOBAL_LOAD_TR_B64 for cooperative matrix loads? Or is it only used in specific scenarios?
Question 3: WMMA issue rate on gfx1201?
The ISA says WMMA takes 32 clocks of “optimal work scheduling” (from the RDNA3 blog, not sure if RDNA4 is the same). For back-of-envelope roofline calculations: what’s the actual throughput of V_WMMA_F32_16X16X16_FP8_FP8 on gfx1201? Is it 1 WMMA per 32 cycles per SIMD? Per CU? The matrix instruction calculator on GitHub seems to cover RDNA3 but I haven’t found gfx12 configs yet.
Question 4: L2 cache size on RX 9070 XT (gfx1201)?
Can’t find this in the ISA or any public spec sheet. We’re seeing what looks like L2 thrashing on large models (14B = 13.8 GB resident) — standalone kernel benchmarks hit 685 GB/s but in-context (after 1200 dispatches reading through the full model) we see significantly lower effective bandwidth. Knowing the L2 size would help us understand if prefetch strategies make any sense or if we’re just bandwidth-bound at that working set size.
Question 5: Wave64 vs Wave32 for WMMA performance?
We’re pinned to Wave64 (requiredSubgroupSize=64) across all our shaders. The ISA shows that WMMA VGPR layouts differ between Wave32 and Wave64 — and GLOBAL_LOAD_TR uses “only addresses from lanes 0-31” even in Wave64 mode. Are we leaving performance on the table by running WMMA in Wave64? Or does Wave64 have compensating advantages (more lanes for non-WMMA work between tiles)?
For context on the profiling journey: we spent 5 sprints (26-31) chasing a decode performance gap that turned out to be a runtime-state interaction at the driver level, not anything we could fix in the shader. Filed a Mesa bug report for an intermittent ring timeout on 26.1-rc3 too. RGP captures available if any of that’s useful.
Happy to share RGP traces, shader SPVs, or any other data that would help answer these. And if any of this is useful feedback for the Mesa/RADV/ACO teams, happy to file issues or test patches.
Cheers,
Matthias
Links: