blob: 5a9abf17596930df3e26cf5f257ecedfd58297f6 [file] [log] [blame]
Jon Ashburnd55a3942015-05-06 09:02:10 -06001/*
Jon Ashburnd55a3942015-05-06 09:02:10 -06002 *
Jon Ashburn23d36b12016-02-02 17:47:28 -07003 * Copyright (c) 2015-2016 The Khronos Group Inc.
4 * Copyright (c) 2015-2016 Valve Corporation
5 * Copyright (c) 2015-2016 LunarG, Inc.
6 * Copyright (C) 2016 Google Inc.
Jon Ashburnd55a3942015-05-06 09:02:10 -06007 *
Jon Ashburn3ebf1252016-04-19 11:30:31 -06008 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
Jon Ashburnd55a3942015-05-06 09:02:10 -060011 *
Jon Ashburn3ebf1252016-04-19 11:30:31 -060012 * http://www.apache.org/licenses/LICENSE-2.0
Jon Ashburnd55a3942015-05-06 09:02:10 -060013 *
Jon Ashburn3ebf1252016-04-19 11:30:31 -060014 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
Jon Ashburn23d36b12016-02-02 17:47:28 -070019 *
20 * Author: Courtney Goeltzenleuchter <courtney@lunarg.com>
Courtney Goeltzenleuchter05559522015-10-30 11:14:30 -060021 * Author: Jon Ashburn <jon@lunarg.com>
Jon Ashburn23d36b12016-02-02 17:47:28 -070022 * Author: Ian Elliott <ian@LunarG.com>
Courtney Goeltzenleuchter05559522015-10-30 11:14:30 -060023 * Author: Tony Barbour <tony@LunarG.com>
Jon Ashburnd55a3942015-05-06 09:02:10 -060024 */
25
David Pinedo9316d3b2015-11-06 12:54:48 -070026#include <vulkan/vulkan.h>
27#include <vulkan/vk_layer.h>
Jon Ashburnd55a3942015-05-06 09:02:10 -060028#include <string.h>
Jon Ashburn27cd5842015-05-12 17:26:48 -060029#include "loader.h"
Tobin Ehlisb835d1b2015-07-03 10:34:49 -060030#include "vk_loader_platform.h"
Jon Ashburnd55a3942015-05-06 09:02:10 -060031
Jon Ashburn23d36b12016-02-02 17:47:28 -070032static VkResult vkDevExtError(VkDevice dev) {
Jon Ashburn2e37d752016-02-12 08:20:06 -070033 struct loader_device *found_dev;
34 struct loader_icd *icd = loader_get_icd_and_device(dev, &found_dev);
35
36 if (icd)
37 loader_log(icd->this_instance, VK_DEBUG_REPORT_ERROR_BIT_EXT, 0,
38 "Bad destination in loader trampoline dispatch,"
39 "Are layers and extensions that you are calling enabled?");
40 return VK_ERROR_EXTENSION_NOT_PRESENT;
Jon Ashburnfc1031e2015-11-17 15:31:02 -070041}
42
Jon Ashburn23d36b12016-02-02 17:47:28 -070043static inline void
44loader_init_device_dispatch_table(struct loader_dev_dispatch_table *dev_table,
45 PFN_vkGetDeviceProcAddr gpa, VkDevice dev) {
Jon Ashburnfc1031e2015-11-17 15:31:02 -070046 VkLayerDispatchTable *table = &dev_table->core_dispatch;
47 for (uint32_t i = 0; i < MAX_NUM_DEV_EXTS; i++)
Jon Ashburn23d36b12016-02-02 17:47:28 -070048 dev_table->ext_dispatch.DevExt[i] = (PFN_vkDevExt)vkDevExtError;
Jon Ashburn8fd08252015-05-28 16:25:02 -060049
Jon Ashburn23d36b12016-02-02 17:47:28 -070050 table->GetDeviceProcAddr =
51 (PFN_vkGetDeviceProcAddr)gpa(dev, "vkGetDeviceProcAddr");
52 table->DestroyDevice = (PFN_vkDestroyDevice)gpa(dev, "vkDestroyDevice");
53 table->GetDeviceQueue = (PFN_vkGetDeviceQueue)gpa(dev, "vkGetDeviceQueue");
54 table->QueueSubmit = (PFN_vkQueueSubmit)gpa(dev, "vkQueueSubmit");
55 table->QueueWaitIdle = (PFN_vkQueueWaitIdle)gpa(dev, "vkQueueWaitIdle");
56 table->DeviceWaitIdle = (PFN_vkDeviceWaitIdle)gpa(dev, "vkDeviceWaitIdle");
57 table->AllocateMemory = (PFN_vkAllocateMemory)gpa(dev, "vkAllocateMemory");
58 table->FreeMemory = (PFN_vkFreeMemory)gpa(dev, "vkFreeMemory");
59 table->MapMemory = (PFN_vkMapMemory)gpa(dev, "vkMapMemory");
60 table->UnmapMemory = (PFN_vkUnmapMemory)gpa(dev, "vkUnmapMemory");
61 table->FlushMappedMemoryRanges =
62 (PFN_vkFlushMappedMemoryRanges)gpa(dev, "vkFlushMappedMemoryRanges");
63 table->InvalidateMappedMemoryRanges =
64 (PFN_vkInvalidateMappedMemoryRanges)gpa(
65 dev, "vkInvalidateMappedMemoryRanges");
66 table->GetDeviceMemoryCommitment = (PFN_vkGetDeviceMemoryCommitment)gpa(
67 dev, "vkGetDeviceMemoryCommitment");
68 table->GetImageSparseMemoryRequirements =
69 (PFN_vkGetImageSparseMemoryRequirements)gpa(
70 dev, "vkGetImageSparseMemoryRequirements");
71 table->GetBufferMemoryRequirements = (PFN_vkGetBufferMemoryRequirements)gpa(
72 dev, "vkGetBufferMemoryRequirements");
73 table->GetImageMemoryRequirements = (PFN_vkGetImageMemoryRequirements)gpa(
74 dev, "vkGetImageMemoryRequirements");
75 table->BindBufferMemory =
76 (PFN_vkBindBufferMemory)gpa(dev, "vkBindBufferMemory");
77 table->BindImageMemory =
78 (PFN_vkBindImageMemory)gpa(dev, "vkBindImageMemory");
79 table->QueueBindSparse =
80 (PFN_vkQueueBindSparse)gpa(dev, "vkQueueBindSparse");
81 table->CreateFence = (PFN_vkCreateFence)gpa(dev, "vkCreateFence");
82 table->DestroyFence = (PFN_vkDestroyFence)gpa(dev, "vkDestroyFence");
83 table->ResetFences = (PFN_vkResetFences)gpa(dev, "vkResetFences");
84 table->GetFenceStatus = (PFN_vkGetFenceStatus)gpa(dev, "vkGetFenceStatus");
85 table->WaitForFences = (PFN_vkWaitForFences)gpa(dev, "vkWaitForFences");
86 table->CreateSemaphore =
87 (PFN_vkCreateSemaphore)gpa(dev, "vkCreateSemaphore");
88 table->DestroySemaphore =
89 (PFN_vkDestroySemaphore)gpa(dev, "vkDestroySemaphore");
90 table->CreateEvent = (PFN_vkCreateEvent)gpa(dev, "vkCreateEvent");
91 table->DestroyEvent = (PFN_vkDestroyEvent)gpa(dev, "vkDestroyEvent");
92 table->GetEventStatus = (PFN_vkGetEventStatus)gpa(dev, "vkGetEventStatus");
93 table->SetEvent = (PFN_vkSetEvent)gpa(dev, "vkSetEvent");
94 table->ResetEvent = (PFN_vkResetEvent)gpa(dev, "vkResetEvent");
95 table->CreateQueryPool =
96 (PFN_vkCreateQueryPool)gpa(dev, "vkCreateQueryPool");
97 table->DestroyQueryPool =
98 (PFN_vkDestroyQueryPool)gpa(dev, "vkDestroyQueryPool");
99 table->GetQueryPoolResults =
100 (PFN_vkGetQueryPoolResults)gpa(dev, "vkGetQueryPoolResults");
101 table->CreateBuffer = (PFN_vkCreateBuffer)gpa(dev, "vkCreateBuffer");
102 table->DestroyBuffer = (PFN_vkDestroyBuffer)gpa(dev, "vkDestroyBuffer");
103 table->CreateBufferView =
104 (PFN_vkCreateBufferView)gpa(dev, "vkCreateBufferView");
105 table->DestroyBufferView =
106 (PFN_vkDestroyBufferView)gpa(dev, "vkDestroyBufferView");
107 table->CreateImage = (PFN_vkCreateImage)gpa(dev, "vkCreateImage");
108 table->DestroyImage = (PFN_vkDestroyImage)gpa(dev, "vkDestroyImage");
109 table->GetImageSubresourceLayout = (PFN_vkGetImageSubresourceLayout)gpa(
110 dev, "vkGetImageSubresourceLayout");
111 table->CreateImageView =
112 (PFN_vkCreateImageView)gpa(dev, "vkCreateImageView");
113 table->DestroyImageView =
114 (PFN_vkDestroyImageView)gpa(dev, "vkDestroyImageView");
115 table->CreateShaderModule =
116 (PFN_vkCreateShaderModule)gpa(dev, "vkCreateShaderModule");
117 table->DestroyShaderModule =
118 (PFN_vkDestroyShaderModule)gpa(dev, "vkDestroyShaderModule");
119 table->CreatePipelineCache =
120 (PFN_vkCreatePipelineCache)gpa(dev, "vkCreatePipelineCache");
121 table->DestroyPipelineCache =
122 (PFN_vkDestroyPipelineCache)gpa(dev, "vkDestroyPipelineCache");
123 table->GetPipelineCacheData =
124 (PFN_vkGetPipelineCacheData)gpa(dev, "vkGetPipelineCacheData");
125 table->MergePipelineCaches =
126 (PFN_vkMergePipelineCaches)gpa(dev, "vkMergePipelineCaches");
127 table->CreateGraphicsPipelines =
128 (PFN_vkCreateGraphicsPipelines)gpa(dev, "vkCreateGraphicsPipelines");
129 table->CreateComputePipelines =
130 (PFN_vkCreateComputePipelines)gpa(dev, "vkCreateComputePipelines");
131 table->DestroyPipeline =
132 (PFN_vkDestroyPipeline)gpa(dev, "vkDestroyPipeline");
133 table->CreatePipelineLayout =
134 (PFN_vkCreatePipelineLayout)gpa(dev, "vkCreatePipelineLayout");
135 table->DestroyPipelineLayout =
136 (PFN_vkDestroyPipelineLayout)gpa(dev, "vkDestroyPipelineLayout");
137 table->CreateSampler = (PFN_vkCreateSampler)gpa(dev, "vkCreateSampler");
138 table->DestroySampler = (PFN_vkDestroySampler)gpa(dev, "vkDestroySampler");
139 table->CreateDescriptorSetLayout = (PFN_vkCreateDescriptorSetLayout)gpa(
140 dev, "vkCreateDescriptorSetLayout");
141 table->DestroyDescriptorSetLayout = (PFN_vkDestroyDescriptorSetLayout)gpa(
142 dev, "vkDestroyDescriptorSetLayout");
143 table->CreateDescriptorPool =
144 (PFN_vkCreateDescriptorPool)gpa(dev, "vkCreateDescriptorPool");
145 table->DestroyDescriptorPool =
146 (PFN_vkDestroyDescriptorPool)gpa(dev, "vkDestroyDescriptorPool");
147 table->ResetDescriptorPool =
148 (PFN_vkResetDescriptorPool)gpa(dev, "vkResetDescriptorPool");
149 table->AllocateDescriptorSets =
150 (PFN_vkAllocateDescriptorSets)gpa(dev, "vkAllocateDescriptorSets");
151 table->FreeDescriptorSets =
152 (PFN_vkFreeDescriptorSets)gpa(dev, "vkFreeDescriptorSets");
153 table->UpdateDescriptorSets =
154 (PFN_vkUpdateDescriptorSets)gpa(dev, "vkUpdateDescriptorSets");
155 table->CreateFramebuffer =
156 (PFN_vkCreateFramebuffer)gpa(dev, "vkCreateFramebuffer");
157 table->DestroyFramebuffer =
158 (PFN_vkDestroyFramebuffer)gpa(dev, "vkDestroyFramebuffer");
159 table->CreateRenderPass =
160 (PFN_vkCreateRenderPass)gpa(dev, "vkCreateRenderPass");
161 table->DestroyRenderPass =
162 (PFN_vkDestroyRenderPass)gpa(dev, "vkDestroyRenderPass");
163 table->GetRenderAreaGranularity =
164 (PFN_vkGetRenderAreaGranularity)gpa(dev, "vkGetRenderAreaGranularity");
165 table->CreateCommandPool =
166 (PFN_vkCreateCommandPool)gpa(dev, "vkCreateCommandPool");
167 table->DestroyCommandPool =
168 (PFN_vkDestroyCommandPool)gpa(dev, "vkDestroyCommandPool");
169 table->ResetCommandPool =
170 (PFN_vkResetCommandPool)gpa(dev, "vkResetCommandPool");
171 table->AllocateCommandBuffers =
172 (PFN_vkAllocateCommandBuffers)gpa(dev, "vkAllocateCommandBuffers");
173 table->FreeCommandBuffers =
174 (PFN_vkFreeCommandBuffers)gpa(dev, "vkFreeCommandBuffers");
175 table->BeginCommandBuffer =
176 (PFN_vkBeginCommandBuffer)gpa(dev, "vkBeginCommandBuffer");
177 table->EndCommandBuffer =
178 (PFN_vkEndCommandBuffer)gpa(dev, "vkEndCommandBuffer");
179 table->ResetCommandBuffer =
180 (PFN_vkResetCommandBuffer)gpa(dev, "vkResetCommandBuffer");
181 table->CmdBindPipeline =
182 (PFN_vkCmdBindPipeline)gpa(dev, "vkCmdBindPipeline");
183 table->CmdSetViewport = (PFN_vkCmdSetViewport)gpa(dev, "vkCmdSetViewport");
184 table->CmdSetScissor = (PFN_vkCmdSetScissor)gpa(dev, "vkCmdSetScissor");
185 table->CmdSetLineWidth =
186 (PFN_vkCmdSetLineWidth)gpa(dev, "vkCmdSetLineWidth");
187 table->CmdSetDepthBias =
188 (PFN_vkCmdSetDepthBias)gpa(dev, "vkCmdSetDepthBias");
189 table->CmdSetBlendConstants =
190 (PFN_vkCmdSetBlendConstants)gpa(dev, "vkCmdSetBlendConstants");
191 table->CmdSetDepthBounds =
192 (PFN_vkCmdSetDepthBounds)gpa(dev, "vkCmdSetDepthBounds");
193 table->CmdSetStencilCompareMask =
194 (PFN_vkCmdSetStencilCompareMask)gpa(dev, "vkCmdSetStencilCompareMask");
195 table->CmdSetStencilWriteMask =
196 (PFN_vkCmdSetStencilWriteMask)gpa(dev, "vkCmdSetStencilWriteMask");
197 table->CmdSetStencilReference =
198 (PFN_vkCmdSetStencilReference)gpa(dev, "vkCmdSetStencilReference");
199 table->CmdBindDescriptorSets =
200 (PFN_vkCmdBindDescriptorSets)gpa(dev, "vkCmdBindDescriptorSets");
201 table->CmdBindVertexBuffers =
202 (PFN_vkCmdBindVertexBuffers)gpa(dev, "vkCmdBindVertexBuffers");
203 table->CmdBindIndexBuffer =
204 (PFN_vkCmdBindIndexBuffer)gpa(dev, "vkCmdBindIndexBuffer");
205 table->CmdDraw = (PFN_vkCmdDraw)gpa(dev, "vkCmdDraw");
206 table->CmdDrawIndexed = (PFN_vkCmdDrawIndexed)gpa(dev, "vkCmdDrawIndexed");
207 table->CmdDrawIndirect =
208 (PFN_vkCmdDrawIndirect)gpa(dev, "vkCmdDrawIndirect");
209 table->CmdDrawIndexedIndirect =
210 (PFN_vkCmdDrawIndexedIndirect)gpa(dev, "vkCmdDrawIndexedIndirect");
211 table->CmdDispatch = (PFN_vkCmdDispatch)gpa(dev, "vkCmdDispatch");
212 table->CmdDispatchIndirect =
213 (PFN_vkCmdDispatchIndirect)gpa(dev, "vkCmdDispatchIndirect");
214 table->CmdCopyBuffer = (PFN_vkCmdCopyBuffer)gpa(dev, "vkCmdCopyBuffer");
215 table->CmdCopyImage = (PFN_vkCmdCopyImage)gpa(dev, "vkCmdCopyImage");
216 table->CmdBlitImage = (PFN_vkCmdBlitImage)gpa(dev, "vkCmdBlitImage");
217 table->CmdCopyBufferToImage =
218 (PFN_vkCmdCopyBufferToImage)gpa(dev, "vkCmdCopyBufferToImage");
219 table->CmdCopyImageToBuffer =
220 (PFN_vkCmdCopyImageToBuffer)gpa(dev, "vkCmdCopyImageToBuffer");
221 table->CmdUpdateBuffer =
222 (PFN_vkCmdUpdateBuffer)gpa(dev, "vkCmdUpdateBuffer");
223 table->CmdFillBuffer = (PFN_vkCmdFillBuffer)gpa(dev, "vkCmdFillBuffer");
224 table->CmdClearColorImage =
225 (PFN_vkCmdClearColorImage)gpa(dev, "vkCmdClearColorImage");
226 table->CmdClearDepthStencilImage = (PFN_vkCmdClearDepthStencilImage)gpa(
227 dev, "vkCmdClearDepthStencilImage");
228 table->CmdClearAttachments =
229 (PFN_vkCmdClearAttachments)gpa(dev, "vkCmdClearAttachments");
230 table->CmdResolveImage =
231 (PFN_vkCmdResolveImage)gpa(dev, "vkCmdResolveImage");
232 table->CmdSetEvent = (PFN_vkCmdSetEvent)gpa(dev, "vkCmdSetEvent");
233 table->CmdResetEvent = (PFN_vkCmdResetEvent)gpa(dev, "vkCmdResetEvent");
234 table->CmdWaitEvents = (PFN_vkCmdWaitEvents)gpa(dev, "vkCmdWaitEvents");
235 table->CmdPipelineBarrier =
236 (PFN_vkCmdPipelineBarrier)gpa(dev, "vkCmdPipelineBarrier");
237 table->CmdBeginQuery = (PFN_vkCmdBeginQuery)gpa(dev, "vkCmdBeginQuery");
238 table->CmdEndQuery = (PFN_vkCmdEndQuery)gpa(dev, "vkCmdEndQuery");
239 table->CmdResetQueryPool =
240 (PFN_vkCmdResetQueryPool)gpa(dev, "vkCmdResetQueryPool");
241 table->CmdWriteTimestamp =
242 (PFN_vkCmdWriteTimestamp)gpa(dev, "vkCmdWriteTimestamp");
243 table->CmdCopyQueryPoolResults =
244 (PFN_vkCmdCopyQueryPoolResults)gpa(dev, "vkCmdCopyQueryPoolResults");
245 table->CmdPushConstants =
246 (PFN_vkCmdPushConstants)gpa(dev, "vkCmdPushConstants");
247 table->CmdBeginRenderPass =
248 (PFN_vkCmdBeginRenderPass)gpa(dev, "vkCmdBeginRenderPass");
249 table->CmdNextSubpass = (PFN_vkCmdNextSubpass)gpa(dev, "vkCmdNextSubpass");
250 table->CmdEndRenderPass =
251 (PFN_vkCmdEndRenderPass)gpa(dev, "vkCmdEndRenderPass");
252 table->CmdExecuteCommands =
253 (PFN_vkCmdExecuteCommands)gpa(dev, "vkCmdExecuteCommands");
Jon Ashburn232e3af2015-11-30 17:21:25 -0700254}
255
Jon Ashburn23d36b12016-02-02 17:47:28 -0700256static inline void loader_init_device_extension_dispatch_table(
257 struct loader_dev_dispatch_table *dev_table, PFN_vkGetDeviceProcAddr gpa,
258 VkDevice dev) {
Jon Ashburn232e3af2015-11-30 17:21:25 -0700259 VkLayerDispatchTable *table = &dev_table->core_dispatch;
Jon Ashburn23d36b12016-02-02 17:47:28 -0700260 table->AcquireNextImageKHR =
261 (PFN_vkAcquireNextImageKHR)gpa(dev, "vkAcquireNextImageKHR");
262 table->CreateSwapchainKHR =
263 (PFN_vkCreateSwapchainKHR)gpa(dev, "vkCreateSwapchainKHR");
264 table->DestroySwapchainKHR =
265 (PFN_vkDestroySwapchainKHR)gpa(dev, "vkDestroySwapchainKHR");
266 table->GetSwapchainImagesKHR =
267 (PFN_vkGetSwapchainImagesKHR)gpa(dev, "vkGetSwapchainImagesKHR");
268 table->QueuePresentKHR =
269 (PFN_vkQueuePresentKHR)gpa(dev, "vkQueuePresentKHR");
Mark Lobodzinski0853ad52016-08-29 14:54:34 -0600270 table->CmdDrawIndirectCountAMD =
271 (PFN_vkCmdDrawIndirectCountAMD)gpa(dev, "vkCmdDrawIndirectCountAMD");
272 table->CmdDrawIndexedIndirectCountAMD =
273 (PFN_vkCmdDrawIndexedIndirectCountAMD)gpa(
274 dev, "vkCmdDrawIndexedIndirectCountAMD");
Mark Lobodzinski5f208522016-08-29 15:36:23 -0600275#ifdef VK_USE_PLATFORM_WIN32_KHR
276 table->GetMemoryWin32HandleNV =
277 (PFN_vkGetMemoryWin32HandleNV)gpa(dev, "vkGetMemoryWin32HandleNV");
278#endif // VK_USE_PLATFORM_WIN32_KHR
Jon Ashburnd55a3942015-05-06 09:02:10 -0600279}
280
Jon Ashburn23d36b12016-02-02 17:47:28 -0700281static inline void *
282loader_lookup_device_dispatch_table(const VkLayerDispatchTable *table,
283 const char *name) {
Jon Ashburnd55a3942015-05-06 09:02:10 -0600284 if (!name || name[0] != 'v' || name[1] != 'k')
285 return NULL;
286
287 name += 2;
Jon Ashburn8d1b0b52015-05-18 13:20:15 -0600288 if (!strcmp(name, "GetDeviceProcAddr"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700289 return (void *)table->GetDeviceProcAddr;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600290 if (!strcmp(name, "DestroyDevice"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700291 return (void *)table->DestroyDevice;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600292 if (!strcmp(name, "GetDeviceQueue"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700293 return (void *)table->GetDeviceQueue;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600294 if (!strcmp(name, "QueueSubmit"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700295 return (void *)table->QueueSubmit;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600296 if (!strcmp(name, "QueueWaitIdle"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700297 return (void *)table->QueueWaitIdle;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600298 if (!strcmp(name, "DeviceWaitIdle"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700299 return (void *)table->DeviceWaitIdle;
Chia-I Wu3432a0c2015-10-27 18:04:07 +0800300 if (!strcmp(name, "AllocateMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700301 return (void *)table->AllocateMemory;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600302 if (!strcmp(name, "FreeMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700303 return (void *)table->FreeMemory;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600304 if (!strcmp(name, "MapMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700305 return (void *)table->MapMemory;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600306 if (!strcmp(name, "UnmapMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700307 return (void *)table->UnmapMemory;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600308 if (!strcmp(name, "FlushMappedMemoryRanges"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700309 return (void *)table->FlushMappedMemoryRanges;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600310 if (!strcmp(name, "InvalidateMappedMemoryRanges"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700311 return (void *)table->InvalidateMappedMemoryRanges;
Courtney Goeltzenleuchterfb71f222015-07-09 21:57:28 -0600312 if (!strcmp(name, "GetDeviceMemoryCommitment"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700313 return (void *)table->GetDeviceMemoryCommitment;
Jon Ashburn754864f2015-07-23 18:49:07 -0600314 if (!strcmp(name, "GetImageSparseMemoryRequirements"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700315 return (void *)table->GetImageSparseMemoryRequirements;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600316 if (!strcmp(name, "GetBufferMemoryRequirements"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700317 return (void *)table->GetBufferMemoryRequirements;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600318 if (!strcmp(name, "GetImageMemoryRequirements"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700319 return (void *)table->GetImageMemoryRequirements;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600320 if (!strcmp(name, "BindBufferMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700321 return (void *)table->BindBufferMemory;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600322 if (!strcmp(name, "BindImageMemory"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700323 return (void *)table->BindImageMemory;
Chia-I Wu1ff4c3d2015-10-26 16:55:27 +0800324 if (!strcmp(name, "QueueBindSparse"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700325 return (void *)table->QueueBindSparse;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600326 if (!strcmp(name, "CreateFence"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700327 return (void *)table->CreateFence;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600328 if (!strcmp(name, "DestroyFence"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700329 return (void *)table->DestroyFence;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600330 if (!strcmp(name, "ResetFences"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700331 return (void *)table->ResetFences;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600332 if (!strcmp(name, "GetFenceStatus"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700333 return (void *)table->GetFenceStatus;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600334 if (!strcmp(name, "WaitForFences"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700335 return (void *)table->WaitForFences;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600336 if (!strcmp(name, "CreateSemaphore"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700337 return (void *)table->CreateSemaphore;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600338 if (!strcmp(name, "DestroySemaphore"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700339 return (void *)table->DestroySemaphore;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600340 if (!strcmp(name, "CreateEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700341 return (void *)table->CreateEvent;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600342 if (!strcmp(name, "DestroyEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700343 return (void *)table->DestroyEvent;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600344 if (!strcmp(name, "GetEventStatus"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700345 return (void *)table->GetEventStatus;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600346 if (!strcmp(name, "SetEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700347 return (void *)table->SetEvent;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600348 if (!strcmp(name, "ResetEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700349 return (void *)table->ResetEvent;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600350 if (!strcmp(name, "CreateQueryPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700351 return (void *)table->CreateQueryPool;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600352 if (!strcmp(name, "DestroyQueryPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700353 return (void *)table->DestroyQueryPool;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600354 if (!strcmp(name, "GetQueryPoolResults"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700355 return (void *)table->GetQueryPoolResults;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600356 if (!strcmp(name, "CreateBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700357 return (void *)table->CreateBuffer;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600358 if (!strcmp(name, "DestroyBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700359 return (void *)table->DestroyBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600360 if (!strcmp(name, "CreateBufferView"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700361 return (void *)table->CreateBufferView;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600362 if (!strcmp(name, "DestroyBufferView"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700363 return (void *)table->DestroyBufferView;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600364 if (!strcmp(name, "CreateImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700365 return (void *)table->CreateImage;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600366 if (!strcmp(name, "DestroyImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700367 return (void *)table->DestroyImage;
Tony Barbour59a47322015-06-24 16:06:58 -0600368 if (!strcmp(name, "GetImageSubresourceLayout"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700369 return (void *)table->GetImageSubresourceLayout;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600370 if (!strcmp(name, "CreateImageView"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700371 return (void *)table->CreateImageView;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600372 if (!strcmp(name, "DestroyImageView"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700373 return (void *)table->DestroyImageView;
Courtney Goeltzenleuchter2d2cb682015-06-24 18:24:19 -0600374 if (!strcmp(name, "CreateShaderModule"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700375 return (void *)table->CreateShaderModule;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600376 if (!strcmp(name, "DestroyShaderModule"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700377 return (void *)table->DestroyShaderModule;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600378 if (!strcmp(name, "CreatePipelineCache"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700379 return (void *)vkCreatePipelineCache;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600380 if (!strcmp(name, "DestroyPipelineCache"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700381 return (void *)vkDestroyPipelineCache;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600382 if (!strcmp(name, "GetPipelineCacheData"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700383 return (void *)vkGetPipelineCacheData;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600384 if (!strcmp(name, "MergePipelineCaches"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700385 return (void *)vkMergePipelineCaches;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600386 if (!strcmp(name, "CreateGraphicsPipelines"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700387 return (void *)vkCreateGraphicsPipelines;
Jon Ashburnc669cc62015-07-09 15:02:25 -0600388 if (!strcmp(name, "CreateComputePipelines"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700389 return (void *)vkCreateComputePipelines;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600390 if (!strcmp(name, "DestroyPipeline"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700391 return (void *)table->DestroyPipeline;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600392 if (!strcmp(name, "CreatePipelineLayout"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700393 return (void *)table->CreatePipelineLayout;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600394 if (!strcmp(name, "DestroyPipelineLayout"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700395 return (void *)table->DestroyPipelineLayout;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600396 if (!strcmp(name, "CreateSampler"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700397 return (void *)table->CreateSampler;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600398 if (!strcmp(name, "DestroySampler"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700399 return (void *)table->DestroySampler;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600400 if (!strcmp(name, "CreateDescriptorSetLayout"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700401 return (void *)table->CreateDescriptorSetLayout;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600402 if (!strcmp(name, "DestroyDescriptorSetLayout"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700403 return (void *)table->DestroyDescriptorSetLayout;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600404 if (!strcmp(name, "CreateDescriptorPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700405 return (void *)table->CreateDescriptorPool;
Tony Barbour1d2cd3f2015-07-03 10:33:54 -0600406 if (!strcmp(name, "DestroyDescriptorPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700407 return (void *)table->DestroyDescriptorPool;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600408 if (!strcmp(name, "ResetDescriptorPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700409 return (void *)table->ResetDescriptorPool;
Chia-I Wu3432a0c2015-10-27 18:04:07 +0800410 if (!strcmp(name, "AllocateDescriptorSets"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700411 return (void *)table->AllocateDescriptorSets;
Tony Barbour34ec6922015-07-10 10:50:45 -0600412 if (!strcmp(name, "FreeDescriptorSets"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700413 return (void *)table->FreeDescriptorSets;
Chia-I Wu9d00ed72015-05-25 16:27:55 +0800414 if (!strcmp(name, "UpdateDescriptorSets"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700415 return (void *)table->UpdateDescriptorSets;
Jon Ashburn754864f2015-07-23 18:49:07 -0600416 if (!strcmp(name, "CreateFramebuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700417 return (void *)table->CreateFramebuffer;
Jon Ashburn754864f2015-07-23 18:49:07 -0600418 if (!strcmp(name, "DestroyFramebuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700419 return (void *)table->DestroyFramebuffer;
Jon Ashburn754864f2015-07-23 18:49:07 -0600420 if (!strcmp(name, "CreateRenderPass"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700421 return (void *)table->CreateRenderPass;
Jon Ashburn754864f2015-07-23 18:49:07 -0600422 if (!strcmp(name, "DestroyRenderPass"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700423 return (void *)table->DestroyRenderPass;
Jon Ashburn754864f2015-07-23 18:49:07 -0600424 if (!strcmp(name, "GetRenderAreaGranularity"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700425 return (void *)table->GetRenderAreaGranularity;
Cody Northrope62183e2015-07-09 18:08:05 -0600426 if (!strcmp(name, "CreateCommandPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700427 return (void *)table->CreateCommandPool;
Cody Northrope62183e2015-07-09 18:08:05 -0600428 if (!strcmp(name, "DestroyCommandPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700429 return (void *)table->DestroyCommandPool;
Cody Northrope62183e2015-07-09 18:08:05 -0600430 if (!strcmp(name, "ResetCommandPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700431 return (void *)table->ResetCommandPool;
Chia-I Wu3432a0c2015-10-27 18:04:07 +0800432 if (!strcmp(name, "AllocateCommandBuffers"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700433 return (void *)table->AllocateCommandBuffers;
Courtney Goeltzenleuchterbee18a92015-10-23 14:21:05 -0600434 if (!strcmp(name, "FreeCommandBuffers"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700435 return (void *)table->FreeCommandBuffers;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600436 if (!strcmp(name, "BeginCommandBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700437 return (void *)table->BeginCommandBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600438 if (!strcmp(name, "EndCommandBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700439 return (void *)table->EndCommandBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600440 if (!strcmp(name, "ResetCommandBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700441 return (void *)table->ResetCommandBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600442 if (!strcmp(name, "CmdBindPipeline"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700443 return (void *)table->CmdBindPipeline;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600444 if (!strcmp(name, "CmdSetViewport"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700445 return (void *)table->CmdSetViewport;
Courtney Goeltzenleuchter078f8172015-09-21 11:44:06 -0600446 if (!strcmp(name, "CmdSetScissor"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700447 return (void *)table->CmdSetScissor;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600448 if (!strcmp(name, "CmdSetLineWidth"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700449 return (void *)table->CmdSetLineWidth;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600450 if (!strcmp(name, "CmdSetDepthBias"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700451 return (void *)table->CmdSetDepthBias;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600452 if (!strcmp(name, "CmdSetBlendConstants"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700453 return (void *)table->CmdSetBlendConstants;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600454 if (!strcmp(name, "CmdSetDepthBounds"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700455 return (void *)table->CmdSetDepthBounds;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600456 if (!strcmp(name, "CmdSetStencilCompareMask"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700457 return (void *)table->CmdSetStencilCompareMask;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600458 if (!strcmp(name, "CmdSetStencilwriteMask"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700459 return (void *)table->CmdSetStencilWriteMask;
Courtney Goeltzenleuchter49c73082015-09-17 15:06:17 -0600460 if (!strcmp(name, "CmdSetStencilReference"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700461 return (void *)table->CmdSetStencilReference;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600462 if (!strcmp(name, "CmdBindDescriptorSets"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700463 return (void *)table->CmdBindDescriptorSets;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600464 if (!strcmp(name, "CmdBindVertexBuffers"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700465 return (void *)table->CmdBindVertexBuffers;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600466 if (!strcmp(name, "CmdBindIndexBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700467 return (void *)table->CmdBindIndexBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600468 if (!strcmp(name, "CmdDraw"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700469 return (void *)table->CmdDraw;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600470 if (!strcmp(name, "CmdDrawIndexed"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700471 return (void *)table->CmdDrawIndexed;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600472 if (!strcmp(name, "CmdDrawIndirect"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700473 return (void *)table->CmdDrawIndirect;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600474 if (!strcmp(name, "CmdDrawIndexedIndirect"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700475 return (void *)table->CmdDrawIndexedIndirect;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600476 if (!strcmp(name, "CmdDispatch"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700477 return (void *)table->CmdDispatch;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600478 if (!strcmp(name, "CmdDispatchIndirect"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700479 return (void *)table->CmdDispatchIndirect;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600480 if (!strcmp(name, "CmdCopyBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700481 return (void *)table->CmdCopyBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600482 if (!strcmp(name, "CmdCopyImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700483 return (void *)table->CmdCopyImage;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600484 if (!strcmp(name, "CmdBlitImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700485 return (void *)table->CmdBlitImage;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600486 if (!strcmp(name, "CmdCopyBufferToImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700487 return (void *)table->CmdCopyBufferToImage;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600488 if (!strcmp(name, "CmdCopyImageToBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700489 return (void *)table->CmdCopyImageToBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600490 if (!strcmp(name, "CmdUpdateBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700491 return (void *)table->CmdUpdateBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600492 if (!strcmp(name, "CmdFillBuffer"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700493 return (void *)table->CmdFillBuffer;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600494 if (!strcmp(name, "CmdClearColorImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700495 return (void *)table->CmdClearColorImage;
Chris Forbesd9be82b2015-06-22 17:21:59 +1200496 if (!strcmp(name, "CmdClearDepthStencilImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700497 return (void *)table->CmdClearDepthStencilImage;
Courtney Goeltzenleuchterc9323e02015-10-15 16:51:05 -0600498 if (!strcmp(name, "CmdClearAttachments"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700499 return (void *)table->CmdClearAttachments;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600500 if (!strcmp(name, "CmdResolveImage"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700501 return (void *)table->CmdResolveImage;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600502 if (!strcmp(name, "CmdSetEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700503 return (void *)table->CmdSetEvent;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600504 if (!strcmp(name, "CmdResetEvent"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700505 return (void *)table->CmdResetEvent;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600506 if (!strcmp(name, "CmdWaitEvents"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700507 return (void *)table->CmdWaitEvents;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600508 if (!strcmp(name, "CmdPipelineBarrier"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700509 return (void *)table->CmdPipelineBarrier;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600510 if (!strcmp(name, "CmdBeginQuery"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700511 return (void *)table->CmdBeginQuery;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600512 if (!strcmp(name, "CmdEndQuery"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700513 return (void *)table->CmdEndQuery;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600514 if (!strcmp(name, "CmdResetQueryPool"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700515 return (void *)table->CmdResetQueryPool;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600516 if (!strcmp(name, "CmdWriteTimestamp"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700517 return (void *)table->CmdWriteTimestamp;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600518 if (!strcmp(name, "CmdCopyQueryPoolResults"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700519 return (void *)table->CmdCopyQueryPoolResults;
Jon Ashburn754864f2015-07-23 18:49:07 -0600520 if (!strcmp(name, "CmdPushConstants"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700521 return (void *)table->CmdPushConstants;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600522 if (!strcmp(name, "CmdBeginRenderPass"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700523 return (void *)table->CmdBeginRenderPass;
Chia-I Wu08accc62015-07-07 11:50:03 +0800524 if (!strcmp(name, "CmdNextSubpass"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700525 return (void *)table->CmdNextSubpass;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600526 if (!strcmp(name, "CmdEndRenderPass"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700527 return (void *)table->CmdEndRenderPass;
Jon Ashburn754864f2015-07-23 18:49:07 -0600528 if (!strcmp(name, "CmdExecuteCommands"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700529 return (void *)table->CmdExecuteCommands;
Jon Ashburnd55a3942015-05-06 09:02:10 -0600530
531 return NULL;
532}
Jon Ashburnfbb4e252015-05-04 16:27:53 -0600533
Jon Ashburn23d36b12016-02-02 17:47:28 -0700534static inline void
535loader_init_instance_core_dispatch_table(VkLayerInstanceDispatchTable *table,
536 PFN_vkGetInstanceProcAddr gpa,
537 VkInstance inst) {
538 table->GetInstanceProcAddr =
539 (PFN_vkGetInstanceProcAddr)gpa(inst, "vkGetInstanceProcAddr");
540 table->DestroyInstance =
541 (PFN_vkDestroyInstance)gpa(inst, "vkDestroyInstance");
542 table->EnumeratePhysicalDevices =
543 (PFN_vkEnumeratePhysicalDevices)gpa(inst, "vkEnumeratePhysicalDevices");
544 table->GetPhysicalDeviceFeatures = (PFN_vkGetPhysicalDeviceFeatures)gpa(
545 inst, "vkGetPhysicalDeviceFeatures");
546 table->GetPhysicalDeviceImageFormatProperties =
547 (PFN_vkGetPhysicalDeviceImageFormatProperties)gpa(
548 inst, "vkGetPhysicalDeviceImageFormatProperties");
549 table->GetPhysicalDeviceFormatProperties =
550 (PFN_vkGetPhysicalDeviceFormatProperties)gpa(
551 inst, "vkGetPhysicalDeviceFormatProperties");
552 table->GetPhysicalDeviceSparseImageFormatProperties =
553 (PFN_vkGetPhysicalDeviceSparseImageFormatProperties)gpa(
554 inst, "vkGetPhysicalDeviceSparseImageFormatProperties");
555 table->GetPhysicalDeviceProperties = (PFN_vkGetPhysicalDeviceProperties)gpa(
556 inst, "vkGetPhysicalDeviceProperties");
557 table->GetPhysicalDeviceQueueFamilyProperties =
558 (PFN_vkGetPhysicalDeviceQueueFamilyProperties)gpa(
559 inst, "vkGetPhysicalDeviceQueueFamilyProperties");
560 table->GetPhysicalDeviceMemoryProperties =
561 (PFN_vkGetPhysicalDeviceMemoryProperties)gpa(
562 inst, "vkGetPhysicalDeviceMemoryProperties");
563 table->EnumerateDeviceExtensionProperties =
564 (PFN_vkEnumerateDeviceExtensionProperties)gpa(
565 inst, "vkEnumerateDeviceExtensionProperties");
566 table->EnumerateDeviceLayerProperties =
567 (PFN_vkEnumerateDeviceLayerProperties)gpa(
568 inst, "vkEnumerateDeviceLayerProperties");
Courtney Goeltzenleuchterd971b612015-06-17 20:51:59 -0600569}
Courtney Goeltzenleuchterf579fa62015-06-10 17:39:03 -0600570
Courtney Goeltzenleuchterd971b612015-06-17 20:51:59 -0600571static inline void loader_init_instance_extension_dispatch_table(
Jon Ashburn23d36b12016-02-02 17:47:28 -0700572 VkLayerInstanceDispatchTable *table, PFN_vkGetInstanceProcAddr gpa,
573 VkInstance inst) {
574 table->DestroySurfaceKHR =
575 (PFN_vkDestroySurfaceKHR)gpa(inst, "vkDestroySurfaceKHR");
576 table->CreateDebugReportCallbackEXT =
577 (PFN_vkCreateDebugReportCallbackEXT)gpa(
578 inst, "vkCreateDebugReportCallbackEXT");
579 table->DestroyDebugReportCallbackEXT =
580 (PFN_vkDestroyDebugReportCallbackEXT)gpa(
581 inst, "vkDestroyDebugReportCallbackEXT");
582 table->DebugReportMessageEXT =
583 (PFN_vkDebugReportMessageEXT)gpa(inst, "vkDebugReportMessageEXT");
584 table->GetPhysicalDeviceSurfaceSupportKHR =
585 (PFN_vkGetPhysicalDeviceSurfaceSupportKHR)gpa(
586 inst, "vkGetPhysicalDeviceSurfaceSupportKHR");
587 table->GetPhysicalDeviceSurfaceCapabilitiesKHR =
588 (PFN_vkGetPhysicalDeviceSurfaceCapabilitiesKHR)gpa(
589 inst, "vkGetPhysicalDeviceSurfaceCapabilitiesKHR");
590 table->GetPhysicalDeviceSurfaceFormatsKHR =
591 (PFN_vkGetPhysicalDeviceSurfaceFormatsKHR)gpa(
592 inst, "vkGetPhysicalDeviceSurfaceFormatsKHR");
593 table->GetPhysicalDeviceSurfacePresentModesKHR =
594 (PFN_vkGetPhysicalDeviceSurfacePresentModesKHR)gpa(
595 inst, "vkGetPhysicalDeviceSurfacePresentModesKHR");
Mark Lobodzinski317574e2016-08-29 14:21:14 -0600596 table->GetPhysicalDeviceExternalImageFormatPropertiesNV =
597 (PFN_vkGetPhysicalDeviceExternalImageFormatPropertiesNV)gpa(
598 inst, "vkGetPhysicalDeviceExternalImageFormatPropertiesNV");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700599#ifdef VK_USE_PLATFORM_MIR_KHR
Jon Ashburn23d36b12016-02-02 17:47:28 -0700600 table->CreateMirSurfaceKHR =
601 (PFN_vkCreateMirSurfaceKHR)gpa(inst, "vkCreateMirSurfaceKHR");
602 table->GetPhysicalDeviceMirPresentationSupportKHR =
603 (PFN_vkGetPhysicalDeviceMirPresentationSupportKHR)gpa(
604 inst, "vkGetPhysicalDeviceMirPresentationSupportKHR");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700605#endif
606#ifdef VK_USE_PLATFORM_WAYLAND_KHR
Jon Ashburn23d36b12016-02-02 17:47:28 -0700607 table->CreateWaylandSurfaceKHR =
608 (PFN_vkCreateWaylandSurfaceKHR)gpa(inst, "vkCreateWaylandSurfaceKHR");
609 table->GetPhysicalDeviceWaylandPresentationSupportKHR =
610 (PFN_vkGetPhysicalDeviceWaylandPresentationSupportKHR)gpa(
611 inst, "vkGetPhysicalDeviceWaylandPresentationSupportKHR");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700612#endif
613#ifdef VK_USE_PLATFORM_WIN32_KHR
Jon Ashburn23d36b12016-02-02 17:47:28 -0700614 table->CreateWin32SurfaceKHR =
615 (PFN_vkCreateWin32SurfaceKHR)gpa(inst, "vkCreateWin32SurfaceKHR");
616 table->GetPhysicalDeviceWin32PresentationSupportKHR =
617 (PFN_vkGetPhysicalDeviceWin32PresentationSupportKHR)gpa(
618 inst, "vkGetPhysicalDeviceWin32PresentationSupportKHR");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700619#endif
620#ifdef VK_USE_PLATFORM_XCB_KHR
Jon Ashburn23d36b12016-02-02 17:47:28 -0700621 table->CreateXcbSurfaceKHR =
622 (PFN_vkCreateXcbSurfaceKHR)gpa(inst, "vkCreateXcbSurfaceKHR");
623 table->GetPhysicalDeviceXcbPresentationSupportKHR =
624 (PFN_vkGetPhysicalDeviceXcbPresentationSupportKHR)gpa(
625 inst, "vkGetPhysicalDeviceXcbPresentationSupportKHR");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700626#endif
627#ifdef VK_USE_PLATFORM_XLIB_KHR
Jon Ashburn23d36b12016-02-02 17:47:28 -0700628 table->CreateXlibSurfaceKHR =
629 (PFN_vkCreateXlibSurfaceKHR)gpa(inst, "vkCreateXlibSurfaceKHR");
630 table->GetPhysicalDeviceXlibPresentationSupportKHR =
631 (PFN_vkGetPhysicalDeviceXlibPresentationSupportKHR)gpa(
632 inst, "vkGetPhysicalDeviceXlibPresentationSupportKHR");
Ian Elliottdb4300a2015-11-23 10:17:23 -0700633#endif
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700634 table->GetPhysicalDeviceDisplayPropertiesKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600635 (PFN_vkGetPhysicalDeviceDisplayPropertiesKHR)gpa(
636 inst, "vkGetPhysicalDeviceDisplayPropertiesKHR");
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700637 table->GetPhysicalDeviceDisplayPlanePropertiesKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600638 (PFN_vkGetPhysicalDeviceDisplayPlanePropertiesKHR)gpa(
639 inst, "vkGetPhysicalDeviceDisplayPlanePropertiesKHR");
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700640 table->GetDisplayPlaneSupportedDisplaysKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600641 (PFN_vkGetDisplayPlaneSupportedDisplaysKHR)gpa(
642 inst, "vkGetDisplayPlaneSupportedDisplaysKHR");
643 table->GetDisplayModePropertiesKHR = (PFN_vkGetDisplayModePropertiesKHR)gpa(
644 inst, "vkGetDisplayModePropertiesKHR");
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700645 table->CreateDisplayModeKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600646 (PFN_vkCreateDisplayModeKHR)gpa(inst, "vkCreateDisplayModeKHR");
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700647 table->GetDisplayPlaneCapabilitiesKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600648 (PFN_vkGetDisplayPlaneCapabilitiesKHR)gpa(
649 inst, "vkGetDisplayPlaneCapabilitiesKHR");
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700650 table->CreateDisplayPlaneSurfaceKHR =
Jon Ashburncc407a22016-04-15 09:25:03 -0600651 (PFN_vkCreateDisplayPlaneSurfaceKHR)gpa(
652 inst, "vkCreateDisplayPlaneSurfaceKHR");
Jon Ashburnfbb4e252015-05-04 16:27:53 -0600653}
Jon Ashburn27cd5842015-05-12 17:26:48 -0600654
Jon Ashburn23d36b12016-02-02 17:47:28 -0700655static inline void *
656loader_lookup_instance_dispatch_table(const VkLayerInstanceDispatchTable *table,
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700657 const char *name, bool *found_name) {
658 if (!name || name[0] != 'v' || name[1] != 'k') {
659 *found_name = false;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600660 return NULL;
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700661 }
Jon Ashburn27cd5842015-05-12 17:26:48 -0600662
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700663 *found_name = true;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600664 name += 2;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600665 if (!strcmp(name, "DestroyInstance"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700666 return (void *)table->DestroyInstance;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600667 if (!strcmp(name, "EnumeratePhysicalDevices"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700668 return (void *)table->EnumeratePhysicalDevices;
Chris Forbesbc0bb772015-06-21 22:55:02 +1200669 if (!strcmp(name, "GetPhysicalDeviceFeatures"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700670 return (void *)table->GetPhysicalDeviceFeatures;
Jon Ashburn754864f2015-07-23 18:49:07 -0600671 if (!strcmp(name, "GetPhysicalDeviceImageFormatProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700672 return (void *)table->GetPhysicalDeviceImageFormatProperties;
Courtney Goeltzenleuchter2caec862015-07-12 12:52:09 -0600673 if (!strcmp(name, "GetPhysicalDeviceFormatProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700674 return (void *)table->GetPhysicalDeviceFormatProperties;
Mark Lobodzinski16e8bef2015-07-03 15:58:09 -0600675 if (!strcmp(name, "GetPhysicalDeviceSparseImageFormatProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700676 return (void *)table->GetPhysicalDeviceSparseImageFormatProperties;
Tony Barbour59a47322015-06-24 16:06:58 -0600677 if (!strcmp(name, "GetPhysicalDeviceProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700678 return (void *)table->GetPhysicalDeviceProperties;
Cody Northropd0802882015-08-03 17:04:53 -0600679 if (!strcmp(name, "GetPhysicalDeviceQueueFamilyProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700680 return (void *)table->GetPhysicalDeviceQueueFamilyProperties;
Tony Barbour59a47322015-06-24 16:06:58 -0600681 if (!strcmp(name, "GetPhysicalDeviceMemoryProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700682 return (void *)table->GetPhysicalDeviceMemoryProperties;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600683 if (!strcmp(name, "GetInstanceProcAddr"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700684 return (void *)table->GetInstanceProcAddr;
Courtney Goeltzenleuchter35985f62015-09-14 17:22:16 -0600685 if (!strcmp(name, "EnumerateDeviceExtensionProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700686 return (void *)table->EnumerateDeviceExtensionProperties;
Courtney Goeltzenleuchter35985f62015-09-14 17:22:16 -0600687 if (!strcmp(name, "EnumerateDeviceLayerProperties"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700688 return (void *)table->EnumerateDeviceLayerProperties;
Ian Elliottfb42cd72015-11-25 14:43:02 -0700689 if (!strcmp(name, "DestroySurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700690 return (void *)table->DestroySurfaceKHR;
Ian Elliott7e40db92015-08-21 15:09:33 -0600691 if (!strcmp(name, "GetPhysicalDeviceSurfaceSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700692 return (void *)table->GetPhysicalDeviceSurfaceSupportKHR;
Ian Elliott486c5502015-11-19 16:05:09 -0700693 if (!strcmp(name, "GetPhysicalDeviceSurfaceCapabilitiesKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700694 return (void *)table->GetPhysicalDeviceSurfaceCapabilitiesKHR;
Ian Elliott486c5502015-11-19 16:05:09 -0700695 if (!strcmp(name, "GetPhysicalDeviceSurfaceFormatsKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700696 return (void *)table->GetPhysicalDeviceSurfaceFormatsKHR;
Ian Elliott486c5502015-11-19 16:05:09 -0700697 if (!strcmp(name, "GetPhysicalDeviceSurfacePresentModesKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700698 return (void *)table->GetPhysicalDeviceSurfacePresentModesKHR;
Mark Lobodzinski317574e2016-08-29 14:21:14 -0600699 if (!strcmp(name, "GetPhysicalDeviceExternalImageFormatPropertiesNV"))
700 return (void *)table->GetPhysicalDeviceExternalImageFormatPropertiesNV;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700701#ifdef VK_USE_PLATFORM_MIR_KHR
702 if (!strcmp(name, "CreateMirSurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700703 return (void *)table->CreateMirSurfaceKHR;
Ian Elliott919fa302015-11-24 15:39:10 -0700704 if (!strcmp(name, "GetPhysicalDeviceMirPresentationSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700705 return (void *)table->GetPhysicalDeviceMirPresentationSupportKHR;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700706#endif
707#ifdef VK_USE_PLATFORM_WAYLAND_KHR
708 if (!strcmp(name, "CreateWaylandSurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700709 return (void *)table->CreateWaylandSurfaceKHR;
Ian Elliott919fa302015-11-24 15:39:10 -0700710 if (!strcmp(name, "GetPhysicalDeviceWaylandPresentationSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700711 return (void *)table->GetPhysicalDeviceWaylandPresentationSupportKHR;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700712#endif
713#ifdef VK_USE_PLATFORM_WIN32_KHR
714 if (!strcmp(name, "CreateWin32SurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700715 return (void *)table->CreateWin32SurfaceKHR;
Ian Elliott919fa302015-11-24 15:39:10 -0700716 if (!strcmp(name, "GetPhysicalDeviceWin32PresentationSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700717 return (void *)table->GetPhysicalDeviceWin32PresentationSupportKHR;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700718#endif
719#ifdef VK_USE_PLATFORM_XCB_KHR
720 if (!strcmp(name, "CreateXcbSurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700721 return (void *)table->CreateXcbSurfaceKHR;
Ian Elliott919fa302015-11-24 15:39:10 -0700722 if (!strcmp(name, "GetPhysicalDeviceXcbPresentationSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700723 return (void *)table->GetPhysicalDeviceXcbPresentationSupportKHR;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700724#endif
725#ifdef VK_USE_PLATFORM_XLIB_KHR
726 if (!strcmp(name, "CreateXlibSurfaceKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700727 return (void *)table->CreateXlibSurfaceKHR;
Ian Elliott919fa302015-11-24 15:39:10 -0700728 if (!strcmp(name, "GetPhysicalDeviceXlibPresentationSupportKHR"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700729 return (void *)table->GetPhysicalDeviceXlibPresentationSupportKHR;
Ian Elliottdb4300a2015-11-23 10:17:23 -0700730#endif
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700731 if (!strcmp(name, "GetPhysicalDeviceDisplayPropertiesKHR"))
732 return (void *)table->GetPhysicalDeviceDisplayPropertiesKHR;
733 if (!strcmp(name, "GetPhysicalDeviceDisplayPlanePropertiesKHR"))
734 return (void *)table->GetPhysicalDeviceDisplayPlanePropertiesKHR;
735 if (!strcmp(name, "GetDisplayPlaneSupportedDisplaysKHR"))
736 return (void *)table->GetDisplayPlaneSupportedDisplaysKHR;
737 if (!strcmp(name, "GetDisplayModePropertiesKHR"))
738 return (void *)table->GetDisplayModePropertiesKHR;
739 if (!strcmp(name, "CreateDisplayModeKHR"))
740 return (void *)table->CreateDisplayModeKHR;
741 if (!strcmp(name, "GetDisplayPlaneCapabilitiesKHR"))
742 return (void *)table->GetDisplayPlaneCapabilitiesKHR;
743 if (!strcmp(name, "CreateDisplayPlaneSurfaceKHR"))
744 return (void *)table->CreateDisplayPlaneSurfaceKHR;
745
Courtney Goeltzenleuchter7415d5a2015-12-09 15:48:16 -0700746 if (!strcmp(name, "CreateDebugReportCallbackEXT"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700747 return (void *)table->CreateDebugReportCallbackEXT;
Courtney Goeltzenleuchter7415d5a2015-12-09 15:48:16 -0700748 if (!strcmp(name, "DestroyDebugReportCallbackEXT"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700749 return (void *)table->DestroyDebugReportCallbackEXT;
Courtney Goeltzenleuchter7415d5a2015-12-09 15:48:16 -0700750 if (!strcmp(name, "DebugReportMessageEXT"))
Jon Ashburn23d36b12016-02-02 17:47:28 -0700751 return (void *)table->DebugReportMessageEXT;
Courtney Goeltzenleuchterf579fa62015-06-10 17:39:03 -0600752
Jon Ashburnc7d3e732016-03-08 09:30:30 -0700753 *found_name = false;
Jon Ashburn27cd5842015-05-12 17:26:48 -0600754 return NULL;
Jon Ashburn8d1b0b52015-05-18 13:20:15 -0600755}