]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
vulkan: use medium matmul tile on Asahi Linux (#24306)
authorKevin Liu <redacted>
Thu, 11 Jun 2026 13:43:04 +0000 (09:43 -0400)
committerGitHub <redacted>
Thu, 11 Jun 2026 13:43:04 +0000 (15:43 +0200)
* vulkan: use medium matmul tile on Asahi Linux

* vulkan: switch Apple detection to Honeykrisp driver id

ggml/src/ggml-vulkan/ggml-vulkan.cpp

index 387826b6d932255393a4073c9baf56acd7ffaeb6..47533c2ba97cf0349b7099446d882903668bf015 100644 (file)
@@ -6202,6 +6202,17 @@ static vk_device ggml_vk_get_device(size_t idx) {
                 break;
             }
 
+            // Honeykrisp driver for Asahi Linux doesn't report VK_VENDOR_ID_APPLE.
+            // Check for Honeykrisp driver and force same configuration as the VK_VENDOR_ID_APPLE case.
+            if (device->driver_id == vk::DriverId::eMesaHoneykrisp) {
+                device->mul_mat_l[i] = false;
+                device->mul_mat_m[i] = true;
+                device->mul_mat_s[i] = false;
+                device->mul_mat_id_l[i] = false;
+                device->mul_mat_id_m[i] = true;
+                device->mul_mat_id_s[i] = false;
+            }
+
             device->mul_mat_l_int[i]    = device->mul_mat_l[i];
             device->mul_mat_m_int[i]    = device->mul_mat_m[i];
             device->mul_mat_s_int[i]    = device->mul_mat_s[i];