Skip to content

Commit 7087aeb

Browse files
committed
anti bsod only for nvidia
1 parent 67e0072 commit 7087aeb

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

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

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3286,7 +3286,12 @@ static vk_device ggml_vk_get_device(size_t idx) {
32863286

32873287
const char* GGML_VK_DISABLE_HOST_VISIBLE_VIDMEM = getenv("GGML_VK_DISABLE_HOST_VISIBLE_VIDMEM");
32883288
//device->disable_host_visible_vidmem = GGML_VK_DISABLE_HOST_VISIBLE_VIDMEM != nullptr;
3289-
device->disable_host_visible_vidmem = true; //kcpp requested fix for vulkan BSOD
3289+
vk::PhysicalDeviceProperties tmpprops = device->physical_device.getProperties();
3290+
if(tmpprops.vendorID == VK_VENDOR_ID_NVIDIA)
3291+
{
3292+
printf("Apply NVIDIA Anti-BSOD Fix for KCPP\n");
3293+
device->disable_host_visible_vidmem = true; //kcpp requested fix for vulkan BSOD on Nvidia
3294+
}
32903295

32913296
bool fp16_storage = false;
32923297
bool fp16_compute = false;

0 commit comments

Comments
 (0)