llama.cpp
adf554d2 - vulkan: make the radix top-k tie selection deterministic (#31931)

Commit
1 hour ago
vulkan: make the radix top-k tie selection deterministic (#31931) * vulkan: make the radix top-k tie selection deterministic The radix select gathers the elements above the threshold and the ties with an atomic counter, so with more ties than remaining slots the kept columns depend on the thread scheduling. Each subgroup now owns a contiguous chunk of the row with the same column mapping in every pass, counts its kept elements, and writes them at ranks from a scan of the subgroup totals; overflowing ties are ranked in column order with a ballot, so the lowest tied columns win, as on CUDA and Metal. The radix pipelines require subgroup arithmetic, ballot and full subgroups. Enable the deterministic top-k check on Vulkan. * optimize shader for AMD, Intel and Nvidia --------- Co-authored-by: Ruben Ortlam <rortlam@redhat.com>
Parents
Loading