summaryrefslogtreecommitdiffstats
path: root/src/intel/vulkan/anv_util.c
diff options
context:
space:
mode:
authorBas Nieuwenhuizen <[email protected]>2018-01-09 03:22:56 +0100
committerBas Nieuwenhuizen <[email protected]>2018-01-17 11:27:52 +0100
commite5b1bd6ab8f5c1d9bf6a90b7003dc336cbe3cf93 (patch)
treeda5589535c0f1ebe2dcb3d441eb12ea06c85f5ac /src/intel/vulkan/anv_util.c
parentf69cbb2b53ac3edf7b201ba77430a61471edfa6e (diff)
vulkan: move anv VK_EXT_debug_report implementation to common code.
For also using it in radv. I moved the remaining stubs back to anv_device.c as they were just trivial. This does not move the vk_errorf/anv_perf_warn or the object type macros, as those depend on anv types and logging. Reviewed-by: Tapani Pälli <[email protected]>
Diffstat (limited to 'src/intel/vulkan/anv_util.c')
-rw-r--r--src/intel/vulkan/anv_util.c32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/intel/vulkan/anv_util.c b/src/intel/vulkan/anv_util.c
index 59f893492b7..6b31224d7f1 100644
--- a/src/intel/vulkan/anv_util.c
+++ b/src/intel/vulkan/anv_util.c
@@ -65,14 +65,14 @@ __anv_perf_warn(struct anv_instance *instance, const void *object,
snprintf(report, sizeof(report), "%s: %s", file, buffer);
- anv_debug_report(instance,
- VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT,
- type,
- (uint64_t) (uintptr_t) object,
- line,
- 0,
- "anv",
- report);
+ vk_debug_report(&instance->debug_report_callbacks,
+ VK_DEBUG_REPORT_PERFORMANCE_WARNING_BIT_EXT,
+ type,
+ (uint64_t) (uintptr_t) object,
+ line,
+ 0,
+ "anv",
+ report);
intel_logw("%s:%d: PERF: %s", file, line, buffer);
}
@@ -99,14 +99,14 @@ __vk_errorf(struct anv_instance *instance, const void *object,
snprintf(report, sizeof(report), "%s:%d: %s", file, line, error_str);
}
- anv_debug_report(instance,
- VK_DEBUG_REPORT_ERROR_BIT_EXT,
- type,
- (uint64_t) (uintptr_t) object,
- line,
- 0,
- "anv",
- report);
+ vk_debug_report(&instance->debug_report_callbacks,
+ VK_DEBUG_REPORT_ERROR_BIT_EXT,
+ type,
+ (uint64_t) (uintptr_t) object,
+ line,
+ 0,
+ "anv",
+ report);
intel_loge("%s", report);