]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commit
vulkan: Use native e2m1 and e4m3 conversions for mxfp4/nvfp4 (#25338)
authorJeff Bolz <redacted>
Mon, 13 Jul 2026 13:44:17 +0000 (08:44 -0500)
committerGitHub <redacted>
Mon, 13 Jul 2026 13:44:17 +0000 (08:44 -0500)
commite920c523e3b8a0163fe498af5bf90df35ff51d25
tree6c91a11407a3a3fb160f5dac705f9c59718f54f1
parent259ae1df8b5277a57a5092636bfcbcbb2f753219
vulkan: Use native e2m1 and e4m3 conversions for mxfp4/nvfp4 (#25338)

This uses the new VK_EXT_shader_ocp_microscaling_types extension to do fp4 type
promotions, and also uses the float8 extension to do ue4m3 promotions for
nvfp4. It's reasonable to assume that an implementation that supports fp4 will
also support fp8, so we don't need to handle all possible combinations of
support.
ggml/src/ggml-vulkan/CMakeLists.txt
ggml/src/ggml-vulkan/ggml-vulkan.cpp
ggml/src/ggml-vulkan/vulkan-shaders/CMakeLists.txt
ggml/src/ggml-vulkan/vulkan-shaders/dequant_funcs.glsl
ggml/src/ggml-vulkan/vulkan-shaders/dequant_funcs_cm2.glsl
ggml/src/ggml-vulkan/vulkan-shaders/feature-tests/float_e2m1.comp [new file with mode: 0644]
ggml/src/ggml-vulkan/vulkan-shaders/feature-tests/float_e4m3.comp [new file with mode: 0644]
ggml/src/ggml-vulkan/vulkan-shaders/mul_mm_funcs.glsl
ggml/src/ggml-vulkan/vulkan-shaders/types.glsl
ggml/src/ggml-vulkan/vulkan-shaders/vulkan-shaders-gen.cpp