1#ifndef HALIDE_RUNTIME_VULKAN_INTERFACE_H
2#define HALIDE_RUNTIME_VULKAN_INTERFACE_H
12#define HL_VK_ENV_DELIM ";"
14#define HL_VK_ENV_DELIM ":"
18#define VK_NO_PROTOTYPES
20#include <vulkan/vulkan.h>
73#define VULKAN_FN(fn) WEAK PFN_##fn fn = nullptr;
74#define HL_USE_VULKAN_LOADER_FNS
75#define HL_USE_VULKAN_INSTANCE_FNS
76#define HL_USE_VULKAN_DEVICE_FNS
78#undef HL_USE_VULKAN_DEVICE_FNS
79#undef HL_USE_VULKAN_INSTANCE_FNS
80#undef HL_USE_VULKAN_LOADER_FNS
87#define VULKAN_FN(fn) fn = (PFN_##fn)halide_vulkan_get_symbol(user_context, #fn);
88#define HL_USE_VULKAN_LOADER_FNS
90#undef HL_USE_VULKAN_LOADER_FNS
97#define VULKAN_FN(fn) fn = (PFN_##fn)vkGetInstanceProcAddr(instance, #fn);
98#define HL_USE_VULKAN_INSTANCE_FNS
100#undef HL_USE_VULKAN_INSTANCE_FNS
106#define VULKAN_FN(fn) fn = (PFN_##fn)(nullptr);
107#define HL_USE_VULKAN_INSTANCE_FNS
109#undef HL_USE_VULKAN_INSTANCE_FNS
116#define VULKAN_FN(fn) fn = (PFN_##fn)vkGetDeviceProcAddr(device, #fn);
117#define HL_USE_VULKAN_DEVICE_FNS
119#undef HL_USE_VULKAN_DEVICE_FNS
125#define VULKAN_FN(fn) fn = (PFN_##fn)(nullptr);
126#define HL_USE_VULKAN_DEVICE_FNS
128#undef HL_USE_VULKAN_DEVICE_FNS
void * halide_get_library_symbol(void *lib, const char *name)
void * halide_load_library(const char *name)
WEAK void * halide_vulkan_get_symbol(void *user_context, const char *name)
void WEAK vk_unload_vulkan_device_functions(void *user_context)
void WEAK vk_unload_vulkan_instance_functions(void *user_context)
void WEAK vk_load_vulkan_loader_functions(void *user_context)
void WEAK vk_load_vulkan_device_functions(void *user_context, VkDevice device)
void WEAK vk_load_vulkan_instance_functions(void *user_context, VkInstance instance)
WEAK halide_device_interface_t vulkan_device_interface
This file defines the class FunctionDAG, which is our representation of a Halide pipeline,...
Internal::ConstantInterval cast(Type t, const Internal::ConstantInterval &a)
Cast operators for ConstantIntervals.
Each GPU API provides a halide_device_interface_t struct pointing to the code that manages device all...