Repository navigation
Releases
Releases · Trecto34/llama-inkling2-vulkan
Inkling-2-Mini Vulkan Build (v0.2 — Fused Vulkan Shaders: 432.7 t/s pp512, 47.1 t/s tg128)
What's new in v0.2-vulkan (commit e734ca0)
Five custom fused Vulkan shaders + graph optimizations for Thinking Machines Lab's Inkling-2-Mini (inkling2), verified 12/12 passing in test-backend-ops (Vulkan0 vs CPU) and bit-for-bit identical greedy output:
situ.comp(GGML_GLU_OP_SITU) — replaces the 11-opLLM_FFN_SITUchain with 1 dispatch reading non-contiguousgate_upviews directly (48/48 hits).inkling_clip.comp(INKLING_CLIP) — fuses the 8-op L2-norm clip chain on Q/K/R into 1 workgroup reduction (144/144 hits).inkling_loop_gate.comp(INKLING_LOOP_GATE) — fuses the 6-op loop controller gate(1 - tanh(f))*cur + tanh(g)*msg(96/96 hits).inkling_mix_weighted.comp(INKLING_MIX_WEIGHTED) — coalesced weighted sum directly from untransposed states + scores, eliminatingCONT(TRANSPOSE)and 2.5–6.7 GFLOPSk=2..5MUL_MAT_VECduring prefill (108/108 hits, ~160 ms → 9.5 ms).inkling_rel_bias.comp(INKLING_REL_BIAS) — fusedtable[rel_pos] - sinksgather directly into FlashAttention layout, eliminatingSUB+ 2×CONT(PERMUTE)+GET_ROWSover ~3.6 GB during prefill (48/48 hits, ~150 ms → 11.8 ms).- Graph caching: caches
blocks_normed, chunks looped-core bank queries ton ≤ 8(MUL_MAT_VECfast path), and skips redundant decodeREPEAT/CONT.
Also includes all v0.1-vulkan fixes (Unsloth ffn_gate_up_exps.scale loading + zero CPU graph splits).
Benchmarks — AMD BC-250 (RADV GFX1013, 40 CUs, Inkling-2-Mini-UD-IQ3_XXS.gguf, -ngl 99 -fa 1)
| Build | pp512 (t/s) |
tg128 (t/s) |
|---|---|---|
Unpatched PR #32695 (+ .scale fix) |
259.13 | 23.55 |
v0.1-vulkan (d4163d3) |
317.83 | 38.67 |
v0.2-vulkan (e734ca0) |
432.68 (+67.0%) | 47.14 (+100.2% / 2.0×) |
Build / Runtime Info
- Target: Linux
x86_64,-DGGML_VULKAN=ON -DBUILD_SHARED_LIBS=OFF -DCMAKE_BUILD_TYPE=Release - Included binaries:
llama-server,llama-cli,llama-bench - Runtime libs: built on Arch/CachyOS (
glibc 2.44,libvulkan.so.1,libgomp.so.1,libssl/libcrypto).
Inkling-2-Mini Vulkan Build (v0.1 — .scale + SITU Graph-Split Fix)
Pre-built Linux x86_64 Vulkan binaries (llama-server, llama-cli, llama-bench) for running Inkling-2-Mini on Vulkan GPUs.
What's Included
- Base:
danielhanchen/llama.cpprepeating-layers(PR #32695) - Fix 1 — Expert
.scaletensors: Loadffn_gate_up_exps.scaleand wire expert scales intoinkling2.cpp(PR #32657), required for Unsloth'sInkling-2-Mini-GGUF(734 tensors). - Fix 2 — Vulkan SITU graph-split fix: Make
cur/upcontiguous beforeggml_scaleinLLM_FFN_SITU, eliminating 192 GPU↔CPU graph splits per token on Vulkan (193 -> 1).
Verified Benchmarks
Tested on AMD BC-250 (RADV GFX1013, 40 CUs) with Inkling-2-Mini-UD-IQ3_XXS.gguf (-ngl 99 -fa 1):
| Test | Throughput |
|---|---|
pp512 |
317.83 t/s |
tg128 |
38.67 t/s |
Build Environment & Runtime Notes
- Target:
linux-x86_64 - CMake flags:
-DGGML_VULKAN=ON -DBUILD_SHARED_LIBS=OFF - Runtime requirements: Built against glibc 2.44; dynamically links system
libvulkan.so.1,libgomp.so.1,libssl.so.4/libcrypto.so.4, and standard C/C++ runtime libraries. Systems with an older glibc or OpenSSL SONAME should build from source.
Verification
tar -xzf llama-inkling2-vulkan-linux-x86_64.tar.gz
sha256sum -c SHA256SUMS.txt