Skip to content

UPSTREAM PR #21787: vulkan: fix output corruption on GCN 2.0/3.0 (Vulkan 1.2)#1345

Open
loci-dev wants to merge 1 commit intomainfrom
loci/pr-21787-fix-vulkan-gcn2-sync
Open

UPSTREAM PR #21787: vulkan: fix output corruption on GCN 2.0/3.0 (Vulkan 1.2)#1345
loci-dev wants to merge 1 commit intomainfrom
loci/pr-21787-fix-vulkan-gcn2-sync

Conversation

@loci-dev
Copy link
Copy Markdown

Note

Source pull request: ggml-org/llama.cpp#21787

Overview

This PR resolves output corruption (token repetition/double-wording) on legacy AMD GCN 2.0 and 3.0 hardware (e.g., R9 390, Fury X).

The issue was introduced in b8394 due to the implementation of modern Vulkan synchronization primitives that are not fully supported by the final legacy Adrenalin drivers (Vulkan 1.2.170). By restoring backward-compatible memory barrier logic in ggml-vulkan.cpp, we restore coherent generation for these cards without regressing performance on modern Vulkan 1.3+ hardware.

Additional information

  • Hardware Tested: Radeon R9 390 (8GB VRAM) on Windows 10.

  • Performance: Verified 22.0 t/s using gemma-4-E4B-it-Q4_K_M.gguf with 100% GPU offload.

  • Context: Many legacy 8GB cards are still highly capable for inference in 2026, but are limited by driver-level Vulkan support. This fix ensures continued accessibility for users on vintage or budget-restricted hardware.

Requirements

@loci-review
Copy link
Copy Markdown

loci-review Bot commented Apr 12, 2026

No meaningful performance changes were detected across 126809 analyzed functions in the following binaries: build.bin.llama-bench, build.bin.libmtmd.so, build.bin.llama-cvector-generator, build.bin.llama-tts, build.bin.libllama.so, build.bin.llama-quantize, build.bin.llama-qwen2vl-cli, build.bin.llama-tokenize, build.bin.llama-gemma3-cli, build.bin.llama-gguf-split, build.bin.llama-llava-cli, build.bin.llama-minicpmv-cli, build.bin.libggml-base.so, build.bin.libggml-cpu.so, build.bin.libggml.so.

💬 Questions? Tag @loci-dev

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants