aboutsummaryrefslogtreecommitdiff
path: root/loader/debug_report.c
diff options
context:
space:
mode:
authorMark Young <marky@lunarg.com>2017-02-28 09:58:04 -0700
committerMark Young <marky@lunarg.com>2017-03-01 08:20:22 -0700
commite2ebfd58c6cfbafbee172093b22e06867e1c3fe6 (patch)
tree7617f642ef2cee90b334b8e58455296c0f47df59 /loader/debug_report.c
parent9172c7bf11a3dbb663e170f57692e68891e891c9 (diff)
downloadusermoji-e2ebfd58c6cfbafbee172093b22e06867e1c3fe6.tar.xz
vulkan: update to header 1.0.42
Updated all necessary files to 1.0.42. This includes the various headers as well as the loader, and the parameter validation, object tracking, and threading layers. Additionally, bump all layer JSON files to 1.0.42. Also, in this change: - Enable loader extension automation so that the loader now generates all extension entry-points automatically during build to reduce likelihood of missing a critical piece on header update. - Enable layer dispatch table extension automation for the same reason. - Fixes from Mark Lobodzinski and Tony Barbour to resolve crash in loader when working with Intel's Windows driver due to GetInstanceProcAddr getting called on inappropriate command names. Change-Id: Ic18d3fac2e145c386c0192031deb5089c91a00d8
Diffstat (limited to 'loader/debug_report.c')
-rw-r--r--loader/debug_report.c59
1 files changed, 24 insertions, 35 deletions
diff --git a/loader/debug_report.c b/loader/debug_report.c
index bd46282a..04e55ccf 100644
--- a/loader/debug_report.c
+++ b/loader/debug_report.c
@@ -272,15 +272,12 @@ static VKAPI_ATTR void VKAPI_CALL debug_report_DebugReportMessageEXT(VkInstance
inst->disp->layer_inst_disp.DebugReportMessageEXT(instance, flags, objType, object, location, msgCode, pLayerPrefix, pMsg);
}
-/*
- * This is the instance chain terminator function
- * for CreateDebugReportCallback
- */
-
-VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateDebugReportCallback(VkInstance instance,
- const VkDebugReportCallbackCreateInfoEXT *pCreateInfo,
- const VkAllocationCallbacks *pAllocator,
- VkDebugReportCallbackEXT *pCallback) {
+// This is the instance chain terminator function
+// for CreateDebugReportCallback
+VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateDebugReportCallbackEXT(VkInstance instance,
+ const VkDebugReportCallbackCreateInfoEXT *pCreateInfo,
+ const VkAllocationCallbacks *pAllocator,
+ VkDebugReportCallbackEXT *pCallback) {
VkDebugReportCallbackEXT *icd_info = NULL;
const struct loader_icd_term *icd_term;
struct loader_instance *inst = (struct loader_instance *)instance;
@@ -309,11 +306,11 @@ VKAPI_ATTR VkResult VKAPI_CALL terminator_CreateDebugReportCallback(VkInstance i
storage_idx = 0;
for (icd_term = inst->icd_terms; icd_term; icd_term = icd_term->next) {
- if (!icd_term->CreateDebugReportCallbackEXT) {
+ if (!icd_term->dispatch.CreateDebugReportCallbackEXT) {
continue;
}
- res = icd_term->CreateDebugReportCallbackEXT(icd_term->instance, pCreateInfo, pAllocator, &icd_info[storage_idx]);
+ res = icd_term->dispatch.CreateDebugReportCallbackEXT(icd_term->instance, pCreateInfo, pAllocator, &icd_info[storage_idx]);
if (res != VK_SUCCESS) {
goto out;
@@ -356,12 +353,12 @@ out:
if (VK_SUCCESS != res) {
storage_idx = 0;
for (icd_term = inst->icd_terms; icd_term; icd_term = icd_term->next) {
- if (NULL == icd_term->DestroyDebugReportCallbackEXT) {
+ if (NULL == icd_term->dispatch.DestroyDebugReportCallbackEXT) {
continue;
}
if (icd_info && icd_info[storage_idx]) {
- icd_term->DestroyDebugReportCallbackEXT(icd_term->instance, icd_info[storage_idx], pAllocator);
+ icd_term->dispatch.DestroyDebugReportCallbackEXT(icd_term->instance, icd_info[storage_idx], pAllocator);
}
storage_idx++;
}
@@ -390,12 +387,9 @@ out:
return res;
}
-/*
- * This is the instance chain terminator function
- * for DestroyDebugReportCallback
- */
-VKAPI_ATTR void VKAPI_CALL terminator_DestroyDebugReportCallback(VkInstance instance, VkDebugReportCallbackEXT callback,
- const VkAllocationCallbacks *pAllocator) {
+// This is the instance chain terminator function for DestroyDebugReportCallback
+VKAPI_ATTR void VKAPI_CALL terminator_DestroyDebugReportCallbackEXT(VkInstance instance, VkDebugReportCallbackEXT callback,
+ const VkAllocationCallbacks *pAllocator) {
uint32_t storage_idx;
VkDebugReportCallbackEXT *icd_info;
const struct loader_icd_term *icd_term;
@@ -404,12 +398,12 @@ VKAPI_ATTR void VKAPI_CALL terminator_DestroyDebugReportCallback(VkInstance inst
icd_info = *(VkDebugReportCallbackEXT **)&callback;
storage_idx = 0;
for (icd_term = inst->icd_terms; icd_term; icd_term = icd_term->next) {
- if (NULL == icd_term->DestroyDebugReportCallbackEXT) {
+ if (NULL == icd_term->dispatch.DestroyDebugReportCallbackEXT) {
continue;
}
if (icd_info[storage_idx]) {
- icd_term->DestroyDebugReportCallbackEXT(icd_term->instance, icd_info[storage_idx], pAllocator);
+ icd_term->dispatch.DestroyDebugReportCallbackEXT(icd_term->instance, icd_info[storage_idx], pAllocator);
}
storage_idx++;
}
@@ -425,29 +419,24 @@ VKAPI_ATTR void VKAPI_CALL terminator_DestroyDebugReportCallback(VkInstance inst
}
}
-/*
- * This is the instance chain terminator function
- * for DebugReportMessage
- */
-VKAPI_ATTR void VKAPI_CALL terminator_DebugReportMessage(VkInstance instance, VkDebugReportFlagsEXT flags,
- VkDebugReportObjectTypeEXT objType, uint64_t object, size_t location,
- int32_t msgCode, const char *pLayerPrefix, const char *pMsg) {
+// This is the instance chain terminator function for DebugReportMessage
+VKAPI_ATTR void VKAPI_CALL terminator_DebugReportMessageEXT(VkInstance instance, VkDebugReportFlagsEXT flags,
+ VkDebugReportObjectTypeEXT objType, uint64_t object, size_t location,
+ int32_t msgCode, const char *pLayerPrefix, const char *pMsg) {
const struct loader_icd_term *icd_term;
struct loader_instance *inst = (struct loader_instance *)instance;
loader_platform_thread_lock_mutex(&loader_lock);
for (icd_term = inst->icd_terms; icd_term; icd_term = icd_term->next) {
- if (icd_term->DebugReportMessageEXT != NULL) {
- icd_term->DebugReportMessageEXT(icd_term->instance, flags, objType, object, location, msgCode, pLayerPrefix, pMsg);
+ if (icd_term->dispatch.DebugReportMessageEXT != NULL) {
+ icd_term->dispatch.DebugReportMessageEXT(icd_term->instance, flags, objType, object, location, msgCode, pLayerPrefix,
+ pMsg);
}
}
- /*
- * Now that all ICDs have seen the message, call the necessary callbacks.
- * Ignoring "bail" return value as there is nothing to bail from at this
- * point.
- */
+ // Now that all ICDs have seen the message, call the necessary callbacks. Ignoring "bail" return value
+ // as there is nothing to bail from at this point.
util_DebugReportMessage(inst, flags, objType, object, location, msgCode, pLayerPrefix, pMsg);