From 8f9a3c84186f19b22028d1ad93f90f961cdcdd3f Mon Sep 17 00:00:00 2001 From: "Neil R. Spruit" Date: Wed, 17 Dec 2025 08:03:50 -0800 Subject: [PATCH] Update the tracing of APIs in the validation layer with params Signed-off-by: Neil R. Spruit --- scripts/generate_code.py | 1 + scripts/templates/validation/to_string.h.mako | 171 + scripts/templates/validation/valddi.cpp.mako | 94 +- source/layers/validation/ze_valddi.cpp | 6329 ++++++++++++++--- .../layers/validation/ze_validation_layer.h | 4 + source/layers/validation/zer_valddi.cpp | 68 +- source/layers/validation/zes_valddi.cpp | 4351 +++++++++-- source/layers/validation/zet_valddi.cpp | 2241 +++++- source/utils/CMakeLists.txt | 2 +- source/utils/ze_to_string.h | 2685 +++++++ source/utils/zer_to_string.h | 29 + source/utils/zes_to_string.h | 1447 ++++ source/utils/zet_to_string.h | 527 ++ 13 files changed, 15785 insertions(+), 2164 deletions(-) create mode 100644 scripts/templates/validation/to_string.h.mako create mode 100644 source/utils/ze_to_string.h create mode 100644 source/utils/zer_to_string.h create mode 100644 source/utils/zes_to_string.h create mode 100644 source/utils/zet_to_string.h diff --git a/scripts/generate_code.py b/scripts/generate_code.py index d90c5b09..05416fa7 100644 --- a/scripts/generate_code.py +++ b/scripts/generate_code.py @@ -182,6 +182,7 @@ def _mako_loader_cpp(path, namespace, tags, version, specs, meta): 'handle_lifetime.h.mako' : ('handle_lifetime_tracking', 'handle_lifetime.h'), 'handle_lifetime.cpp.mako' : ('handle_lifetime_tracking', 'handle_lifetime.cpp'), 'certification.h.mako' : ('checkers/certification/generated', 'certification.h'), + 'to_string.h.mako' : ('../../utils', 'to_string.h'), } def _mako_validation_layer_cpp(path, namespace, tags, version, specs, meta): diff --git a/scripts/templates/validation/to_string.h.mako b/scripts/templates/validation/to_string.h.mako new file mode 100644 index 00000000..dc55fa0b --- /dev/null +++ b/scripts/templates/validation/to_string.h.mako @@ -0,0 +1,171 @@ +<%! +import re +from templates import helper as th +%><% + n=namespace + N=n.upper() + + x=tags['$x'] + X=x.upper() +%>/* + * ***THIS FILE IS GENERATED. *** + * See to_string.h.mako for modifications + * + * Copyright (C) 2025 Intel Corporation + * + * SPDX-License-Identifier: MIT + * + * @file ${name} + * + * to_string functions for Level Zero types + */ + +#ifndef _${N}_TO_STRING_H +#define _${N}_TO_STRING_H + +#include "${x}_api.h" +#include +#include +#include + +%if n == 'ze': +namespace loader { + +// Forward declarations +std::string to_string(const ${x}_result_t result); + +// Pointer to_string +template +inline std::string to_string(const T* ptr) { + if (ptr == nullptr) { + return "nullptr"; + } + std::ostringstream oss; + oss << "0x" << std::hex << reinterpret_cast(ptr); + return oss.str(); +} + +%else: +// Include ze_to_string.h for common definitions +#include "ze_to_string.h" + +namespace loader { +%endif +%if n == 'ze': +// Handle to_string functions +%for obj in th.extract_objs(specs, r"handle"): +inline std::string to_string(${th.make_type_name(n, tags, obj)} handle) { + return to_string(reinterpret_cast(handle)); +} + +%endfor +%endif +%if n == 'ze': +// For primitive types and Level Zero typedef'd types +// Since most Level Zero types are typedef'd to uint32_t, we can't distinguish them by type +inline std::string to_string(uint32_t value) { return std::to_string(value); } +inline std::string to_string(uint64_t value) { return std::to_string(value); } +inline std::string to_string(uint8_t value) { return std::to_string(static_cast(value)); } +inline std::string to_string(uint16_t value) { return std::to_string(value); } +inline std::string to_string(int32_t value) { return std::to_string(value); } +inline std::string to_string(int64_t value) { return std::to_string(value); } +#if SIZE_MAX != UINT64_MAX +inline std::string to_string(size_t value) { return std::to_string(value); } +#endif +inline std::string to_string(double value) { return std::to_string(value); } +inline std::string to_string(const char* str) { + if (!str) return "nullptr"; + return std::string("\"") + str + "\""; +} + +// Pointer to primitive types - dereference and print value +inline std::string to_string(const uint32_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint64_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint8_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint16_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const int32_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const int64_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +#if SIZE_MAX != UINT64_MAX +inline std::string to_string(const size_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +#endif +inline std::string to_string(const double* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} + +%endif +// Struct to_string functions +%for obj in th.extract_objs(specs, r"struct"): +<% + struct_name = th.make_type_name(n, tags, obj) +%>\ +inline std::string to_string(const ${struct_name}* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + %for idx, member in enumerate(obj['members']): + %if member['name'] != 'pNext': +<% + # Extract the actual member name without array brackets + member_name_full = member['name'] + member_name = member_name_full.split('[')[0] if '[' in member_name_full else member_name_full + is_array = '[' in member_name_full + + # Check if member is a pointer or regular value + member_type = member.get('type', '') + if is_array: + # For arrays, just pass the array name (decays to pointer) + member_access = f"desc->{member_name}" + elif '*' in member_type: + # It's already a pointer - pass directly + member_access = f"desc->{member_name}" + else: + # Check if it's a struct type by looking at the type name + # If it contains a struct typename pattern, take its address + if '_t' in member_type and 'uint' not in member_type and 'int' not in member_type and 'size_t' not in member_type: + member_access = f"&desc->{member_name}" + else: + member_access = f"desc->{member_name}" +%>\ + %if idx == 0 and member['name'] == 'stype': + oss << "stype=" << to_string(${member_access}); + %elif idx == 0: + oss << "${member_name}=" << to_string(${member_access}); + %else: + oss << ", ${member_name}=" << to_string(${member_access}); + %endif + %endif + %endfor + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ${struct_name}& desc) { + return to_string(&desc); +} + +%endfor +} // namespace loader + +#endif // _${N}_TO_STRING_H diff --git a/scripts/templates/validation/valddi.cpp.mako b/scripts/templates/validation/valddi.cpp.mako index 7fc47480..b1fbc532 100644 --- a/scripts/templates/validation/valddi.cpp.mako +++ b/scripts/templates/validation/valddi.cpp.mako @@ -19,6 +19,18 @@ from templates import helper as th * */ #include "${x}_validation_layer.h" +#include + +// Define a macro for marking potentially unused functions +#if defined(_MSC_VER) + // MSVC doesn't support __attribute__((unused)), just omit the marking + #define VALIDATION_MAYBE_UNUSED +#elif defined(__GNUC__) || defined(__clang__) + // GCC and Clang support __attribute__((unused)) + #define VALIDATION_MAYBE_UNUSED __attribute__((unused)) +#else + #define VALIDATION_MAYBE_UNUSED +#endif namespace validation_layer { @@ -33,12 +45,68 @@ namespace validation_layer ); %endif - static ze_result_t logAndPropagateResult(const char* fname, ze_result_t result) { - if (result != ${X}_RESULT_SUCCESS) { - context.logger->log_trace("Error (" + loader::to_string(result) + ") in " + std::string(fname)); - } + // Generate specific logAndPropagateResult functions for each API function + %for obj in th.extract_objs(specs, r"function"): + <% + func_name = th.make_func_name(n, tags, obj) + param_lines = [line for line in th.make_param_lines(n, tags, obj, format=['name','delim'])] + param_names = [line for line in th.make_param_lines(n, tags, obj, format=['name'])] + is_void_params = len(param_lines) == 0 + %>\ + %if 'condition' in obj: +#if ${th.subt(n, tags, obj['condition'])} + %endif + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_${func_name}( + ze_result_t result\ +%if not is_void_params: +, + %for line in th.make_param_lines(n, tags, obj): + ${line} + %endfor +%endif +) { + std::string status = (result == ${X}_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + %if is_void_params: + context.logger->log_trace(status + " (" + loader::to_string(result) + ") in ${func_name}()"); + %else: + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in ${func_name}("; + %for i, param in enumerate([p for p in th.make_param_lines(n, tags, obj, format=['name'])]): + %if i > 0: + oss << ", "; + %endif + oss << "${param}=" << loader::to_string(${param}); + %endfor + oss << ")"; + context.logger->log_trace(oss.str()); + %endif + return result; + } + %if 'condition' in obj: +#endif // ${th.subt(n, tags, obj['condition'])} + %endif + %endfor +\ +%if n == 'ze': + // Special function for zexCounterBasedEventCreate2 + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zexCounterBasedEventCreate2( + ze_result_t result, + ze_context_handle_t hContext, + ze_device_handle_t hDevice, + const void* desc, + ze_event_handle_t* phEvent + ) { + std::string status = (result == ${X}_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zexCounterBasedEventCreate2(" + << "hContext=" << static_cast(hContext) << ", " + << "hDevice=" << static_cast(hDevice) << ", " + << "desc=" << desc << ", " + << "phEvent=" << static_cast(phEvent) << ")"; + context.logger->log_trace(oss.str()); return result; } +%endif %for obj in th.extract_objs(specs, r"function"): <% @@ -66,7 +134,7 @@ namespace validation_layer if( nullptr == ${th.make_pfn_name(n, tags, obj)} ) %if ret_type == "ze_result_t": - return logAndPropagateResult("${th.make_func_name(n, tags, obj)}", ${X}_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_${th.make_func_name(n, tags, obj)}(${X}_RESULT_ERROR_UNSUPPORTED_FEATURE${', ' if not is_void_params else ''}${', '.join(th.make_param_lines(n, tags, obj, format=["name"]))}); %else: return ${failure_return}; %endif @@ -80,7 +148,7 @@ ${line} \ ); if(result!=${X}_RESULT_SUCCESS) \ %if ret_type == "ze_result_t": -return logAndPropagateResult("${th.make_func_name(n, tags, obj)}", result); +return logAndPropagateResult_${th.make_func_name(n, tags, obj)}(result${', ' if not is_void_params else ''}${', '.join(th.make_param_lines(n, tags, obj, format=["name"]))}); %else: return ${failure_return}; %endif @@ -103,7 +171,7 @@ ${line} \ ); if(result!=${X}_RESULT_SUCCESS) \ %if ret_type == "ze_result_t": -return logAndPropagateResult("${th.make_func_name(n, tags, obj)}", result); +return logAndPropagateResult_${th.make_func_name(n, tags, obj)}(result${', ' if not is_void_params else ''}${', '.join(th.make_param_lines(n, tags, obj, format=["name"]))}); %else: return ${failure_return}; %endif @@ -134,7 +202,7 @@ driver_result ); %endif if(result!=${X}_RESULT_SUCCESS) \ %if ret_type == "ze_result_t": -return logAndPropagateResult("${th.make_func_name(n, tags, obj)}", result); +return logAndPropagateResult_${th.make_func_name(n, tags, obj)}(result${', ' if not is_void_params else ''}${', '.join(th.make_param_lines(n, tags, obj, format=["name"]))}); %else: return ${failure_return}; %endif @@ -173,7 +241,7 @@ return ${failure_return}; } %endif %if ret_type == "ze_result_t": - return logAndPropagateResult("${th.make_func_name(n, tags, obj)}", driver_result); + return logAndPropagateResult_${th.make_func_name(n, tags, obj)}(driver_result${', ' if not is_void_params else ''}${', '.join(th.make_param_lines(n, tags, obj, format=["name"]))}); %else: return driver_result; %endif @@ -203,7 +271,7 @@ return ${failure_return}; auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zexCounterBasedEventCreate2Prologue( hContext, hDevice, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } if(context.enableThreadingValidation){ @@ -212,7 +280,7 @@ return ${failure_return}; if(context.enableHandleLifetime){ auto result = context.handleLifetime->zeHandleLifetime.zexCounterBasedEventCreate2Prologue( hContext, hDevice, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } // This is an experimental function that must be accessed through the extension mechanism @@ -254,7 +322,7 @@ return ${failure_return}; for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zexCounterBasedEventCreate2Epilogue( hContext, hDevice, desc, phEvent, driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } if(driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime){ @@ -263,7 +331,7 @@ return ${failure_return}; // Note: counter-based events may not have a traditional event pool dependency } } - return logAndPropagateResult("zexCounterBasedEventCreate2", driver_result); + return logAndPropagateResult_zexCounterBasedEventCreate2(driver_result, hContext, hDevice, desc, phEvent); } %endif } // namespace validation_layer diff --git a/source/layers/validation/ze_valddi.cpp b/source/layers/validation/ze_valddi.cpp index 0858ec71..ca0c1cf6 100644 --- a/source/layers/validation/ze_valddi.cpp +++ b/source/layers/validation/ze_valddi.cpp @@ -10,6 +10,18 @@ * */ #include "ze_validation_layer.h" +#include + +// Define a macro for marking potentially unused functions +#if defined(_MSC_VER) + // MSVC doesn't support __attribute__((unused)), just omit the marking + #define VALIDATION_MAYBE_UNUSED +#elif defined(__GNUC__) || defined(__clang__) + // GCC and Clang support __attribute__((unused)) + #define VALIDATION_MAYBE_UNUSED __attribute__((unused)) +#else + #define VALIDATION_MAYBE_UNUSED +#endif namespace validation_layer { @@ -22,10 +34,4241 @@ namespace validation_layer ze_event_handle_t *phEvent ); - static ze_result_t logAndPropagateResult(const char* fname, ze_result_t result) { - if (result != ZE_RESULT_SUCCESS) { - context.logger->log_trace("Error (" + loader::to_string(result) + ") in " + std::string(fname)); - } + // Generate specific logAndPropagateResult functions for each API function + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeInit( + ze_result_t result, + ze_init_flags_t flags ///< [in] initialization flags. + ///< must be 0 (default) or a combination of ::ze_init_flag_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeInit("; + oss << "flags=" << loader::to_string(flags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGet( + ze_result_t result, + uint32_t* pCount, ///< [in,out] pointer to the number of driver instances. + ///< if count is zero, then the loader shall update the value with the + ///< total number of drivers available. + ///< if count is greater than the number of drivers available, then the + ///< loader shall update the value with the correct number of drivers available. + ze_driver_handle_t* phDrivers ///< [in,out][optional][range(0, *pCount)] array of driver instance handles. + ///< if count is less than the number of drivers available, then the loader + ///< shall only retrieve that number of drivers. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGet("; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDrivers=" << loader::to_string(phDrivers); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeInitDrivers( + ze_result_t result, + uint32_t* pCount, ///< [in,out] pointer to the number of driver instances. + ///< if count is zero, then the loader shall update the value with the + ///< total number of drivers available. + ///< if count is greater than the number of drivers available, then the + ///< loader shall update the value with the correct number of drivers available. + ze_driver_handle_t* phDrivers, ///< [in,out][optional][range(0, *pCount)] array of driver instance handles. + ///< if count is less than the number of drivers available, then the loader + ///< shall only retrieve that number of drivers. + ze_init_driver_type_desc_t* desc ///< [in] descriptor containing the driver type initialization details + ///< including ::ze_init_driver_type_flag_t combinations. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeInitDrivers("; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDrivers=" << loader::to_string(phDrivers); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetApiVersion( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + ze_api_version_t* version ///< [out] api version +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetApiVersion("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "version=" << loader::to_string(version); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetProperties( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + ze_driver_properties_t* pDriverProperties ///< [in,out] query result for driver properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetProperties("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pDriverProperties=" << loader::to_string(pDriverProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetIpcProperties( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + ze_driver_ipc_properties_t* pIpcProperties ///< [in,out] query result for IPC properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetIpcProperties("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pIpcProperties=" << loader::to_string(pIpcProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetExtensionProperties( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint32_t* pCount, ///< [in,out] pointer to the number of extension properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of extension properties available. + ///< if count is greater than the number of extension properties available, + ///< then the driver shall update the value with the correct number of + ///< extension properties available. + ze_driver_extension_properties_t* pExtensionProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< extension properties. + ///< if count is less than the number of extension properties available, + ///< then driver shall only retrieve that number of extension properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetExtensionProperties("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pExtensionProperties=" << loader::to_string(pExtensionProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetExtensionFunctionAddress( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + const char* name, ///< [in] extension function name + void** ppFunctionAddress ///< [out] pointer to function pointer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetExtensionFunctionAddress("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "name=" << loader::to_string(name); + oss << ", "; + oss << "ppFunctionAddress=" << loader::to_string(ppFunctionAddress); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetLastErrorDescription( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + const char** ppString ///< [in,out] pointer to a null-terminated array of characters describing + ///< cause of error. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetLastErrorDescription("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "ppString=" << loader::to_string(ppString); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverGetDefaultContext( + ze_result_t result, + ze_driver_handle_t hDriver ///< [in] handle of the driver instance +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverGetDefaultContext("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGet( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint32_t* pCount, ///< [in,out] pointer to the number of devices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of devices available. + ///< if count is greater than the number of devices available, then the + ///< driver shall update the value with the correct number of devices available. + ze_device_handle_t* phDevices ///< [in,out][optional][range(0, *pCount)] array of handle of devices. + ///< if count is less than the number of devices available, then driver + ///< shall only retrieve that number of devices. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGet("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetRootDevice( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device object + ze_device_handle_t* phRootDevice ///< [in,out] parent root device. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetRootDevice("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "phRootDevice=" << loader::to_string(phRootDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetSubDevices( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device object + uint32_t* pCount, ///< [in,out] pointer to the number of sub-devices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of sub-devices available. + ///< if count is greater than the number of sub-devices available, then the + ///< driver shall update the value with the correct number of sub-devices available. + ze_device_handle_t* phSubdevices ///< [in,out][optional][range(0, *pCount)] array of handle of sub-devices. + ///< if count is less than the number of sub-devices available, then driver + ///< shall only retrieve that number of sub-devices. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetSubDevices("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phSubdevices=" << loader::to_string(phSubdevices); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_properties_t* pDeviceProperties ///< [in,out] query result for device properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pDeviceProperties=" << loader::to_string(pDeviceProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetComputeProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_compute_properties_t* pComputeProperties ///< [in,out] query result for compute properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetComputeProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pComputeProperties=" << loader::to_string(pComputeProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetModuleProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_module_properties_t* pModuleProperties///< [in,out] query result for module properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetModuleProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pModuleProperties=" << loader::to_string(pModuleProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of command queue group properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of command queue group properties available. + ///< if count is greater than the number of command queue group properties + ///< available, then the driver shall update the value with the correct + ///< number of command queue group properties available. + ze_command_queue_group_properties_t* pCommandQueueGroupProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< command queue group properties. + ///< if count is less than the number of command queue group properties + ///< available, then driver shall only retrieve that number of command + ///< queue group properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetCommandQueueGroupProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pCommandQueueGroupProperties=" << loader::to_string(pCommandQueueGroupProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetMemoryProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of memory properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of memory properties available. + ///< if count is greater than the number of memory properties available, + ///< then the driver shall update the value with the correct number of + ///< memory properties available. + ze_device_memory_properties_t* pMemProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< memory properties. + ///< if count is less than the number of memory properties available, then + ///< driver shall only retrieve that number of memory properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetMemoryProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pMemProperties=" << loader::to_string(pMemProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetMemoryAccessProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_memory_access_properties_t* pMemAccessProperties ///< [in,out] query result for memory access properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetMemoryAccessProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pMemAccessProperties=" << loader::to_string(pMemAccessProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetCacheProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of cache properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of cache properties available. + ///< if count is greater than the number of cache properties available, + ///< then the driver shall update the value with the correct number of + ///< cache properties available. + ze_device_cache_properties_t* pCacheProperties ///< [in,out][optional][range(0, *pCount)] array of query results for cache properties. + ///< if count is less than the number of cache properties available, then + ///< driver shall only retrieve that number of cache properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetCacheProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pCacheProperties=" << loader::to_string(pCacheProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetImageProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_image_properties_t* pImageProperties ///< [in,out] query result for image properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetImageProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pImageProperties=" << loader::to_string(pImageProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetExternalMemoryProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_device_external_memory_properties_t* pExternalMemoryProperties ///< [in,out] query result for external memory properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetExternalMemoryProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pExternalMemoryProperties=" << loader::to_string(pExternalMemoryProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetP2PProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device performing the access + ze_device_handle_t hPeerDevice, ///< [in] handle of the peer device with the allocation + ze_device_p2p_properties_t* pP2PProperties ///< [in,out] Peer-to-Peer properties between source and peer device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetP2PProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hPeerDevice=" << loader::to_string(hPeerDevice); + oss << ", "; + oss << "pP2PProperties=" << loader::to_string(pP2PProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceCanAccessPeer( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device performing the access + ze_device_handle_t hPeerDevice, ///< [in] handle of the peer device with the allocation + ze_bool_t* value ///< [out] returned access capability +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceCanAccessPeer("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hPeerDevice=" << loader::to_string(hPeerDevice); + oss << ", "; + oss << "value=" << loader::to_string(value); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetStatus( + ze_result_t result, + ze_device_handle_t hDevice ///< [in] handle of the device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetStatus("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetGlobalTimestamps( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + uint64_t* hostTimestamp, ///< [out] value of the Host's global timestamp that correlates with the + ///< Device's global timestamp value. + uint64_t* deviceTimestamp ///< [out] value of the Device's global timestamp that correlates with the + ///< Host's global timestamp value. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetGlobalTimestamps("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hostTimestamp=" << loader::to_string(hostTimestamp); + oss << ", "; + oss << "deviceTimestamp=" << loader::to_string(deviceTimestamp); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceSynchronize( + ze_result_t result, + ze_device_handle_t hDevice ///< [in] handle of the device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceSynchronize("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextCreate( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver object + const ze_context_desc_t* desc, ///< [in] pointer to context descriptor + ze_context_handle_t* phContext ///< [out] pointer to handle of context object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextCreate("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phContext=" << loader::to_string(phContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextCreateEx( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver object + const ze_context_desc_t* desc, ///< [in] pointer to context descriptor + uint32_t numDevices, ///< [in][optional] number of device handles; must be 0 if `nullptr == + ///< phDevices` + ze_device_handle_t* phDevices, ///< [in][optional][range(0, numDevices)] array of device handles which + ///< context has visibility. + ///< if nullptr, then all devices and any sub-devices supported by the + ///< driver instance are + ///< visible to the context. + ///< otherwise, the context only has visibility to the devices and any + ///< sub-devices of the + ///< devices in this array. + ze_context_handle_t* phContext ///< [out] pointer to handle of context object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextCreateEx("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "numDevices=" << loader::to_string(numDevices); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ", "; + oss << "phContext=" << loader::to_string(phContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextDestroy( + ze_result_t result, + ze_context_handle_t hContext ///< [in][release] handle of context object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextDestroy("; + oss << "hContext=" << loader::to_string(hContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextGetStatus( + ze_result_t result, + ze_context_handle_t hContext ///< [in] handle of context object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextGetStatus("; + oss << "hContext=" << loader::to_string(hContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device object + const ze_command_queue_desc_t* desc, ///< [in] pointer to command queue descriptor + ze_command_queue_handle_t* phCommandQueue ///< [out] pointer to handle of command queue object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phCommandQueue=" << loader::to_string(phCommandQueue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueDestroy( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue ///< [in][release] handle of command queue object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueDestroy("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueExecuteCommandLists( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue, ///< [in] handle of the command queue + uint32_t numCommandLists, ///< [in] number of command lists to execute + ze_command_list_handle_t* phCommandLists, ///< [in][range(0, numCommandLists)] list of handles of the command lists + ///< to execute + ze_fence_handle_t hFence ///< [in][optional] handle of the fence to signal on completion +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueExecuteCommandLists("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ", "; + oss << "numCommandLists=" << loader::to_string(numCommandLists); + oss << ", "; + oss << "phCommandLists=" << loader::to_string(phCommandLists); + oss << ", "; + oss << "hFence=" << loader::to_string(hFence); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueSynchronize( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue, ///< [in] handle of the command queue + uint64_t timeout ///< [in] if non-zero, then indicates the maximum time (in nanoseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then immediately returns the status of the command queue; + ///< if `UINT64_MAX`, then function will not return until complete or + ///< device is lost. + ///< Due to external dependencies, timeout may be rounded to the closest + ///< value allowed by the accuracy of those dependencies. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueSynchronize("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueGetOrdinal( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue, ///< [in] handle of the command queue + uint32_t* pOrdinal ///< [out] command queue group ordinal +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueGetOrdinal("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ", "; + oss << "pOrdinal=" << loader::to_string(pOrdinal); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandQueueGetIndex( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue, ///< [in] handle of the command queue + uint32_t* pIndex ///< [out] command queue index within the group +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandQueueGetIndex("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ", "; + oss << "pIndex=" << loader::to_string(pIndex); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device object + const ze_command_list_desc_t* desc, ///< [in] pointer to command list descriptor + ze_command_list_handle_t* phCommandList ///< [out] pointer to handle of command list object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phCommandList=" << loader::to_string(phCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListCreateImmediate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device object + const ze_command_queue_desc_t* altdesc, ///< [in] pointer to command queue descriptor + ze_command_list_handle_t* phCommandList ///< [out] pointer to handle of command list object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListCreateImmediate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "altdesc=" << loader::to_string(altdesc); + oss << ", "; + oss << "phCommandList=" << loader::to_string(phCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListDestroy( + ze_result_t result, + ze_command_list_handle_t hCommandList ///< [in][release] handle of command list object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListDestroy("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListClose( + ze_result_t result, + ze_command_list_handle_t hCommandList ///< [in] handle of command list object to close +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListClose("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListReset( + ze_result_t result, + ze_command_list_handle_t hCommandList ///< [in] handle of command list object to reset +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListReset("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint64_t* dstptr, ///< [in,out] pointer to memory where timestamp value will be written; must + ///< be 8byte-aligned. + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before executing query; + ///< must be 0 if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before executing query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendWriteGlobalTimestamp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListHostSynchronize( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the immediate command list + uint64_t timeout ///< [in] if non-zero, then indicates the maximum time (in nanoseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then immediately returns the status of the immediate command list; + ///< if `UINT64_MAX`, then function will not return until complete or + ///< device is lost. + ///< Due to external dependencies, timeout may be rounded to the closest + ///< value allowed by the accuracy of those dependencies. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListHostSynchronize("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListGetDeviceHandle( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_device_handle_t* phDevice ///< [out] handle of the device on which the command list was created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListGetDeviceHandle("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "phDevice=" << loader::to_string(phDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListGetContextHandle( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_context_handle_t* phContext ///< [out] handle of the context on which the command list was created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListGetContextHandle("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "phContext=" << loader::to_string(phContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListGetOrdinal( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t* pOrdinal ///< [out] command queue group ordinal to which command list is submitted +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListGetOrdinal("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "pOrdinal=" << loader::to_string(pOrdinal); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListImmediateGetIndex( + ze_result_t result, + ze_command_list_handle_t hCommandListImmediate, ///< [in] handle of the immediate command list + uint32_t* pIndex ///< [out] command queue index within the group to which the immediate + ///< command list is submitted +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListImmediateGetIndex("; + oss << "hCommandListImmediate=" << loader::to_string(hCommandListImmediate); + oss << ", "; + oss << "pIndex=" << loader::to_string(pIndex); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListIsImmediate( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_bool_t* pIsImmediate ///< [out] Boolean indicating whether the command list is an immediate + ///< command list (true) or not (false) +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListIsImmediate("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "pIsImmediate=" << loader::to_string(pIsImmediate); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendBarrier( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before executing barrier; + ///< must be 0 if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before executing barrier +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendBarrier("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t numRanges, ///< [in] number of memory ranges + const size_t* pRangeSizes, ///< [in][range(0, numRanges)] array of sizes of memory range + const void** pRanges, ///< [in][range(0, numRanges)] array of memory ranges + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before executing barrier; + ///< must be 0 if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before executing barrier +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryRangesBarrier("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numRanges=" << loader::to_string(numRanges); + oss << ", "; + oss << "pRangeSizes=" << loader::to_string(pRangeSizes); + oss << ", "; + oss << "pRanges=" << loader::to_string(pRanges); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextSystemBarrier( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context object + ze_device_handle_t hDevice ///< [in] handle of the device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextSystemBarrier("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryCopy( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination memory to copy to + const void* srcptr, ///< [in] pointer to source memory to copy from + size_t size, ///< [in] size in bytes to copy + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryCopy("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryFill( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* ptr, ///< [in] pointer to memory to initialize + const void* pattern, ///< [in] pointer to value to initialize memory to + size_t pattern_size, ///< [in] size in bytes of the value to initialize memory to + size_t size, ///< [in] size in bytes to initialize + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryFill("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "pattern=" << loader::to_string(pattern); + oss << ", "; + oss << "pattern_size=" << loader::to_string(pattern_size); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryCopyRegion( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination memory to copy to + const ze_copy_region_t* dstRegion, ///< [in] pointer to destination region to copy to + uint32_t dstPitch, ///< [in] destination pitch in bytes + uint32_t dstSlicePitch, ///< [in] destination slice pitch in bytes. This is required for 3D region + ///< copies where the `depth` member of ::ze_copy_region_t is not 0, + ///< otherwise it's ignored. + const void* srcptr, ///< [in] pointer to source memory to copy from + const ze_copy_region_t* srcRegion, ///< [in] pointer to source region to copy from + uint32_t srcPitch, ///< [in] source pitch in bytes + uint32_t srcSlicePitch, ///< [in] source slice pitch in bytes. This is required for 3D region + ///< copies where the `depth` member of ::ze_copy_region_t is not 0, + ///< otherwise it's ignored. + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryCopyRegion("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "dstRegion=" << loader::to_string(dstRegion); + oss << ", "; + oss << "dstPitch=" << loader::to_string(dstPitch); + oss << ", "; + oss << "dstSlicePitch=" << loader::to_string(dstSlicePitch); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "srcRegion=" << loader::to_string(srcRegion); + oss << ", "; + oss << "srcPitch=" << loader::to_string(srcPitch); + oss << ", "; + oss << "srcSlicePitch=" << loader::to_string(srcSlicePitch); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination memory to copy to + ze_context_handle_t hContextSrc, ///< [in] handle of source context object + const void* srcptr, ///< [in] pointer to source memory to copy from + size_t size, ///< [in] size in bytes to copy + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryCopyFromContext("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "hContextSrc=" << loader::to_string(hContextSrc); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopy( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + ze_image_handle_t hDstImage, ///< [in] handle of destination image to copy to + ze_image_handle_t hSrcImage, ///< [in] handle of source image to copy from + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopy("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hDstImage=" << loader::to_string(hDstImage); + oss << ", "; + oss << "hSrcImage=" << loader::to_string(hSrcImage); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopyRegion( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + ze_image_handle_t hDstImage, ///< [in] handle of destination image to copy to + ze_image_handle_t hSrcImage, ///< [in] handle of source image to copy from + const ze_image_region_t* pDstRegion, ///< [in][optional] destination region descriptor + const ze_image_region_t* pSrcRegion, ///< [in][optional] source region descriptor + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopyRegion("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hDstImage=" << loader::to_string(hDstImage); + oss << ", "; + oss << "hSrcImage=" << loader::to_string(hSrcImage); + oss << ", "; + oss << "pDstRegion=" << loader::to_string(pDstRegion); + oss << ", "; + oss << "pSrcRegion=" << loader::to_string(pSrcRegion); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopyToMemory( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination memory to copy to + ze_image_handle_t hSrcImage, ///< [in] handle of source image to copy from + const ze_image_region_t* pSrcRegion, ///< [in][optional] source region descriptor + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopyToMemory("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "hSrcImage=" << loader::to_string(hSrcImage); + oss << ", "; + oss << "pSrcRegion=" << loader::to_string(pSrcRegion); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopyFromMemory( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + ze_image_handle_t hDstImage, ///< [in] handle of destination image to copy to + const void* srcptr, ///< [in] pointer to source memory to copy from + const ze_image_region_t* pDstRegion, ///< [in][optional] destination region descriptor + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopyFromMemory("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hDstImage=" << loader::to_string(hDstImage); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "pDstRegion=" << loader::to_string(pDstRegion); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemoryPrefetch( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + const void* ptr, ///< [in] pointer to start of the memory range to prefetch + size_t size ///< [in] size in bytes of the memory range to prefetch +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemoryPrefetch("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendMemAdvise( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + ze_device_handle_t hDevice, ///< [in] device associated with the memory advice + const void* ptr, ///< [in] Pointer to the start of the memory range + size_t size, ///< [in] Size in bytes of the memory range + ze_memory_advice_t advice ///< [in] Memory advice for the memory range +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendMemAdvise("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "advice=" << loader::to_string(advice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const ze_event_pool_desc_t* desc, ///< [in] pointer to event pool descriptor + uint32_t numDevices, ///< [in][optional] number of device handles; must be 0 if `nullptr == + ///< phDevices` + ze_device_handle_t* phDevices, ///< [in][optional][range(0, numDevices)] array of device handles which + ///< have visibility to the event pool. + ///< if nullptr, then event pool is visible to all devices supported by the + ///< driver instance. + ze_event_pool_handle_t* phEventPool ///< [out] pointer handle of event pool object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "numDevices=" << loader::to_string(numDevices); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ", "; + oss << "phEventPool=" << loader::to_string(phEventPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolDestroy( + ze_result_t result, + ze_event_pool_handle_t hEventPool ///< [in][release] handle of event pool object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolDestroy("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventCreate( + ze_result_t result, + ze_event_pool_handle_t hEventPool, ///< [in] handle of the event pool + const ze_event_desc_t* desc, ///< [in] pointer to event descriptor + ze_event_handle_t* phEvent ///< [out] pointer to handle of event object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventCreate("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phEvent=" << loader::to_string(phEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventDestroy( + ze_result_t result, + ze_event_handle_t hEvent ///< [in][release] handle of event object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventDestroy("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolGetIpcHandle( + ze_result_t result, + ze_event_pool_handle_t hEventPool, ///< [in] handle of event pool object + ze_ipc_event_pool_handle_t* phIpc ///< [out] Returned IPC event handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolGetIpcHandle("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ", "; + oss << "phIpc=" << loader::to_string(phIpc); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolPutIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object associated with the IPC event pool + ///< handle + ze_ipc_event_pool_handle_t hIpc ///< [in] IPC event pool handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolPutIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hIpc=" << loader::to_string(hIpc); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolOpenIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object to associate with the IPC event pool + ///< handle + ze_ipc_event_pool_handle_t hIpc, ///< [in] IPC event pool handle + ze_event_pool_handle_t* phEventPool ///< [out] pointer handle of event pool object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolOpenIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hIpc=" << loader::to_string(hIpc); + oss << ", "; + oss << "phEventPool=" << loader::to_string(phEventPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolCloseIpcHandle( + ze_result_t result, + ze_event_pool_handle_t hEventPool ///< [in][release] handle of event pool object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolCloseIpcHandle("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendSignalEvent( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_event_handle_t hEvent ///< [in] handle of the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendSignalEvent("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendWaitOnEvents( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t numEvents, ///< [in] number of events to wait on before continuing + ze_event_handle_t* phEvents ///< [in][range(0, numEvents)] handles of the events to wait on before + ///< continuing +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendWaitOnEvents("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numEvents=" << loader::to_string(numEvents); + oss << ", "; + oss << "phEvents=" << loader::to_string(phEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventHostSignal( + ze_result_t result, + ze_event_handle_t hEvent ///< [in] handle of the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventHostSignal("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventHostSynchronize( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + uint64_t timeout ///< [in] if non-zero, then indicates the maximum time (in nanoseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then operates exactly like ::zeEventQueryStatus; + ///< if `UINT64_MAX`, then function will not return until complete or + ///< device is lost. + ///< Due to external dependencies, timeout may be rounded to the closest + ///< value allowed by the accuracy of those dependencies. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventHostSynchronize("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventQueryStatus( + ze_result_t result, + ze_event_handle_t hEvent ///< [in] handle of the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventQueryStatus("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendEventReset( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_event_handle_t hEvent ///< [in] handle of the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendEventReset("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventHostReset( + ze_result_t result, + ze_event_handle_t hEvent ///< [in] handle of the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventHostReset("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventQueryKernelTimestamp( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_kernel_timestamp_result_t* dstptr ///< [in,out] pointer to memory for where timestamp result will be written. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventQueryKernelTimestamp("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t numEvents, ///< [in] the number of timestamp events to query + ze_event_handle_t* phEvents, ///< [in][range(0, numEvents)] handles of timestamp events to query + void* dstptr, ///< [in,out] pointer to memory where ::ze_kernel_timestamp_result_t will + ///< be written; must be size-aligned. + const size_t* pOffsets, ///< [in][optional][range(0, numEvents)] offset, in bytes, to write + ///< results; address must be 4byte-aligned and offsets must be + ///< size-aligned. + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before executing query; + ///< must be 0 if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before executing query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendQueryKernelTimestamps("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numEvents=" << loader::to_string(numEvents); + oss << ", "; + oss << "phEvents=" << loader::to_string(phEvents); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "pOffsets=" << loader::to_string(pOffsets); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventGetEventPool( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_event_pool_handle_t* phEventPool ///< [out] handle of the event pool for the event +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventGetEventPool("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "phEventPool=" << loader::to_string(phEventPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventGetSignalScope( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_event_scope_flags_t* pSignalScope ///< [out] signal event scope. This is the scope of relevant cache + ///< hierarchies that are flushed on a signal action before the event is + ///< triggered. May be 0 or a valid combination of ::ze_event_scope_flag_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventGetSignalScope("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "pSignalScope=" << loader::to_string(pSignalScope); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventGetWaitScope( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_event_scope_flags_t* pWaitScope ///< [out] wait event scope. This is the scope of relevant cache + ///< hierarchies invalidated on a wait action after the event is complete. + ///< May be 0 or a valid combination of ::ze_event_scope_flag_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventGetWaitScope("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "pWaitScope=" << loader::to_string(pWaitScope); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolGetContextHandle( + ze_result_t result, + ze_event_pool_handle_t hEventPool, ///< [in] handle of the event pool + ze_context_handle_t* phContext ///< [out] handle of the context on which the event pool was created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolGetContextHandle("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ", "; + oss << "phContext=" << loader::to_string(phContext); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventPoolGetFlags( + ze_result_t result, + ze_event_pool_handle_t hEventPool, ///< [in] handle of the event pool + ze_event_pool_flags_t* pFlags ///< [out] creation flags used to create the event pool; may be 0 or a + ///< valid combination of ::ze_event_pool_flag_t +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventPoolGetFlags("; + oss << "hEventPool=" << loader::to_string(hEventPool); + oss << ", "; + oss << "pFlags=" << loader::to_string(pFlags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFenceCreate( + ze_result_t result, + ze_command_queue_handle_t hCommandQueue, ///< [in] handle of command queue + const ze_fence_desc_t* desc, ///< [in] pointer to fence descriptor + ze_fence_handle_t* phFence ///< [out] pointer to handle of fence object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFenceCreate("; + oss << "hCommandQueue=" << loader::to_string(hCommandQueue); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phFence=" << loader::to_string(phFence); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFenceDestroy( + ze_result_t result, + ze_fence_handle_t hFence ///< [in][release] handle of fence object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFenceDestroy("; + oss << "hFence=" << loader::to_string(hFence); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFenceHostSynchronize( + ze_result_t result, + ze_fence_handle_t hFence, ///< [in] handle of the fence + uint64_t timeout ///< [in] if non-zero, then indicates the maximum time (in nanoseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then operates exactly like ::zeFenceQueryStatus; + ///< if `UINT64_MAX`, then function will not return until complete or + ///< device is lost. + ///< Due to external dependencies, timeout may be rounded to the closest + ///< value allowed by the accuracy of those dependencies. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFenceHostSynchronize("; + oss << "hFence=" << loader::to_string(hFence); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFenceQueryStatus( + ze_result_t result, + ze_fence_handle_t hFence ///< [in] handle of the fence +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFenceQueryStatus("; + oss << "hFence=" << loader::to_string(hFence); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFenceReset( + ze_result_t result, + ze_fence_handle_t hFence ///< [in] handle of the fence +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFenceReset("; + oss << "hFence=" << loader::to_string(hFence); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageGetProperties( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_image_desc_t* desc, ///< [in] pointer to image descriptor + ze_image_properties_t* pImageProperties ///< [out] pointer to image properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageGetProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "pImageProperties=" << loader::to_string(pImageProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_image_desc_t* desc, ///< [in] pointer to image descriptor + ze_image_handle_t* phImage ///< [out] pointer to handle of image object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phImage=" << loader::to_string(phImage); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageDestroy( + ze_result_t result, + ze_image_handle_t hImage ///< [in][release] handle of image object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageDestroy("; + oss << "hImage=" << loader::to_string(hImage); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemAllocShared( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const ze_device_mem_alloc_desc_t* device_desc, ///< [in] pointer to device memory allocation descriptor + const ze_host_mem_alloc_desc_t* host_desc, ///< [in] pointer to host memory allocation descriptor + size_t size, ///< [in] size in bytes to allocate; must be less than or equal to the + ///< `maxMemAllocSize` member of ::ze_device_properties_t + size_t alignment, ///< [in] minimum alignment in bytes for the allocation; must be a power of + ///< two + ze_device_handle_t hDevice, ///< [in][optional] device handle to associate with + void** pptr ///< [out] pointer to shared allocation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemAllocShared("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "device_desc=" << loader::to_string(device_desc); + oss << ", "; + oss << "host_desc=" << loader::to_string(host_desc); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "alignment=" << loader::to_string(alignment); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemAllocDevice( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const ze_device_mem_alloc_desc_t* device_desc, ///< [in] pointer to device memory allocation descriptor + size_t size, ///< [in] size in bytes to allocate; must be less than or equal to the + ///< `maxMemAllocSize` member of ::ze_device_properties_t + size_t alignment, ///< [in] minimum alignment in bytes for the allocation; must be a power of + ///< two + ze_device_handle_t hDevice, ///< [in] handle of the device + void** pptr ///< [out] pointer to device allocation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemAllocDevice("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "device_desc=" << loader::to_string(device_desc); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "alignment=" << loader::to_string(alignment); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemAllocHost( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const ze_host_mem_alloc_desc_t* host_desc, ///< [in] pointer to host memory allocation descriptor + size_t size, ///< [in] size in bytes to allocate; must be less than or equal to the + ///< `maxMemAllocSize` member of ::ze_device_properties_t + size_t alignment, ///< [in] minimum alignment in bytes for the allocation; must be a power of + ///< two + void** pptr ///< [out] pointer to host allocation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemAllocHost("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "host_desc=" << loader::to_string(host_desc); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "alignment=" << loader::to_string(alignment); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemFree( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + void* ptr ///< [in][release] pointer to memory to free +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemFree("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetAllocProperties( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] memory pointer to query + ze_memory_allocation_properties_t* pMemAllocProperties, ///< [in,out] query result for memory allocation properties + ze_device_handle_t* phDevice ///< [out][optional] device associated with this allocation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetAllocProperties("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "pMemAllocProperties=" << loader::to_string(pMemAllocProperties); + oss << ", "; + oss << "phDevice=" << loader::to_string(phDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetAddressRange( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] memory pointer to query + void** pBase, ///< [in,out][optional] base address of the allocation + size_t* pSize ///< [in,out][optional] size of the allocation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetAddressRange("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "pBase=" << loader::to_string(pBase); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to the device memory allocation + ze_ipc_mem_handle_t* pIpcHandle ///< [out] Returned IPC memory handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "pIpcHandle=" << loader::to_string(pIpcHandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + uint64_t handle, ///< [in] file descriptor + ze_ipc_mem_handle_t* pIpcHandle ///< [out] Returned IPC memory handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetIpcHandleFromFileDescriptorExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "handle=" << loader::to_string(handle); + oss << ", "; + oss << "pIpcHandle=" << loader::to_string(pIpcHandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_ipc_mem_handle_t ipcHandle, ///< [in] IPC memory handle + uint64_t* pHandle ///< [out] Returned file descriptor +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetFileDescriptorFromIpcHandleExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ipcHandle=" << loader::to_string(ipcHandle); + oss << ", "; + oss << "pHandle=" << loader::to_string(pHandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemPutIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_ipc_mem_handle_t handle ///< [in] IPC memory handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemPutIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "handle=" << loader::to_string(handle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemOpenIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device to associate with the IPC memory handle + ze_ipc_mem_handle_t handle, ///< [in] IPC memory handle + ze_ipc_memory_flags_t flags, ///< [in] flags controlling the operation. + ///< must be 0 (default) or a valid combination of ::ze_ipc_memory_flag_t. + void** pptr ///< [out] pointer to device allocation in this process +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemOpenIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "handle=" << loader::to_string(handle); + oss << ", "; + oss << "flags=" << loader::to_string(flags); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemCloseIpcHandle( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr ///< [in][release] pointer to device allocation in this process +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemCloseIpcHandle("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemSetAtomicAccessAttributeExp( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context + ze_device_handle_t hDevice, ///< [in] device associated with the memory advice + const void* ptr, ///< [in] Pointer to the start of the memory range + size_t size, ///< [in] Size in bytes of the memory range + ze_memory_atomic_attr_exp_flags_t attr ///< [in] Atomic access attributes to set for the specified range. + ///< Must be 0 (default) or a valid combination of ::ze_memory_atomic_attr_exp_flag_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemSetAtomicAccessAttributeExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "attr=" << loader::to_string(attr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetAtomicAccessAttributeExp( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context + ze_device_handle_t hDevice, ///< [in] device associated with the memory advice + const void* ptr, ///< [in] Pointer to the start of the memory range + size_t size, ///< [in] Size in bytes of the memory range + ze_memory_atomic_attr_exp_flags_t* pAttr ///< [out] Atomic access attributes for the specified range +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetAtomicAccessAttributeExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "pAttr=" << loader::to_string(pAttr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_module_desc_t* desc, ///< [in] pointer to module descriptor + ze_module_handle_t* phModule, ///< [out] pointer to handle of module object created + ze_module_build_log_handle_t* phBuildLog ///< [out][optional] pointer to handle of module's build log. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phModule=" << loader::to_string(phModule); + oss << ", "; + oss << "phBuildLog=" << loader::to_string(phBuildLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleDestroy( + ze_result_t result, + ze_module_handle_t hModule ///< [in][release] handle of the module +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleDestroy("; + oss << "hModule=" << loader::to_string(hModule); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleDynamicLink( + ze_result_t result, + uint32_t numModules, ///< [in] number of modules to be linked pointed to by phModules. + ze_module_handle_t* phModules, ///< [in][range(0, numModules)] pointer to an array of modules to + ///< dynamically link together. + ze_module_build_log_handle_t* phLinkLog ///< [out][optional] pointer to handle of dynamic link log. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleDynamicLink("; + oss << "numModules=" << loader::to_string(numModules); + oss << ", "; + oss << "phModules=" << loader::to_string(phModules); + oss << ", "; + oss << "phLinkLog=" << loader::to_string(phLinkLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleBuildLogDestroy( + ze_result_t result, + ze_module_build_log_handle_t hModuleBuildLog ///< [in][release] handle of the module build log object. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleBuildLogDestroy("; + oss << "hModuleBuildLog=" << loader::to_string(hModuleBuildLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleBuildLogGetString( + ze_result_t result, + ze_module_build_log_handle_t hModuleBuildLog, ///< [in] handle of the module build log object. + size_t* pSize, ///< [in,out] size of build log string. + char* pBuildLog ///< [in,out][optional] pointer to null-terminated string of the log. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleBuildLogGetString("; + oss << "hModuleBuildLog=" << loader::to_string(hModuleBuildLog); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pBuildLog=" << loader::to_string(pBuildLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleGetNativeBinary( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + size_t* pSize, ///< [in,out] size of native binary in bytes. + uint8_t* pModuleNativeBinary ///< [in,out][optional] byte pointer to native binary +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleGetNativeBinary("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pModuleNativeBinary=" << loader::to_string(pModuleNativeBinary); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleGetGlobalPointer( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + const char* pGlobalName, ///< [in] name of global variable in module + size_t* pSize, ///< [in,out][optional] size of global variable + void** pptr ///< [in,out][optional] device visible pointer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleGetGlobalPointer("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "pGlobalName=" << loader::to_string(pGlobalName); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleGetKernelNames( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + uint32_t* pCount, ///< [in,out] pointer to the number of names. + ///< if count is zero, then the driver shall update the value with the + ///< total number of names available. + ///< if count is greater than the number of names available, then the + ///< driver shall update the value with the correct number of names available. + const char** pNames ///< [in,out][optional][range(0, *pCount)] array of names of functions. + ///< if count is less than the number of names available, then driver shall + ///< only retrieve that number of names. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleGetKernelNames("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pNames=" << loader::to_string(pNames); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleGetProperties( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + ze_module_properties_t* pModuleProperties ///< [in,out] query result for module properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleGetProperties("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "pModuleProperties=" << loader::to_string(pModuleProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelCreate( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + const ze_kernel_desc_t* desc, ///< [in] pointer to kernel descriptor + ze_kernel_handle_t* phKernel ///< [out] handle of the Function object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelCreate("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phKernel=" << loader::to_string(phKernel); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelDestroy( + ze_result_t result, + ze_kernel_handle_t hKernel ///< [in][release] handle of the kernel object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelDestroy("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleGetFunctionPointer( + ze_result_t result, + ze_module_handle_t hModule, ///< [in] handle of the module + const char* pFunctionName, ///< [in] Name of function to retrieve function pointer for. + void** pfnFunction ///< [out] pointer to function. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleGetFunctionPointer("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "pFunctionName=" << loader::to_string(pFunctionName); + oss << ", "; + oss << "pfnFunction=" << loader::to_string(pfnFunction); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSetGroupSize( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t groupSizeX, ///< [in] group size for X dimension to use for this kernel + uint32_t groupSizeY, ///< [in] group size for Y dimension to use for this kernel + uint32_t groupSizeZ ///< [in] group size for Z dimension to use for this kernel +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSetGroupSize("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "groupSizeX=" << loader::to_string(groupSizeX); + oss << ", "; + oss << "groupSizeY=" << loader::to_string(groupSizeY); + oss << ", "; + oss << "groupSizeZ=" << loader::to_string(groupSizeZ); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSuggestGroupSize( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t globalSizeX, ///< [in] global width for X dimension + uint32_t globalSizeY, ///< [in] global width for Y dimension + uint32_t globalSizeZ, ///< [in] global width for Z dimension + uint32_t* groupSizeX, ///< [out] recommended size of group for X dimension + uint32_t* groupSizeY, ///< [out] recommended size of group for Y dimension + uint32_t* groupSizeZ ///< [out] recommended size of group for Z dimension +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSuggestGroupSize("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "globalSizeX=" << loader::to_string(globalSizeX); + oss << ", "; + oss << "globalSizeY=" << loader::to_string(globalSizeY); + oss << ", "; + oss << "globalSizeZ=" << loader::to_string(globalSizeZ); + oss << ", "; + oss << "groupSizeX=" << loader::to_string(groupSizeX); + oss << ", "; + oss << "groupSizeY=" << loader::to_string(groupSizeY); + oss << ", "; + oss << "groupSizeZ=" << loader::to_string(groupSizeZ); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t* totalGroupCount ///< [out] recommended total group count. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSuggestMaxCooperativeGroupCount("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "totalGroupCount=" << loader::to_string(totalGroupCount); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSetArgumentValue( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t argIndex, ///< [in] argument index in range [0, num args - 1] + size_t argSize, ///< [in] size of argument type + const void* pArgValue ///< [in][optional] argument value represented as matching arg type. If + ///< null then argument value is considered null. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSetArgumentValue("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "argIndex=" << loader::to_string(argIndex); + oss << ", "; + oss << "argSize=" << loader::to_string(argSize); + oss << ", "; + oss << "pArgValue=" << loader::to_string(pArgValue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSetIndirectAccess( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + ze_kernel_indirect_access_flags_t flags ///< [in] kernel indirect access flags +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSetIndirectAccess("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "flags=" << loader::to_string(flags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetIndirectAccess( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + ze_kernel_indirect_access_flags_t* pFlags ///< [out] query result for kernel indirect access flags. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetIndirectAccess("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pFlags=" << loader::to_string(pFlags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetSourceAttributes( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t* pSize, ///< [in,out] pointer to size of string in bytes, including + ///< null-terminating character. + char** pString ///< [in,out][optional] pointer to application-managed character array + ///< (string data). + ///< If NULL, the string length of the kernel source attributes, including + ///< a null-terminating character, is returned in pSize. Otherwise, pString + ///< must point to valid application memory that is greater than or equal + ///< to *pSize bytes in length, and on return the pointed-to string will + ///< contain a space-separated list of kernel source attributes. Note: This + ///< API was originally intended to ship with a char *pString, however this + ///< typo was introduced. Thus the API has to stay this way for backwards + ///< compatible reasons. It can be corrected in v2.0. Suggestion is to + ///< create your own char *pString and then pass to this API with &pString. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetSourceAttributes("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pString=" << loader::to_string(pString); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSetCacheConfig( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + ze_cache_config_flags_t flags ///< [in] cache configuration. + ///< must be 0 (default configuration) or a valid combination of ::ze_cache_config_flag_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSetCacheConfig("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "flags=" << loader::to_string(flags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetProperties( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + ze_kernel_properties_t* pKernelProperties ///< [in,out] query result for kernel properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetProperties("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pKernelProperties=" << loader::to_string(pKernelProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetName( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + size_t* pSize, ///< [in,out] size of kernel name string, including null terminator, in + ///< bytes. + char* pName ///< [in,out][optional] char pointer to kernel name. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetName("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pName=" << loader::to_string(pName); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchKernel( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + const ze_group_count_t* pLaunchFuncArgs, ///< [in] thread group launch arguments + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchKernel("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pLaunchFuncArgs=" << loader::to_string(pLaunchFuncArgs); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + const ze_group_count_t* pGroupCounts, ///< [in] thread group launch arguments + const void * pNext, ///< [in][optional] additional parameters passed to the function + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchKernelWithParameters("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pGroupCounts=" << loader::to_string(pGroupCounts); + oss << ", "; + oss << "pNext=" << loader::to_string(pNext); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + const ze_group_count_t groupCounts, ///< [in] thread group counts + const ze_group_size_t groupSizes, ///< [in] thread group sizes + void ** pArguments, ///< [in]pointer to an array of pointers + const void * pNext, ///< [in][optional] additional extensions passed to the function + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchKernelWithArguments("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "groupCounts=" << loader::to_string(groupCounts); + oss << ", "; + oss << "groupSizes=" << loader::to_string(groupSizes); + oss << ", "; + oss << "pArguments=" << loader::to_string(pArguments); + oss << ", "; + oss << "pNext=" << loader::to_string(pNext); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + const ze_group_count_t* pLaunchFuncArgs, ///< [in] thread group launch arguments + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchCooperativeKernel("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pLaunchFuncArgs=" << loader::to_string(pLaunchFuncArgs); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + const ze_group_count_t* pLaunchArgumentsBuffer, ///< [in] pointer to device buffer that will contain thread group launch + ///< arguments + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchKernelIndirect("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pLaunchArgumentsBuffer=" << loader::to_string(pLaunchArgumentsBuffer); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t numKernels, ///< [in] maximum number of kernels to launch + ze_kernel_handle_t* phKernels, ///< [in][range(0, numKernels)] handles of the kernel objects + const uint32_t* pCountBuffer, ///< [in] pointer to device memory location that will contain the actual + ///< number of kernels to launch; value must be less than or equal to + ///< numKernels + const ze_group_count_t* pLaunchArgumentsBuffer, ///< [in][range(0, numKernels)] pointer to device buffer that will contain + ///< a contiguous array of thread group launch arguments + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendLaunchMultipleKernelsIndirect("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numKernels=" << loader::to_string(numKernels); + oss << ", "; + oss << "phKernels=" << loader::to_string(phKernels); + oss << ", "; + oss << "pCountBuffer=" << loader::to_string(pCountBuffer); + oss << ", "; + oss << "pLaunchArgumentsBuffer=" << loader::to_string(pLaunchArgumentsBuffer); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextMakeMemoryResident( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context object + ze_device_handle_t hDevice, ///< [in] handle of the device + void* ptr, ///< [in] pointer to memory to make resident + size_t size ///< [in] size in bytes to make resident +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextMakeMemoryResident("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextEvictMemory( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context object + ze_device_handle_t hDevice, ///< [in] handle of the device + void* ptr, ///< [in] pointer to memory to evict + size_t size ///< [in] size in bytes to evict +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextEvictMemory("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextMakeImageResident( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context object + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_image_handle_t hImage ///< [in] handle of image to make resident +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextMakeImageResident("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hImage=" << loader::to_string(hImage); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeContextEvictImage( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of context object + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_image_handle_t hImage ///< [in] handle of image to make evict +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeContextEvictImage("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hImage=" << loader::to_string(hImage); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeSamplerCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_sampler_desc_t* desc, ///< [in] pointer to sampler descriptor + ze_sampler_handle_t* phSampler ///< [out] handle of the sampler +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeSamplerCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phSampler=" << loader::to_string(phSampler); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeSamplerDestroy( + ze_result_t result, + ze_sampler_handle_t hSampler ///< [in][release] handle of the sampler +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeSamplerDestroy("; + oss << "hSampler=" << loader::to_string(hSampler); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemReserve( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* pStart, ///< [in][optional] pointer to start of region to reserve. If nullptr then + ///< implementation will choose a start address. + size_t size, ///< [in] size in bytes to reserve; must be page aligned. + void** pptr ///< [out] pointer to virtual reservation. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemReserve("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "pStart=" << loader::to_string(pStart); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "pptr=" << loader::to_string(pptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemFree( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to start of region to free. + size_t size ///< [in] size in bytes to free; must be page aligned. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemFree("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemQueryPageSize( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device object + size_t size, ///< [in] unaligned allocation size in bytes + size_t* pagesize ///< [out] pointer to page size to use for start address and size + ///< alignments. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemQueryPageSize("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "pagesize=" << loader::to_string(pagesize); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zePhysicalMemCreate( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device object, can be `nullptr` if creating + ///< physical host memory. + ze_physical_mem_desc_t* desc, ///< [in] pointer to physical memory descriptor. + ze_physical_mem_handle_t* phPhysicalMemory ///< [out] pointer to handle of physical memory object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zePhysicalMemCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phPhysicalMemory=" << loader::to_string(phPhysicalMemory); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zePhysicalMemDestroy( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_physical_mem_handle_t hPhysicalMemory ///< [in][release] handle of physical memory object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zePhysicalMemDestroy("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hPhysicalMemory=" << loader::to_string(hPhysicalMemory); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemMap( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to start of virtual address range to map. + size_t size, ///< [in] size in bytes of virtual address range to map; must be page + ///< aligned. + ze_physical_mem_handle_t hPhysicalMemory, ///< [in] handle to physical memory object. + size_t offset, ///< [in] offset into physical memory allocation object; must be page + ///< aligned. + ze_memory_access_attribute_t access ///< [in] specifies page access attributes to apply to the virtual address + ///< range. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemMap("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "hPhysicalMemory=" << loader::to_string(hPhysicalMemory); + oss << ", "; + oss << "offset=" << loader::to_string(offset); + oss << ", "; + oss << "access=" << loader::to_string(access); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemUnmap( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to start of region to unmap. + size_t size ///< [in] size in bytes to unmap; must be page aligned. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemUnmap("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemSetAccessAttribute( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to start of reserved virtual address region. + size_t size, ///< [in] size in bytes; must be page aligned. + ze_memory_access_attribute_t access ///< [in] specifies page access attributes to apply to the virtual address + ///< range. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemSetAccessAttribute("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "access=" << loader::to_string(access); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeVirtualMemGetAccessAttribute( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const void* ptr, ///< [in] pointer to start of virtual address region for query. + size_t size, ///< [in] size in bytes; must be page aligned. + ze_memory_access_attribute_t* access, ///< [out] query result for page access attribute. + size_t* outSize ///< [out] query result for size of virtual address range, starting at ptr, + ///< that shares same access attribute. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeVirtualMemGetAccessAttribute("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "access=" << loader::to_string(access); + oss << ", "; + oss << "outSize=" << loader::to_string(outSize); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSetGlobalOffsetExp( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + uint32_t offsetX, ///< [in] global offset for X dimension to use for this kernel + uint32_t offsetY, ///< [in] global offset for Y dimension to use for this kernel + uint32_t offsetZ ///< [in] global offset for Z dimension to use for this kernel +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSetGlobalOffsetExp("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "offsetX=" << loader::to_string(offsetX); + oss << ", "; + oss << "offsetY=" << loader::to_string(offsetY); + oss << ", "; + oss << "offsetZ=" << loader::to_string(offsetZ); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetBinaryExp( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] Kernel handle. + size_t* pSize, ///< [in,out] pointer to variable with size of GEN ISA binary. + uint8_t* pKernelBinary ///< [in,out] pointer to storage area for GEN ISA binary function. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetBinaryExp("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pKernelBinary=" << loader::to_string(pKernelBinary); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceImportExternalSemaphoreExt( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] The device handle. + const ze_external_semaphore_ext_desc_t* desc, ///< [in] The pointer to external semaphore descriptor. + ze_external_semaphore_ext_handle_t* phSemaphore ///< [out] The handle of the external semaphore imported. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceImportExternalSemaphoreExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phSemaphore=" << loader::to_string(phSemaphore); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt( + ze_result_t result, + ze_external_semaphore_ext_handle_t hSemaphore ///< [in] The handle of the external semaphore. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceReleaseExternalSemaphoreExt("; + oss << "hSemaphore=" << loader::to_string(hSemaphore); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] The command list handle. + uint32_t numSemaphores, ///< [in] The number of external semaphores. + ze_external_semaphore_ext_handle_t* phSemaphores, ///< [in][range(0, numSemaphores)] The vector of external semaphore handles + ///< to be appended into command list. + ze_external_semaphore_signal_params_ext_t* signalParams,///< [in] Signal parameters. + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendSignalExternalSemaphoreExt("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numSemaphores=" << loader::to_string(numSemaphores); + oss << ", "; + oss << "phSemaphores=" << loader::to_string(phSemaphores); + oss << ", "; + oss << "signalParams=" << loader::to_string(signalParams); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] The command list handle. + uint32_t numSemaphores, ///< [in] The number of external semaphores. + ze_external_semaphore_ext_handle_t* phSemaphores, ///< [in] [range(0,numSemaphores)] The vector of external semaphore handles + ///< to append into command list. + ze_external_semaphore_wait_params_ext_t* waitParams,///< [in] Wait parameters. + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendWaitExternalSemaphoreExt("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numSemaphores=" << loader::to_string(numSemaphores); + oss << ", "; + oss << "phSemaphores=" << loader::to_string(phSemaphores); + oss << ", "; + oss << "waitParams=" << loader::to_string(waitParams); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderCreateExt( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + const ze_rtas_builder_ext_desc_t* pDescriptor, ///< [in] pointer to builder descriptor + ze_rtas_builder_ext_handle_t* phBuilder ///< [out] handle of builder object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderCreateExt("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pDescriptor=" << loader::to_string(pDescriptor); + oss << ", "; + oss << "phBuilder=" << loader::to_string(phBuilder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt( + ze_result_t result, + ze_rtas_builder_ext_handle_t hBuilder, ///< [in] handle of builder object + const ze_rtas_builder_build_op_ext_desc_t* pBuildOpDescriptor, ///< [in] pointer to build operation descriptor + ze_rtas_builder_ext_properties_t* pProperties ///< [in,out] query result for builder properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderGetBuildPropertiesExt("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ", "; + oss << "pBuildOpDescriptor=" << loader::to_string(pBuildOpDescriptor); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + ze_rtas_format_ext_t rtasFormatA, ///< [in] operand A + ze_rtas_format_ext_t rtasFormatB ///< [in] operand B +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverRTASFormatCompatibilityCheckExt("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "rtasFormatA=" << loader::to_string(rtasFormatA); + oss << ", "; + oss << "rtasFormatB=" << loader::to_string(rtasFormatB); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderBuildExt( + ze_result_t result, + ze_rtas_builder_ext_handle_t hBuilder, ///< [in] handle of builder object + const ze_rtas_builder_build_op_ext_desc_t* pBuildOpDescriptor, ///< [in] pointer to build operation descriptor + void* pScratchBuffer, ///< [in][range(0, `scratchBufferSizeBytes`)] scratch buffer to be used + ///< during acceleration structure construction + size_t scratchBufferSizeBytes, ///< [in] size of scratch buffer, in bytes + void* pRtasBuffer, ///< [in] pointer to destination buffer + size_t rtasBufferSizeBytes, ///< [in] destination buffer size, in bytes + ze_rtas_parallel_operation_ext_handle_t hParallelOperation, ///< [in][optional] handle to parallel operation object + void* pBuildUserPtr, ///< [in][optional] pointer passed to callbacks + ze_rtas_aabb_ext_t* pBounds, ///< [in,out][optional] pointer to destination address for acceleration + ///< structure bounds + size_t* pRtasBufferSizeBytes ///< [out][optional] updated acceleration structure size requirement, in + ///< bytes +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderBuildExt("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ", "; + oss << "pBuildOpDescriptor=" << loader::to_string(pBuildOpDescriptor); + oss << ", "; + oss << "pScratchBuffer=" << loader::to_string(pScratchBuffer); + oss << ", "; + oss << "scratchBufferSizeBytes=" << loader::to_string(scratchBufferSizeBytes); + oss << ", "; + oss << "pRtasBuffer=" << loader::to_string(pRtasBuffer); + oss << ", "; + oss << "rtasBufferSizeBytes=" << loader::to_string(rtasBufferSizeBytes); + oss << ", "; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ", "; + oss << "pBuildUserPtr=" << loader::to_string(pBuildUserPtr); + oss << ", "; + oss << "pBounds=" << loader::to_string(pBounds); + oss << ", "; + oss << "pRtasBufferSizeBytes=" << loader::to_string(pRtasBufferSizeBytes); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination in device memory to copy the ray tracing + ///< acceleration structure to + const void* srcptr, ///< [in] pointer to a valid source ray tracing acceleration structure in + ///< host memory to copy from + size_t size, ///< [in] size in bytes to copy + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderCommandListAppendCopyExt("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderDestroyExt( + ze_result_t result, + ze_rtas_builder_ext_handle_t hBuilder ///< [in][release] handle of builder object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderDestroyExt("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationCreateExt( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + ze_rtas_parallel_operation_ext_handle_t* phParallelOperation///< [out] handle of parallel operation object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationCreateExt("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "phParallelOperation=" << loader::to_string(phParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt( + ze_result_t result, + ze_rtas_parallel_operation_ext_handle_t hParallelOperation, ///< [in] handle of parallel operation object + ze_rtas_parallel_operation_ext_properties_t* pProperties///< [in,out] query result for parallel operation properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationGetPropertiesExt("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationJoinExt( + ze_result_t result, + ze_rtas_parallel_operation_ext_handle_t hParallelOperation ///< [in] handle of parallel operation object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationJoinExt("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationDestroyExt( + ze_result_t result, + ze_rtas_parallel_operation_ext_handle_t hParallelOperation ///< [in][release] handle of parallel operation object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationDestroyExt("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of vector width properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of vector width properties available. + ///< if count is greater than the number of vector width properties + ///< available, then the driver shall update the value with the correct + ///< number of vector width properties available. + ze_device_vector_width_properties_ext_t* pVectorWidthProperties ///< [in,out][optional][range(0, *pCount)] array of vector width properties. + ///< if count is less than the number of properties available, then the + ///< driver will return only the number requested. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetVectorWidthPropertiesExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pVectorWidthProperties=" << loader::to_string(pVectorWidthProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelGetAllocationPropertiesExp( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] Kernel handle. + uint32_t* pCount, ///< [in,out] pointer to the number of kernel allocation properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of kernel allocation properties available. + ///< if count is greater than the number of kernel allocation properties + ///< available, then the driver shall update the value with the correct + ///< number of kernel allocation properties. + ze_kernel_allocation_exp_properties_t* pAllocationProperties///< [in,out][optional][range(0, *pCount)] array of kernel allocation properties. + ///< if count is less than the number of kernel allocation properties + ///< available, then driver shall only retrieve that number of kernel + ///< allocation properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelGetAllocationPropertiesExp("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pAllocationProperties=" << loader::to_string(pAllocationProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceReserveCacheExt( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device object + size_t cacheLevel, ///< [in] cache level where application want to reserve. If zero, then the + ///< driver shall default to last level of cache and attempt to reserve in + ///< that cache. + size_t cacheReservationSize ///< [in] value for reserving size, in bytes. If zero, then the driver + ///< shall remove prior reservation +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceReserveCacheExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "cacheLevel=" << loader::to_string(cacheLevel); + oss << ", "; + oss << "cacheReservationSize=" << loader::to_string(cacheReservationSize); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceSetCacheAdviceExt( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device object + void* ptr, ///< [in] memory pointer to query + size_t regionSize, ///< [in] region size, in pages + ze_cache_ext_region_t cacheRegion ///< [in] reservation region +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceSetCacheAdviceExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ", "; + oss << "regionSize=" << loader::to_string(regionSize); + oss << ", "; + oss << "cacheRegion=" << loader::to_string(cacheRegion); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventQueryTimestampsExp( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_device_handle_t hDevice, ///< [in] handle of the device to query + uint32_t* pCount, ///< [in,out] pointer to the number of timestamp results. + ///< if count is zero, then the driver shall update the value with the + ///< total number of timestamps available. + ///< if count is greater than the number of timestamps available, then the + ///< driver shall update the value with the correct number of timestamps available. + ze_kernel_timestamp_result_t* pTimestamps ///< [in,out][optional][range(0, *pCount)] array of timestamp results. + ///< if count is less than the number of timestamps available, then driver + ///< shall only retrieve that number of timestamps. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventQueryTimestampsExp("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pTimestamps=" << loader::to_string(pTimestamps); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageGetMemoryPropertiesExp( + ze_result_t result, + ze_image_handle_t hImage, ///< [in] handle of image object + ze_image_memory_properties_exp_t* pMemoryProperties ///< [in,out] query result for image memory properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageGetMemoryPropertiesExp("; + oss << "hImage=" << loader::to_string(hImage); + oss << ", "; + oss << "pMemoryProperties=" << loader::to_string(pMemoryProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageViewCreateExt( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_image_desc_t* desc, ///< [in] pointer to image descriptor + ze_image_handle_t hImage, ///< [in] handle of image object to create view from + ze_image_handle_t* phImageView ///< [out] pointer to handle of image object created for view +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageViewCreateExt("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "hImage=" << loader::to_string(hImage); + oss << ", "; + oss << "phImageView=" << loader::to_string(phImageView); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageViewCreateExp( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + const ze_image_desc_t* desc, ///< [in] pointer to image descriptor + ze_image_handle_t hImage, ///< [in] handle of image object to create view from + ze_image_handle_t* phImageView ///< [out] pointer to handle of image object created for view +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageViewCreateExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "hImage=" << loader::to_string(hImage); + oss << ", "; + oss << "phImageView=" << loader::to_string(phImageView); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeKernelSchedulingHintExp( + ze_result_t result, + ze_kernel_handle_t hKernel, ///< [in] handle of the kernel object + ze_scheduling_hint_exp_desc_t* pHint ///< [in] pointer to kernel scheduling hint descriptor +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeKernelSchedulingHintExp("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pHint=" << loader::to_string(pHint); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDevicePciGetPropertiesExt( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device object. + ze_pci_ext_properties_t* pPciProperties ///< [in,out] returns the PCI properties of the device. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDevicePciGetPropertiesExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pPciProperties=" << loader::to_string(pPciProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + void* dstptr, ///< [in] pointer to destination memory to copy to + ze_image_handle_t hSrcImage, ///< [in] handle of source image to copy from + const ze_image_region_t* pSrcRegion, ///< [in][optional] source region descriptor + uint32_t destRowPitch, ///< [in] size in bytes of the 1D slice of the 2D region of a 2D or 3D + ///< image or each image of a 1D or 2D image array being written + uint32_t destSlicePitch, ///< [in] size in bytes of the 2D slice of the 3D region of a 3D image or + ///< each image of a 1D or 2D image array being written + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopyToMemoryExt("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "dstptr=" << loader::to_string(dstptr); + oss << ", "; + oss << "hSrcImage=" << loader::to_string(hSrcImage); + oss << ", "; + oss << "pSrcRegion=" << loader::to_string(pSrcRegion); + oss << ", "; + oss << "destRowPitch=" << loader::to_string(destRowPitch); + oss << ", "; + oss << "destSlicePitch=" << loader::to_string(destSlicePitch); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of command list + ze_image_handle_t hDstImage, ///< [in] handle of destination image to copy to + const void* srcptr, ///< [in] pointer to source memory to copy from + const ze_image_region_t* pDstRegion, ///< [in][optional] destination region descriptor + uint32_t srcRowPitch, ///< [in] size in bytes of the 1D slice of the 2D region of a 2D or 3D + ///< image or each image of a 1D or 2D image array being read + uint32_t srcSlicePitch, ///< [in] size in bytes of the 2D slice of the 3D region of a 3D image or + ///< each image of a 1D or 2D image array being read + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before launching; must be 0 + ///< if `nullptr == phWaitEvents` + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListAppendImageCopyFromMemoryExt("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hDstImage=" << loader::to_string(hDstImage); + oss << ", "; + oss << "srcptr=" << loader::to_string(srcptr); + oss << ", "; + oss << "pDstRegion=" << loader::to_string(pDstRegion); + oss << ", "; + oss << "srcRowPitch=" << loader::to_string(srcRowPitch); + oss << ", "; + oss << "srcSlicePitch=" << loader::to_string(srcSlicePitch); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageGetAllocPropertiesExt( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_image_handle_t hImage, ///< [in] handle of image object to query + ze_image_allocation_ext_properties_t* pImageAllocProperties ///< [in,out] query result for image allocation properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageGetAllocPropertiesExt("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hImage=" << loader::to_string(hImage); + oss << ", "; + oss << "pImageAllocProperties=" << loader::to_string(pImageAllocProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeModuleInspectLinkageExt( + ze_result_t result, + ze_linkage_inspection_ext_desc_t* pInspectDesc, ///< [in] pointer to linkage inspection descriptor structure. + uint32_t numModules, ///< [in] number of modules to be inspected pointed to by phModules. + ze_module_handle_t* phModules, ///< [in][range(0, numModules)] pointer to an array of modules to be + ///< inspected for import dependencies. + ze_module_build_log_handle_t* phLog ///< [out] pointer to handle of linkage inspection log. Log object will + ///< contain separate lists of imports, un-resolvable imports, and exports. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeModuleInspectLinkageExt("; + oss << "pInspectDesc=" << loader::to_string(pInspectDesc); + oss << ", "; + oss << "numModules=" << loader::to_string(numModules); + oss << ", "; + oss << "phModules=" << loader::to_string(phModules); + oss << ", "; + oss << "phLog=" << loader::to_string(phLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemFreeExt( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + const ze_memory_free_ext_desc_t* pMemFreeDesc, ///< [in] pointer to memory free descriptor + void* ptr ///< [in][release] pointer to memory to free +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemFreeExt("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "pMemFreeDesc=" << loader::to_string(pMemFreeDesc); + oss << ", "; + oss << "ptr=" << loader::to_string(ptr); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricVertexGetExp( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint32_t* pCount, ///< [in,out] pointer to the number of fabric vertices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of fabric vertices available. + ///< if count is greater than the number of fabric vertices available, then + ///< the driver shall update the value with the correct number of fabric + ///< vertices available. + ze_fabric_vertex_handle_t* phVertices ///< [in,out][optional][range(0, *pCount)] array of handle of fabric vertices. + ///< if count is less than the number of fabric vertices available, then + ///< driver shall only retrieve that number of fabric vertices. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricVertexGetExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phVertices=" << loader::to_string(phVertices); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricVertexGetSubVerticesExp( + ze_result_t result, + ze_fabric_vertex_handle_t hVertex, ///< [in] handle of the fabric vertex object + uint32_t* pCount, ///< [in,out] pointer to the number of sub-vertices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of sub-vertices available. + ///< if count is greater than the number of sub-vertices available, then + ///< the driver shall update the value with the correct number of + ///< sub-vertices available. + ze_fabric_vertex_handle_t* phSubvertices ///< [in,out][optional][range(0, *pCount)] array of handle of sub-vertices. + ///< if count is less than the number of sub-vertices available, then + ///< driver shall only retrieve that number of sub-vertices. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricVertexGetSubVerticesExp("; + oss << "hVertex=" << loader::to_string(hVertex); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phSubvertices=" << loader::to_string(phSubvertices); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricVertexGetPropertiesExp( + ze_result_t result, + ze_fabric_vertex_handle_t hVertex, ///< [in] handle of the fabric vertex + ze_fabric_vertex_exp_properties_t* pVertexProperties///< [in,out] query result for fabric vertex properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricVertexGetPropertiesExp("; + oss << "hVertex=" << loader::to_string(hVertex); + oss << ", "; + oss << "pVertexProperties=" << loader::to_string(pVertexProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricVertexGetDeviceExp( + ze_result_t result, + ze_fabric_vertex_handle_t hVertex, ///< [in] handle of the fabric vertex + ze_device_handle_t* phDevice ///< [out] device handle corresponding to fabric vertex +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricVertexGetDeviceExp("; + oss << "hVertex=" << loader::to_string(hVertex); + oss << ", "; + oss << "phDevice=" << loader::to_string(phDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDeviceGetFabricVertexExp( + ze_result_t result, + ze_device_handle_t hDevice, ///< [in] handle of the device + ze_fabric_vertex_handle_t* phVertex ///< [out] fabric vertex handle corresponding to device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDeviceGetFabricVertexExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "phVertex=" << loader::to_string(phVertex); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricEdgeGetExp( + ze_result_t result, + ze_fabric_vertex_handle_t hVertexA, ///< [in] handle of first fabric vertex instance + ze_fabric_vertex_handle_t hVertexB, ///< [in] handle of second fabric vertex instance + uint32_t* pCount, ///< [in,out] pointer to the number of fabric edges. + ///< if count is zero, then the driver shall update the value with the + ///< total number of fabric edges available. + ///< if count is greater than the number of fabric edges available, then + ///< the driver shall update the value with the correct number of fabric + ///< edges available. + ze_fabric_edge_handle_t* phEdges ///< [in,out][optional][range(0, *pCount)] array of handle of fabric edges. + ///< if count is less than the number of fabric edges available, then + ///< driver shall only retrieve that number of fabric edges. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricEdgeGetExp("; + oss << "hVertexA=" << loader::to_string(hVertexA); + oss << ", "; + oss << "hVertexB=" << loader::to_string(hVertexB); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phEdges=" << loader::to_string(phEdges); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricEdgeGetVerticesExp( + ze_result_t result, + ze_fabric_edge_handle_t hEdge, ///< [in] handle of the fabric edge instance + ze_fabric_vertex_handle_t* phVertexA, ///< [out] fabric vertex connected to one end of the given fabric edge. + ze_fabric_vertex_handle_t* phVertexB ///< [out] fabric vertex connected to other end of the given fabric edge. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricEdgeGetVerticesExp("; + oss << "hEdge=" << loader::to_string(hEdge); + oss << ", "; + oss << "phVertexA=" << loader::to_string(phVertexA); + oss << ", "; + oss << "phVertexB=" << loader::to_string(phVertexB); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeFabricEdgeGetPropertiesExp( + ze_result_t result, + ze_fabric_edge_handle_t hEdge, ///< [in] handle of the fabric edge + ze_fabric_edge_exp_properties_t* pEdgeProperties///< [in,out] query result for fabric edge properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeFabricEdgeGetPropertiesExp("; + oss << "hEdge=" << loader::to_string(hEdge); + oss << ", "; + oss << "pEdgeProperties=" << loader::to_string(pEdgeProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeEventQueryKernelTimestampsExt( + ze_result_t result, + ze_event_handle_t hEvent, ///< [in] handle of the event + ze_device_handle_t hDevice, ///< [in] handle of the device to query + uint32_t* pCount, ///< [in,out] pointer to the number of event packets available. + ///< - This value is implementation specific. + ///< - if `*pCount` is zero, then the driver shall update the value with + ///< the total number of event packets available. + ///< - if `*pCount` is greater than the number of event packets + ///< available, the driver shall update the value with the correct value. + ///< - Buffer(s) for query results must be sized by the application to + ///< accommodate a minimum of `*pCount` elements. + ze_event_query_kernel_timestamps_results_ext_properties_t* pResults ///< [in,out][optional][range(0, *pCount)] pointer to event query + ///< properties structure(s). + ///< - This parameter may be null when `*pCount` is zero. + ///< - if `*pCount` is less than the number of event packets available, + ///< the driver may only update `*pCount` elements, starting at element zero. + ///< - if `*pCount` is greater than the number of event packets + ///< available, the driver may only update the valid elements. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeEventQueryKernelTimestampsExt("; + oss << "hEvent=" << loader::to_string(hEvent); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pResults=" << loader::to_string(pResults); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderCreateExp( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + const ze_rtas_builder_exp_desc_t* pDescriptor, ///< [in] pointer to builder descriptor + ze_rtas_builder_exp_handle_t* phBuilder ///< [out] handle of builder object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderCreateExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pDescriptor=" << loader::to_string(pDescriptor); + oss << ", "; + oss << "phBuilder=" << loader::to_string(phBuilder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp( + ze_result_t result, + ze_rtas_builder_exp_handle_t hBuilder, ///< [in] handle of builder object + const ze_rtas_builder_build_op_exp_desc_t* pBuildOpDescriptor, ///< [in] pointer to build operation descriptor + ze_rtas_builder_exp_properties_t* pProperties ///< [in,out] query result for builder properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderGetBuildPropertiesExp("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ", "; + oss << "pBuildOpDescriptor=" << loader::to_string(pBuildOpDescriptor); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + ze_rtas_format_exp_t rtasFormatA, ///< [in] operand A + ze_rtas_format_exp_t rtasFormatB ///< [in] operand B +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeDriverRTASFormatCompatibilityCheckExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "rtasFormatA=" << loader::to_string(rtasFormatA); + oss << ", "; + oss << "rtasFormatB=" << loader::to_string(rtasFormatB); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderBuildExp( + ze_result_t result, + ze_rtas_builder_exp_handle_t hBuilder, ///< [in] handle of builder object + const ze_rtas_builder_build_op_exp_desc_t* pBuildOpDescriptor, ///< [in] pointer to build operation descriptor + void* pScratchBuffer, ///< [in][range(0, `scratchBufferSizeBytes`)] scratch buffer to be used + ///< during acceleration structure construction + size_t scratchBufferSizeBytes, ///< [in] size of scratch buffer, in bytes + void* pRtasBuffer, ///< [in] pointer to destination buffer + size_t rtasBufferSizeBytes, ///< [in] destination buffer size, in bytes + ze_rtas_parallel_operation_exp_handle_t hParallelOperation, ///< [in][optional] handle to parallel operation object + void* pBuildUserPtr, ///< [in][optional] pointer passed to callbacks + ze_rtas_aabb_exp_t* pBounds, ///< [in,out][optional] pointer to destination address for acceleration + ///< structure bounds + size_t* pRtasBufferSizeBytes ///< [out][optional] updated acceleration structure size requirement, in + ///< bytes +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderBuildExp("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ", "; + oss << "pBuildOpDescriptor=" << loader::to_string(pBuildOpDescriptor); + oss << ", "; + oss << "pScratchBuffer=" << loader::to_string(pScratchBuffer); + oss << ", "; + oss << "scratchBufferSizeBytes=" << loader::to_string(scratchBufferSizeBytes); + oss << ", "; + oss << "pRtasBuffer=" << loader::to_string(pRtasBuffer); + oss << ", "; + oss << "rtasBufferSizeBytes=" << loader::to_string(rtasBufferSizeBytes); + oss << ", "; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ", "; + oss << "pBuildUserPtr=" << loader::to_string(pBuildUserPtr); + oss << ", "; + oss << "pBounds=" << loader::to_string(pBounds); + oss << ", "; + oss << "pRtasBufferSizeBytes=" << loader::to_string(pRtasBufferSizeBytes); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASBuilderDestroyExp( + ze_result_t result, + ze_rtas_builder_exp_handle_t hBuilder ///< [in][release] handle of builder object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASBuilderDestroyExp("; + oss << "hBuilder=" << loader::to_string(hBuilder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationCreateExp( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of driver object + ze_rtas_parallel_operation_exp_handle_t* phParallelOperation///< [out] handle of parallel operation object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationCreateExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "phParallelOperation=" << loader::to_string(phParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp( + ze_result_t result, + ze_rtas_parallel_operation_exp_handle_t hParallelOperation, ///< [in] handle of parallel operation object + ze_rtas_parallel_operation_exp_properties_t* pProperties///< [in,out] query result for parallel operation properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationGetPropertiesExp("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationJoinExp( + ze_result_t result, + ze_rtas_parallel_operation_exp_handle_t hParallelOperation ///< [in] handle of parallel operation object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationJoinExp("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeRTASParallelOperationDestroyExp( + ze_result_t result, + ze_rtas_parallel_operation_exp_handle_t hParallelOperation ///< [in][release] handle of parallel operation object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeRTASParallelOperationDestroyExp("; + oss << "hParallelOperation=" << loader::to_string(hParallelOperation); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeMemGetPitchFor2dImage( + ze_result_t result, + ze_context_handle_t hContext, ///< [in] handle of the context object + ze_device_handle_t hDevice, ///< [in] handle of the device + size_t imageWidth, ///< [in] imageWidth + size_t imageHeight, ///< [in] imageHeight + unsigned int elementSizeInBytes, ///< [in] Element size in bytes + size_t * rowPitch ///< [out] rowPitch +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeMemGetPitchFor2dImage("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "imageWidth=" << loader::to_string(imageWidth); + oss << ", "; + oss << "imageHeight=" << loader::to_string(imageHeight); + oss << ", "; + oss << "elementSizeInBytes=" << loader::to_string(elementSizeInBytes); + oss << ", "; + oss << "rowPitch=" << loader::to_string(rowPitch); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeImageGetDeviceOffsetExp( + ze_result_t result, + ze_image_handle_t hImage, ///< [in] handle of the image + uint64_t* pDeviceOffset ///< [out] bindless device offset for image +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeImageGetDeviceOffsetExp("; + oss << "hImage=" << loader::to_string(hImage); + oss << ", "; + oss << "pDeviceOffset=" << loader::to_string(pDeviceOffset); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListCreateCloneExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle to source command list (the command list to clone) + ze_command_list_handle_t* phClonedCommandList ///< [out] pointer to handle of the cloned command list +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListCreateCloneExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "phClonedCommandList=" << loader::to_string(phClonedCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp( + ze_result_t result, + ze_command_list_handle_t hCommandListImmediate, ///< [in] handle of the immediate command list + uint32_t numCommandLists, ///< [in] number of command lists + ze_command_list_handle_t* phCommandLists, ///< [in][range(0, numCommandLists)] handles of command lists + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + ///< - if not null, this event is signaled after the completion of all + ///< appended command lists + uint32_t numWaitEvents, ///< [in][optional] number of events to wait on before executing appended + ///< command lists; must be 0 if nullptr == phWaitEvents + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before executing appended command lists. + ///< - if not null, all wait events must be satisfied prior to the start + ///< of any appended command list(s) +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListImmediateAppendCommandListsExp("; + oss << "hCommandListImmediate=" << loader::to_string(hCommandListImmediate); + oss << ", "; + oss << "numCommandLists=" << loader::to_string(numCommandLists); + oss << ", "; + oss << "phCommandLists=" << loader::to_string(phCommandLists); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListGetNextCommandIdExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + const ze_mutable_command_id_exp_desc_t* desc, ///< [in] pointer to mutable command identifier descriptor + uint64_t* pCommandId ///< [out] pointer to mutable command identifier to be written +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListGetNextCommandIdExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "pCommandId=" << loader::to_string(pCommandId); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + const ze_mutable_command_id_exp_desc_t* desc, ///< [in][out] pointer to mutable command identifier descriptor + uint32_t numKernels, ///< [in][optional] number of entries on phKernels list + ze_kernel_handle_t* phKernels, ///< [in][optional][range(0, numKernels)] list of kernels that user can + ///< switch between using ::zeCommandListUpdateMutableCommandKernelsExp + ///< call + uint64_t* pCommandId ///< [out] pointer to mutable command identifier to be written +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListGetNextCommandIdWithKernelsExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "numKernels=" << loader::to_string(numKernels); + oss << ", "; + oss << "phKernels=" << loader::to_string(phKernels); + oss << ", "; + oss << "pCommandId=" << loader::to_string(pCommandId); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListUpdateMutableCommandsExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + const ze_mutable_commands_exp_desc_t* desc ///< [in] pointer to mutable commands descriptor; multiple descriptors may + ///< be chained via `pNext` member +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListUpdateMutableCommandsExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint64_t commandId, ///< [in] command identifier + ze_event_handle_t hSignalEvent ///< [in][optional] handle of the event to signal on completion +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListUpdateMutableCommandSignalEventExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "commandId=" << loader::to_string(commandId); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint64_t commandId, ///< [in] command identifier + uint32_t numWaitEvents, ///< [in][optional] the number of wait events + ze_event_handle_t* phWaitEvents ///< [in][optional][range(0, numWaitEvents)] handle of the events to wait + ///< on before launching +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListUpdateMutableCommandWaitEventsExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "commandId=" << loader::to_string(commandId); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp( + ze_result_t result, + ze_command_list_handle_t hCommandList, ///< [in] handle of the command list + uint32_t numKernels, ///< [in] the number of kernels to update + uint64_t* pCommandId, ///< [in][range(0, numKernels)] command identifier + ze_kernel_handle_t* phKernels ///< [in][range(0, numKernels)] handle of the kernel for a command + ///< identifier to switch to +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zeCommandListUpdateMutableCommandKernelsExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "numKernels=" << loader::to_string(numKernels); + oss << ", "; + oss << "pCommandId=" << loader::to_string(pCommandId); + oss << ", "; + oss << "phKernels=" << loader::to_string(phKernels); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + // Special function for zexCounterBasedEventCreate2 + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zexCounterBasedEventCreate2( + ze_result_t result, + ze_context_handle_t hContext, + ze_device_handle_t hDevice, + const void* desc, + ze_event_handle_t* phEvent + ) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zexCounterBasedEventCreate2(" + << "hContext=" << static_cast(hContext) << ", " + << "hDevice=" << static_cast(hDevice) << ", " + << "desc=" << desc << ", " + << "phEvent=" << static_cast(phEvent) << ")"; + context.logger->log_trace(oss.str()); return result; } @@ -42,12 +4285,12 @@ namespace validation_layer auto pfnInit = context.zeDdiTable.Global.pfnInit; if( nullptr == pfnInit ) - return logAndPropagateResult("zeInit", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeInit(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, flags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeInitPrologue( flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInit(result, flags); } @@ -58,17 +4301,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeInitPrologue( flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInit(result, flags); } auto driver_result = pfnInit( flags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeInitEpilogue( flags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInit(result, flags); } - return logAndPropagateResult("zeInit", driver_result); + return logAndPropagateResult_zeInit(driver_result, flags); } /////////////////////////////////////////////////////////////////////////////// @@ -90,12 +4333,12 @@ namespace validation_layer auto pfnGet = context.zeDdiTable.Driver.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zeDriverGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, pCount, phDrivers); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetPrologue( pCount, phDrivers ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGet(result, pCount, phDrivers); } @@ -106,14 +4349,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetPrologue( pCount, phDrivers ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGet(result, pCount, phDrivers); } auto driver_result = pfnGet( pCount, phDrivers ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetEpilogue( pCount, phDrivers ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGet(result, pCount, phDrivers); } @@ -126,7 +4369,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeDriverGet", driver_result); + return logAndPropagateResult_zeDriverGet(driver_result, pCount, phDrivers); } /////////////////////////////////////////////////////////////////////////////// @@ -150,12 +4393,12 @@ namespace validation_layer auto pfnInitDrivers = context.zeDdiTable.Global.pfnInitDrivers; if( nullptr == pfnInitDrivers ) - return logAndPropagateResult("zeInitDrivers", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeInitDrivers(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, pCount, phDrivers, desc); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeInitDriversPrologue( pCount, phDrivers, desc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInitDrivers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInitDrivers(result, pCount, phDrivers, desc); } @@ -166,17 +4409,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeInitDriversPrologue( pCount, phDrivers, desc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInitDrivers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInitDrivers(result, pCount, phDrivers, desc); } auto driver_result = pfnInitDrivers( pCount, phDrivers, desc ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeInitDriversEpilogue( pCount, phDrivers, desc ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeInitDrivers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeInitDrivers(result, pCount, phDrivers, desc); } - return logAndPropagateResult("zeInitDrivers", driver_result); + return logAndPropagateResult_zeInitDrivers(driver_result, pCount, phDrivers, desc); } /////////////////////////////////////////////////////////////////////////////// @@ -192,12 +4435,12 @@ namespace validation_layer auto pfnGetApiVersion = context.zeDdiTable.Driver.pfnGetApiVersion; if( nullptr == pfnGetApiVersion ) - return logAndPropagateResult("zeDriverGetApiVersion", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetApiVersion(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, version); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetApiVersionPrologue( hDriver, version ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetApiVersion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetApiVersion(result, hDriver, version); } @@ -208,17 +4451,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetApiVersionPrologue( hDriver, version ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetApiVersion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetApiVersion(result, hDriver, version); } auto driver_result = pfnGetApiVersion( hDriver, version ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetApiVersionEpilogue( hDriver, version ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetApiVersion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetApiVersion(result, hDriver, version); } - return logAndPropagateResult("zeDriverGetApiVersion", driver_result); + return logAndPropagateResult_zeDriverGetApiVersion(driver_result, hDriver, version); } /////////////////////////////////////////////////////////////////////////////// @@ -234,12 +4477,12 @@ namespace validation_layer auto pfnGetProperties = context.zeDdiTable.Driver.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zeDriverGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pDriverProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetPropertiesPrologue( hDriver, pDriverProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetProperties(result, hDriver, pDriverProperties); } @@ -250,17 +4493,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetPropertiesPrologue( hDriver, pDriverProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetProperties(result, hDriver, pDriverProperties); } auto driver_result = pfnGetProperties( hDriver, pDriverProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetPropertiesEpilogue( hDriver, pDriverProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetProperties(result, hDriver, pDriverProperties); } - return logAndPropagateResult("zeDriverGetProperties", driver_result); + return logAndPropagateResult_zeDriverGetProperties(driver_result, hDriver, pDriverProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -276,12 +4519,12 @@ namespace validation_layer auto pfnGetIpcProperties = context.zeDdiTable.Driver.pfnGetIpcProperties; if( nullptr == pfnGetIpcProperties ) - return logAndPropagateResult("zeDriverGetIpcProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetIpcProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pIpcProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetIpcPropertiesPrologue( hDriver, pIpcProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetIpcProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetIpcProperties(result, hDriver, pIpcProperties); } @@ -292,17 +4535,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetIpcPropertiesPrologue( hDriver, pIpcProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetIpcProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetIpcProperties(result, hDriver, pIpcProperties); } auto driver_result = pfnGetIpcProperties( hDriver, pIpcProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetIpcPropertiesEpilogue( hDriver, pIpcProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetIpcProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetIpcProperties(result, hDriver, pIpcProperties); } - return logAndPropagateResult("zeDriverGetIpcProperties", driver_result); + return logAndPropagateResult_zeDriverGetIpcProperties(driver_result, hDriver, pIpcProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -327,12 +4570,12 @@ namespace validation_layer auto pfnGetExtensionProperties = context.zeDdiTable.Driver.pfnGetExtensionProperties; if( nullptr == pfnGetExtensionProperties ) - return logAndPropagateResult("zeDriverGetExtensionProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetExtensionProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pCount, pExtensionProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetExtensionPropertiesPrologue( hDriver, pCount, pExtensionProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } @@ -343,17 +4586,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetExtensionPropertiesPrologue( hDriver, pCount, pExtensionProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } auto driver_result = pfnGetExtensionProperties( hDriver, pCount, pExtensionProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetExtensionPropertiesEpilogue( hDriver, pCount, pExtensionProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } - return logAndPropagateResult("zeDriverGetExtensionProperties", driver_result); + return logAndPropagateResult_zeDriverGetExtensionProperties(driver_result, hDriver, pCount, pExtensionProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -370,12 +4613,12 @@ namespace validation_layer auto pfnGetExtensionFunctionAddress = context.zeDdiTable.Driver.pfnGetExtensionFunctionAddress; if( nullptr == pfnGetExtensionFunctionAddress ) - return logAndPropagateResult("zeDriverGetExtensionFunctionAddress", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetExtensionFunctionAddress(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, name, ppFunctionAddress); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetExtensionFunctionAddressPrologue( hDriver, name, ppFunctionAddress ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } @@ -386,7 +4629,7 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetExtensionFunctionAddressPrologue( hDriver, name, ppFunctionAddress ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } auto driver_result = pfnGetExtensionFunctionAddress( hDriver, name, ppFunctionAddress ); @@ -402,10 +4645,10 @@ namespace validation_layer for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetExtensionFunctionAddressEpilogue( hDriver, name, ppFunctionAddress ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } - return logAndPropagateResult("zeDriverGetExtensionFunctionAddress", driver_result); + return logAndPropagateResult_zeDriverGetExtensionFunctionAddress(driver_result, hDriver, name, ppFunctionAddress); } /////////////////////////////////////////////////////////////////////////////// @@ -422,12 +4665,12 @@ namespace validation_layer auto pfnGetLastErrorDescription = context.zeDdiTable.Driver.pfnGetLastErrorDescription; if( nullptr == pfnGetLastErrorDescription ) - return logAndPropagateResult("zeDriverGetLastErrorDescription", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverGetLastErrorDescription(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, ppString); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetLastErrorDescriptionPrologue( hDriver, ppString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetLastErrorDescription(result, hDriver, ppString); } @@ -438,17 +4681,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverGetLastErrorDescriptionPrologue( hDriver, ppString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetLastErrorDescription(result, hDriver, ppString); } auto driver_result = pfnGetLastErrorDescription( hDriver, ppString ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverGetLastErrorDescriptionEpilogue( hDriver, ppString ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverGetLastErrorDescription(result, hDriver, ppString); } - return logAndPropagateResult("zeDriverGetLastErrorDescription", driver_result); + return logAndPropagateResult_zeDriverGetLastErrorDescription(driver_result, hDriver, ppString); } /////////////////////////////////////////////////////////////////////////////// @@ -512,12 +4755,12 @@ namespace validation_layer auto pfnGet = context.zeDdiTable.Device.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zeDeviceGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pCount, phDevices); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetPrologue( hDriver, pCount, phDevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGet(result, hDriver, pCount, phDevices); } @@ -528,14 +4771,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetPrologue( hDriver, pCount, phDevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGet(result, hDriver, pCount, phDevices); } auto driver_result = pfnGet( hDriver, pCount, phDevices ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetEpilogue( hDriver, pCount, phDevices ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGet(result, hDriver, pCount, phDevices); } @@ -548,7 +4791,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeDeviceGet", driver_result); + return logAndPropagateResult_zeDeviceGet(driver_result, hDriver, pCount, phDevices); } /////////////////////////////////////////////////////////////////////////////// @@ -564,12 +4807,12 @@ namespace validation_layer auto pfnGetRootDevice = context.zeDdiTable.Device.pfnGetRootDevice; if( nullptr == pfnGetRootDevice ) - return logAndPropagateResult("zeDeviceGetRootDevice", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetRootDevice(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, phRootDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetRootDevicePrologue( hDevice, phRootDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetRootDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetRootDevice(result, hDevice, phRootDevice); } @@ -580,17 +4823,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetRootDevicePrologue( hDevice, phRootDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetRootDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetRootDevice(result, hDevice, phRootDevice); } auto driver_result = pfnGetRootDevice( hDevice, phRootDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetRootDeviceEpilogue( hDevice, phRootDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetRootDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetRootDevice(result, hDevice, phRootDevice); } - return logAndPropagateResult("zeDeviceGetRootDevice", driver_result); + return logAndPropagateResult_zeDeviceGetRootDevice(driver_result, hDevice, phRootDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -613,12 +4856,12 @@ namespace validation_layer auto pfnGetSubDevices = context.zeDdiTable.Device.pfnGetSubDevices; if( nullptr == pfnGetSubDevices ) - return logAndPropagateResult("zeDeviceGetSubDevices", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetSubDevices(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phSubdevices); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetSubDevicesPrologue( hDevice, pCount, phSubdevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetSubDevices", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetSubDevices(result, hDevice, pCount, phSubdevices); } @@ -629,14 +4872,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetSubDevicesPrologue( hDevice, pCount, phSubdevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetSubDevices", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetSubDevices(result, hDevice, pCount, phSubdevices); } auto driver_result = pfnGetSubDevices( hDevice, pCount, phSubdevices ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetSubDevicesEpilogue( hDevice, pCount, phSubdevices ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetSubDevices", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetSubDevices(result, hDevice, pCount, phSubdevices); } @@ -649,7 +4892,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeDeviceGetSubDevices", driver_result); + return logAndPropagateResult_zeDeviceGetSubDevices(driver_result, hDevice, pCount, phSubdevices); } /////////////////////////////////////////////////////////////////////////////// @@ -665,12 +4908,12 @@ namespace validation_layer auto pfnGetProperties = context.zeDdiTable.Device.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zeDeviceGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pDeviceProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetPropertiesPrologue( hDevice, pDeviceProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetProperties(result, hDevice, pDeviceProperties); } @@ -681,17 +4924,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetPropertiesPrologue( hDevice, pDeviceProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetProperties(result, hDevice, pDeviceProperties); } auto driver_result = pfnGetProperties( hDevice, pDeviceProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetPropertiesEpilogue( hDevice, pDeviceProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetProperties(result, hDevice, pDeviceProperties); } - return logAndPropagateResult("zeDeviceGetProperties", driver_result); + return logAndPropagateResult_zeDeviceGetProperties(driver_result, hDevice, pDeviceProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -707,12 +4950,12 @@ namespace validation_layer auto pfnGetComputeProperties = context.zeDdiTable.Device.pfnGetComputeProperties; if( nullptr == pfnGetComputeProperties ) - return logAndPropagateResult("zeDeviceGetComputeProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetComputeProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pComputeProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetComputePropertiesPrologue( hDevice, pComputeProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetComputeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetComputeProperties(result, hDevice, pComputeProperties); } @@ -723,17 +4966,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetComputePropertiesPrologue( hDevice, pComputeProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetComputeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetComputeProperties(result, hDevice, pComputeProperties); } auto driver_result = pfnGetComputeProperties( hDevice, pComputeProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetComputePropertiesEpilogue( hDevice, pComputeProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetComputeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetComputeProperties(result, hDevice, pComputeProperties); } - return logAndPropagateResult("zeDeviceGetComputeProperties", driver_result); + return logAndPropagateResult_zeDeviceGetComputeProperties(driver_result, hDevice, pComputeProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -749,12 +4992,12 @@ namespace validation_layer auto pfnGetModuleProperties = context.zeDdiTable.Device.pfnGetModuleProperties; if( nullptr == pfnGetModuleProperties ) - return logAndPropagateResult("zeDeviceGetModuleProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetModuleProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pModuleProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetModulePropertiesPrologue( hDevice, pModuleProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetModuleProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetModuleProperties(result, hDevice, pModuleProperties); } @@ -765,17 +5008,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetModulePropertiesPrologue( hDevice, pModuleProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetModuleProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetModuleProperties(result, hDevice, pModuleProperties); } auto driver_result = pfnGetModuleProperties( hDevice, pModuleProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetModulePropertiesEpilogue( hDevice, pModuleProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetModuleProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetModuleProperties(result, hDevice, pModuleProperties); } - return logAndPropagateResult("zeDeviceGetModuleProperties", driver_result); + return logAndPropagateResult_zeDeviceGetModuleProperties(driver_result, hDevice, pModuleProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -801,12 +5044,12 @@ namespace validation_layer auto pfnGetCommandQueueGroupProperties = context.zeDdiTable.Device.pfnGetCommandQueueGroupProperties; if( nullptr == pfnGetCommandQueueGroupProperties ) - return logAndPropagateResult("zeDeviceGetCommandQueueGroupProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pCommandQueueGroupProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetCommandQueueGroupPropertiesPrologue( hDevice, pCount, pCommandQueueGroupProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCommandQueueGroupProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties(result, hDevice, pCount, pCommandQueueGroupProperties); } @@ -817,17 +5060,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetCommandQueueGroupPropertiesPrologue( hDevice, pCount, pCommandQueueGroupProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCommandQueueGroupProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties(result, hDevice, pCount, pCommandQueueGroupProperties); } auto driver_result = pfnGetCommandQueueGroupProperties( hDevice, pCount, pCommandQueueGroupProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetCommandQueueGroupPropertiesEpilogue( hDevice, pCount, pCommandQueueGroupProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCommandQueueGroupProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties(result, hDevice, pCount, pCommandQueueGroupProperties); } - return logAndPropagateResult("zeDeviceGetCommandQueueGroupProperties", driver_result); + return logAndPropagateResult_zeDeviceGetCommandQueueGroupProperties(driver_result, hDevice, pCount, pCommandQueueGroupProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -852,12 +5095,12 @@ namespace validation_layer auto pfnGetMemoryProperties = context.zeDdiTable.Device.pfnGetMemoryProperties; if( nullptr == pfnGetMemoryProperties ) - return logAndPropagateResult("zeDeviceGetMemoryProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetMemoryProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pMemProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetMemoryPropertiesPrologue( hDevice, pCount, pMemProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryProperties(result, hDevice, pCount, pMemProperties); } @@ -868,17 +5111,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetMemoryPropertiesPrologue( hDevice, pCount, pMemProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryProperties(result, hDevice, pCount, pMemProperties); } auto driver_result = pfnGetMemoryProperties( hDevice, pCount, pMemProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetMemoryPropertiesEpilogue( hDevice, pCount, pMemProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryProperties(result, hDevice, pCount, pMemProperties); } - return logAndPropagateResult("zeDeviceGetMemoryProperties", driver_result); + return logAndPropagateResult_zeDeviceGetMemoryProperties(driver_result, hDevice, pCount, pMemProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -894,12 +5137,12 @@ namespace validation_layer auto pfnGetMemoryAccessProperties = context.zeDdiTable.Device.pfnGetMemoryAccessProperties; if( nullptr == pfnGetMemoryAccessProperties ) - return logAndPropagateResult("zeDeviceGetMemoryAccessProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetMemoryAccessProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pMemAccessProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetMemoryAccessPropertiesPrologue( hDevice, pMemAccessProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryAccessProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryAccessProperties(result, hDevice, pMemAccessProperties); } @@ -910,17 +5153,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetMemoryAccessPropertiesPrologue( hDevice, pMemAccessProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryAccessProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryAccessProperties(result, hDevice, pMemAccessProperties); } auto driver_result = pfnGetMemoryAccessProperties( hDevice, pMemAccessProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetMemoryAccessPropertiesEpilogue( hDevice, pMemAccessProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetMemoryAccessProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetMemoryAccessProperties(result, hDevice, pMemAccessProperties); } - return logAndPropagateResult("zeDeviceGetMemoryAccessProperties", driver_result); + return logAndPropagateResult_zeDeviceGetMemoryAccessProperties(driver_result, hDevice, pMemAccessProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -944,12 +5187,12 @@ namespace validation_layer auto pfnGetCacheProperties = context.zeDdiTable.Device.pfnGetCacheProperties; if( nullptr == pfnGetCacheProperties ) - return logAndPropagateResult("zeDeviceGetCacheProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetCacheProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pCacheProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetCachePropertiesPrologue( hDevice, pCount, pCacheProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCacheProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCacheProperties(result, hDevice, pCount, pCacheProperties); } @@ -960,17 +5203,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetCachePropertiesPrologue( hDevice, pCount, pCacheProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCacheProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCacheProperties(result, hDevice, pCount, pCacheProperties); } auto driver_result = pfnGetCacheProperties( hDevice, pCount, pCacheProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetCachePropertiesEpilogue( hDevice, pCount, pCacheProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetCacheProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetCacheProperties(result, hDevice, pCount, pCacheProperties); } - return logAndPropagateResult("zeDeviceGetCacheProperties", driver_result); + return logAndPropagateResult_zeDeviceGetCacheProperties(driver_result, hDevice, pCount, pCacheProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -986,12 +5229,12 @@ namespace validation_layer auto pfnGetImageProperties = context.zeDdiTable.Device.pfnGetImageProperties; if( nullptr == pfnGetImageProperties ) - return logAndPropagateResult("zeDeviceGetImageProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetImageProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pImageProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetImagePropertiesPrologue( hDevice, pImageProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetImageProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetImageProperties(result, hDevice, pImageProperties); } @@ -1002,17 +5245,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetImagePropertiesPrologue( hDevice, pImageProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetImageProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetImageProperties(result, hDevice, pImageProperties); } auto driver_result = pfnGetImageProperties( hDevice, pImageProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetImagePropertiesEpilogue( hDevice, pImageProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetImageProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetImageProperties(result, hDevice, pImageProperties); } - return logAndPropagateResult("zeDeviceGetImageProperties", driver_result); + return logAndPropagateResult_zeDeviceGetImageProperties(driver_result, hDevice, pImageProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1028,12 +5271,12 @@ namespace validation_layer auto pfnGetExternalMemoryProperties = context.zeDdiTable.Device.pfnGetExternalMemoryProperties; if( nullptr == pfnGetExternalMemoryProperties ) - return logAndPropagateResult("zeDeviceGetExternalMemoryProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetExternalMemoryProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pExternalMemoryProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetExternalMemoryPropertiesPrologue( hDevice, pExternalMemoryProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetExternalMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetExternalMemoryProperties(result, hDevice, pExternalMemoryProperties); } @@ -1044,17 +5287,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetExternalMemoryPropertiesPrologue( hDevice, pExternalMemoryProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetExternalMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetExternalMemoryProperties(result, hDevice, pExternalMemoryProperties); } auto driver_result = pfnGetExternalMemoryProperties( hDevice, pExternalMemoryProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetExternalMemoryPropertiesEpilogue( hDevice, pExternalMemoryProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetExternalMemoryProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetExternalMemoryProperties(result, hDevice, pExternalMemoryProperties); } - return logAndPropagateResult("zeDeviceGetExternalMemoryProperties", driver_result); + return logAndPropagateResult_zeDeviceGetExternalMemoryProperties(driver_result, hDevice, pExternalMemoryProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1071,12 +5314,12 @@ namespace validation_layer auto pfnGetP2PProperties = context.zeDdiTable.Device.pfnGetP2PProperties; if( nullptr == pfnGetP2PProperties ) - return logAndPropagateResult("zeDeviceGetP2PProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetP2PProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, hPeerDevice, pP2PProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetP2PPropertiesPrologue( hDevice, hPeerDevice, pP2PProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetP2PProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetP2PProperties(result, hDevice, hPeerDevice, pP2PProperties); } @@ -1087,17 +5330,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetP2PPropertiesPrologue( hDevice, hPeerDevice, pP2PProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetP2PProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetP2PProperties(result, hDevice, hPeerDevice, pP2PProperties); } auto driver_result = pfnGetP2PProperties( hDevice, hPeerDevice, pP2PProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetP2PPropertiesEpilogue( hDevice, hPeerDevice, pP2PProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetP2PProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetP2PProperties(result, hDevice, hPeerDevice, pP2PProperties); } - return logAndPropagateResult("zeDeviceGetP2PProperties", driver_result); + return logAndPropagateResult_zeDeviceGetP2PProperties(driver_result, hDevice, hPeerDevice, pP2PProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1114,12 +5357,12 @@ namespace validation_layer auto pfnCanAccessPeer = context.zeDdiTable.Device.pfnCanAccessPeer; if( nullptr == pfnCanAccessPeer ) - return logAndPropagateResult("zeDeviceCanAccessPeer", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceCanAccessPeer(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, hPeerDevice, value); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceCanAccessPeerPrologue( hDevice, hPeerDevice, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceCanAccessPeer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceCanAccessPeer(result, hDevice, hPeerDevice, value); } @@ -1130,17 +5373,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceCanAccessPeerPrologue( hDevice, hPeerDevice, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceCanAccessPeer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceCanAccessPeer(result, hDevice, hPeerDevice, value); } auto driver_result = pfnCanAccessPeer( hDevice, hPeerDevice, value ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceCanAccessPeerEpilogue( hDevice, hPeerDevice, value ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceCanAccessPeer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceCanAccessPeer(result, hDevice, hPeerDevice, value); } - return logAndPropagateResult("zeDeviceCanAccessPeer", driver_result); + return logAndPropagateResult_zeDeviceCanAccessPeer(driver_result, hDevice, hPeerDevice, value); } /////////////////////////////////////////////////////////////////////////////// @@ -1155,12 +5398,12 @@ namespace validation_layer auto pfnGetStatus = context.zeDdiTable.Device.pfnGetStatus; if( nullptr == pfnGetStatus ) - return logAndPropagateResult("zeDeviceGetStatus", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetStatus(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetStatusPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetStatus(result, hDevice); } @@ -1171,17 +5414,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetStatusPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetStatus(result, hDevice); } auto driver_result = pfnGetStatus( hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetStatusEpilogue( hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetStatus(result, hDevice); } - return logAndPropagateResult("zeDeviceGetStatus", driver_result); + return logAndPropagateResult_zeDeviceGetStatus(driver_result, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -1200,12 +5443,12 @@ namespace validation_layer auto pfnGetGlobalTimestamps = context.zeDdiTable.Device.pfnGetGlobalTimestamps; if( nullptr == pfnGetGlobalTimestamps ) - return logAndPropagateResult("zeDeviceGetGlobalTimestamps", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetGlobalTimestamps(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, hostTimestamp, deviceTimestamp); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetGlobalTimestampsPrologue( hDevice, hostTimestamp, deviceTimestamp ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetGlobalTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetGlobalTimestamps(result, hDevice, hostTimestamp, deviceTimestamp); } @@ -1216,17 +5459,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetGlobalTimestampsPrologue( hDevice, hostTimestamp, deviceTimestamp ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetGlobalTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetGlobalTimestamps(result, hDevice, hostTimestamp, deviceTimestamp); } auto driver_result = pfnGetGlobalTimestamps( hDevice, hostTimestamp, deviceTimestamp ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetGlobalTimestampsEpilogue( hDevice, hostTimestamp, deviceTimestamp ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetGlobalTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetGlobalTimestamps(result, hDevice, hostTimestamp, deviceTimestamp); } - return logAndPropagateResult("zeDeviceGetGlobalTimestamps", driver_result); + return logAndPropagateResult_zeDeviceGetGlobalTimestamps(driver_result, hDevice, hostTimestamp, deviceTimestamp); } /////////////////////////////////////////////////////////////////////////////// @@ -1241,12 +5484,12 @@ namespace validation_layer auto pfnSynchronize = context.zeDdiTable.Device.pfnSynchronize; if( nullptr == pfnSynchronize ) - return logAndPropagateResult("zeDeviceSynchronize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceSynchronize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceSynchronizePrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSynchronize(result, hDevice); } @@ -1257,17 +5500,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceSynchronizePrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSynchronize(result, hDevice); } auto driver_result = pfnSynchronize( hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceSynchronizeEpilogue( hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSynchronize(result, hDevice); } - return logAndPropagateResult("zeDeviceSynchronize", driver_result); + return logAndPropagateResult_zeDeviceSynchronize(driver_result, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -1284,12 +5527,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Context.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeContextCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, desc, phContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextCreatePrologue( hDriver, desc, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreate(result, hDriver, desc, phContext); } @@ -1300,14 +5543,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextCreatePrologue( hDriver, desc, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreate(result, hDriver, desc, phContext); } auto driver_result = pfnCreate( hDriver, desc, phContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextCreateEpilogue( hDriver, desc, phContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreate(result, hDriver, desc, phContext); } @@ -1319,7 +5562,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeContextCreate", driver_result); + return logAndPropagateResult_zeContextCreate(driver_result, hDriver, desc, phContext); } /////////////////////////////////////////////////////////////////////////////// @@ -1346,12 +5589,12 @@ namespace validation_layer auto pfnCreateEx = context.zeDdiTable.Context.pfnCreateEx; if( nullptr == pfnCreateEx ) - return logAndPropagateResult("zeContextCreateEx", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextCreateEx(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, desc, numDevices, phDevices, phContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextCreateExPrologue( hDriver, desc, numDevices, phDevices, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreateEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreateEx(result, hDriver, desc, numDevices, phDevices, phContext); } @@ -1362,14 +5605,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextCreateExPrologue( hDriver, desc, numDevices, phDevices, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreateEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreateEx(result, hDriver, desc, numDevices, phDevices, phContext); } auto driver_result = pfnCreateEx( hDriver, desc, numDevices, phDevices, phContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextCreateExEpilogue( hDriver, desc, numDevices, phDevices, phContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextCreateEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextCreateEx(result, hDriver, desc, numDevices, phDevices, phContext); } @@ -1381,7 +5624,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeContextCreateEx", driver_result); + return logAndPropagateResult_zeContextCreateEx(driver_result, hDriver, desc, numDevices, phDevices, phContext); } /////////////////////////////////////////////////////////////////////////////// @@ -1396,12 +5639,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Context.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeContextDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextDestroyPrologue( hContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextDestroy(result, hContext); } @@ -1412,17 +5655,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextDestroyPrologue( hContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextDestroy(result, hContext); } auto driver_result = pfnDestroy( hContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextDestroyEpilogue( hContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextDestroy(result, hContext); } - return logAndPropagateResult("zeContextDestroy", driver_result); + return logAndPropagateResult_zeContextDestroy(driver_result, hContext); } /////////////////////////////////////////////////////////////////////////////// @@ -1437,12 +5680,12 @@ namespace validation_layer auto pfnGetStatus = context.zeDdiTable.Context.pfnGetStatus; if( nullptr == pfnGetStatus ) - return logAndPropagateResult("zeContextGetStatus", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextGetStatus(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextGetStatusPrologue( hContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextGetStatus(result, hContext); } @@ -1453,17 +5696,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextGetStatusPrologue( hContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextGetStatus(result, hContext); } auto driver_result = pfnGetStatus( hContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextGetStatusEpilogue( hContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextGetStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextGetStatus(result, hContext); } - return logAndPropagateResult("zeContextGetStatus", driver_result); + return logAndPropagateResult_zeContextGetStatus(driver_result, hContext); } /////////////////////////////////////////////////////////////////////////////// @@ -1481,12 +5724,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.CommandQueue.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeCommandQueueCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phCommandQueue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueCreatePrologue( hContext, hDevice, desc, phCommandQueue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueCreate(result, hContext, hDevice, desc, phCommandQueue); } @@ -1497,14 +5740,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueCreatePrologue( hContext, hDevice, desc, phCommandQueue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueCreate(result, hContext, hDevice, desc, phCommandQueue); } auto driver_result = pfnCreate( hContext, hDevice, desc, phCommandQueue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueCreateEpilogue( hContext, hDevice, desc, phCommandQueue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueCreate(result, hContext, hDevice, desc, phCommandQueue); } @@ -1516,7 +5759,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeCommandQueueCreate", driver_result); + return logAndPropagateResult_zeCommandQueueCreate(driver_result, hContext, hDevice, desc, phCommandQueue); } /////////////////////////////////////////////////////////////////////////////// @@ -1531,12 +5774,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.CommandQueue.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeCommandQueueDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueDestroyPrologue( hCommandQueue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueDestroy(result, hCommandQueue); } @@ -1547,17 +5790,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueDestroyPrologue( hCommandQueue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueDestroy(result, hCommandQueue); } auto driver_result = pfnDestroy( hCommandQueue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueDestroyEpilogue( hCommandQueue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueDestroy(result, hCommandQueue); } - return logAndPropagateResult("zeCommandQueueDestroy", driver_result); + return logAndPropagateResult_zeCommandQueueDestroy(driver_result, hCommandQueue); } /////////////////////////////////////////////////////////////////////////////// @@ -1576,12 +5819,12 @@ namespace validation_layer auto pfnExecuteCommandLists = context.zeDdiTable.CommandQueue.pfnExecuteCommandLists; if( nullptr == pfnExecuteCommandLists ) - return logAndPropagateResult("zeCommandQueueExecuteCommandLists", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueExecuteCommandLists(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue, numCommandLists, phCommandLists, hFence); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueExecuteCommandListsPrologue( hCommandQueue, numCommandLists, phCommandLists, hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueExecuteCommandLists", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueExecuteCommandLists(result, hCommandQueue, numCommandLists, phCommandLists, hFence); } @@ -1592,17 +5835,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueExecuteCommandListsPrologue( hCommandQueue, numCommandLists, phCommandLists, hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueExecuteCommandLists", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueExecuteCommandLists(result, hCommandQueue, numCommandLists, phCommandLists, hFence); } auto driver_result = pfnExecuteCommandLists( hCommandQueue, numCommandLists, phCommandLists, hFence ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueExecuteCommandListsEpilogue( hCommandQueue, numCommandLists, phCommandLists, hFence ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueExecuteCommandLists", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueExecuteCommandLists(result, hCommandQueue, numCommandLists, phCommandLists, hFence); } - return logAndPropagateResult("zeCommandQueueExecuteCommandLists", driver_result); + return logAndPropagateResult_zeCommandQueueExecuteCommandLists(driver_result, hCommandQueue, numCommandLists, phCommandLists, hFence); } /////////////////////////////////////////////////////////////////////////////// @@ -1624,12 +5867,12 @@ namespace validation_layer auto pfnSynchronize = context.zeDdiTable.CommandQueue.pfnSynchronize; if( nullptr == pfnSynchronize ) - return logAndPropagateResult("zeCommandQueueSynchronize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueSynchronize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue, timeout); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueSynchronizePrologue( hCommandQueue, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueSynchronize(result, hCommandQueue, timeout); } @@ -1640,17 +5883,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueSynchronizePrologue( hCommandQueue, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueSynchronize(result, hCommandQueue, timeout); } auto driver_result = pfnSynchronize( hCommandQueue, timeout ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueSynchronizeEpilogue( hCommandQueue, timeout ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueSynchronize(result, hCommandQueue, timeout); } - return logAndPropagateResult("zeCommandQueueSynchronize", driver_result); + return logAndPropagateResult_zeCommandQueueSynchronize(driver_result, hCommandQueue, timeout); } /////////////////////////////////////////////////////////////////////////////// @@ -1666,12 +5909,12 @@ namespace validation_layer auto pfnGetOrdinal = context.zeDdiTable.CommandQueue.pfnGetOrdinal; if( nullptr == pfnGetOrdinal ) - return logAndPropagateResult("zeCommandQueueGetOrdinal", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueGetOrdinal(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue, pOrdinal); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueGetOrdinalPrologue( hCommandQueue, pOrdinal ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetOrdinal(result, hCommandQueue, pOrdinal); } @@ -1682,17 +5925,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueGetOrdinalPrologue( hCommandQueue, pOrdinal ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetOrdinal(result, hCommandQueue, pOrdinal); } auto driver_result = pfnGetOrdinal( hCommandQueue, pOrdinal ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueGetOrdinalEpilogue( hCommandQueue, pOrdinal ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetOrdinal(result, hCommandQueue, pOrdinal); } - return logAndPropagateResult("zeCommandQueueGetOrdinal", driver_result); + return logAndPropagateResult_zeCommandQueueGetOrdinal(driver_result, hCommandQueue, pOrdinal); } /////////////////////////////////////////////////////////////////////////////// @@ -1708,12 +5951,12 @@ namespace validation_layer auto pfnGetIndex = context.zeDdiTable.CommandQueue.pfnGetIndex; if( nullptr == pfnGetIndex ) - return logAndPropagateResult("zeCommandQueueGetIndex", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandQueueGetIndex(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue, pIndex); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueGetIndexPrologue( hCommandQueue, pIndex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetIndex(result, hCommandQueue, pIndex); } @@ -1724,17 +5967,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandQueueGetIndexPrologue( hCommandQueue, pIndex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetIndex(result, hCommandQueue, pIndex); } auto driver_result = pfnGetIndex( hCommandQueue, pIndex ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandQueueGetIndexEpilogue( hCommandQueue, pIndex ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandQueueGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandQueueGetIndex(result, hCommandQueue, pIndex); } - return logAndPropagateResult("zeCommandQueueGetIndex", driver_result); + return logAndPropagateResult_zeCommandQueueGetIndex(driver_result, hCommandQueue, pIndex); } /////////////////////////////////////////////////////////////////////////////// @@ -1752,12 +5995,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.CommandList.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeCommandListCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreatePrologue( hContext, hDevice, desc, phCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreate(result, hContext, hDevice, desc, phCommandList); } @@ -1768,14 +6011,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListCreatePrologue( hContext, hDevice, desc, phCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreate(result, hContext, hDevice, desc, phCommandList); } auto driver_result = pfnCreate( hContext, hDevice, desc, phCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreateEpilogue( hContext, hDevice, desc, phCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreate(result, hContext, hDevice, desc, phCommandList); } @@ -1787,7 +6030,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeCommandListCreate", driver_result); + return logAndPropagateResult_zeCommandListCreate(driver_result, hContext, hDevice, desc, phCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1805,12 +6048,12 @@ namespace validation_layer auto pfnCreateImmediate = context.zeDdiTable.CommandList.pfnCreateImmediate; if( nullptr == pfnCreateImmediate ) - return logAndPropagateResult("zeCommandListCreateImmediate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListCreateImmediate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, altdesc, phCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreateImmediatePrologue( hContext, hDevice, altdesc, phCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateImmediate(result, hContext, hDevice, altdesc, phCommandList); } @@ -1821,14 +6064,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListCreateImmediatePrologue( hContext, hDevice, altdesc, phCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateImmediate(result, hContext, hDevice, altdesc, phCommandList); } auto driver_result = pfnCreateImmediate( hContext, hDevice, altdesc, phCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreateImmediateEpilogue( hContext, hDevice, altdesc, phCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateImmediate(result, hContext, hDevice, altdesc, phCommandList); } @@ -1838,7 +6081,7 @@ namespace validation_layer context.handleLifetime->addHandle( *phCommandList , false); } } - return logAndPropagateResult("zeCommandListCreateImmediate", driver_result); + return logAndPropagateResult_zeCommandListCreateImmediate(driver_result, hContext, hDevice, altdesc, phCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1853,12 +6096,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.CommandList.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeCommandListDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListDestroyPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListDestroy(result, hCommandList); } @@ -1869,17 +6112,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListDestroyPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListDestroy(result, hCommandList); } auto driver_result = pfnDestroy( hCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListDestroyEpilogue( hCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListDestroy(result, hCommandList); } - return logAndPropagateResult("zeCommandListDestroy", driver_result); + return logAndPropagateResult_zeCommandListDestroy(driver_result, hCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1894,12 +6137,12 @@ namespace validation_layer auto pfnClose = context.zeDdiTable.CommandList.pfnClose; if( nullptr == pfnClose ) - return logAndPropagateResult("zeCommandListClose", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListClose(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListClosePrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListClose(result, hCommandList); } @@ -1910,17 +6153,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListClosePrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListClose(result, hCommandList); } auto driver_result = pfnClose( hCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCloseEpilogue( hCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListClose(result, hCommandList); } - return logAndPropagateResult("zeCommandListClose", driver_result); + return logAndPropagateResult_zeCommandListClose(driver_result, hCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1935,12 +6178,12 @@ namespace validation_layer auto pfnReset = context.zeDdiTable.CommandList.pfnReset; if( nullptr == pfnReset ) - return logAndPropagateResult("zeCommandListReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListResetPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListReset(result, hCommandList); } @@ -1951,17 +6194,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListResetPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListReset(result, hCommandList); } auto driver_result = pfnReset( hCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListResetEpilogue( hCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListReset(result, hCommandList); } - return logAndPropagateResult("zeCommandListReset", driver_result); + return logAndPropagateResult_zeCommandListReset(driver_result, hCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1983,12 +6226,12 @@ namespace validation_layer auto pfnAppendWriteGlobalTimestamp = context.zeDdiTable.CommandList.pfnAppendWriteGlobalTimestamp; if( nullptr == pfnAppendWriteGlobalTimestamp ) - return logAndPropagateResult("zeCommandListAppendWriteGlobalTimestamp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWriteGlobalTimestampPrologue( hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWriteGlobalTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp(result, hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -1999,17 +6242,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendWriteGlobalTimestampPrologue( hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWriteGlobalTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp(result, hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendWriteGlobalTimestamp( hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWriteGlobalTimestampEpilogue( hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWriteGlobalTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp(result, hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendWriteGlobalTimestamp", driver_result); + return logAndPropagateResult_zeCommandListAppendWriteGlobalTimestamp(driver_result, hCommandList, dstptr, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2031,12 +6274,12 @@ namespace validation_layer auto pfnHostSynchronize = context.zeDdiTable.CommandList.pfnHostSynchronize; if( nullptr == pfnHostSynchronize ) - return logAndPropagateResult("zeCommandListHostSynchronize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListHostSynchronize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, timeout); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListHostSynchronizePrologue( hCommandList, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListHostSynchronize(result, hCommandList, timeout); } @@ -2047,17 +6290,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListHostSynchronizePrologue( hCommandList, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListHostSynchronize(result, hCommandList, timeout); } auto driver_result = pfnHostSynchronize( hCommandList, timeout ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListHostSynchronizeEpilogue( hCommandList, timeout ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListHostSynchronize(result, hCommandList, timeout); } - return logAndPropagateResult("zeCommandListHostSynchronize", driver_result); + return logAndPropagateResult_zeCommandListHostSynchronize(driver_result, hCommandList, timeout); } /////////////////////////////////////////////////////////////////////////////// @@ -2073,12 +6316,12 @@ namespace validation_layer auto pfnGetDeviceHandle = context.zeDdiTable.CommandList.pfnGetDeviceHandle; if( nullptr == pfnGetDeviceHandle ) - return logAndPropagateResult("zeCommandListGetDeviceHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListGetDeviceHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, phDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetDeviceHandlePrologue( hCommandList, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetDeviceHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetDeviceHandle(result, hCommandList, phDevice); } @@ -2089,17 +6332,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListGetDeviceHandlePrologue( hCommandList, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetDeviceHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetDeviceHandle(result, hCommandList, phDevice); } auto driver_result = pfnGetDeviceHandle( hCommandList, phDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetDeviceHandleEpilogue( hCommandList, phDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetDeviceHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetDeviceHandle(result, hCommandList, phDevice); } - return logAndPropagateResult("zeCommandListGetDeviceHandle", driver_result); + return logAndPropagateResult_zeCommandListGetDeviceHandle(driver_result, hCommandList, phDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -2115,12 +6358,12 @@ namespace validation_layer auto pfnGetContextHandle = context.zeDdiTable.CommandList.pfnGetContextHandle; if( nullptr == pfnGetContextHandle ) - return logAndPropagateResult("zeCommandListGetContextHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListGetContextHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, phContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetContextHandlePrologue( hCommandList, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetContextHandle(result, hCommandList, phContext); } @@ -2131,17 +6374,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListGetContextHandlePrologue( hCommandList, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetContextHandle(result, hCommandList, phContext); } auto driver_result = pfnGetContextHandle( hCommandList, phContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetContextHandleEpilogue( hCommandList, phContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetContextHandle(result, hCommandList, phContext); } - return logAndPropagateResult("zeCommandListGetContextHandle", driver_result); + return logAndPropagateResult_zeCommandListGetContextHandle(driver_result, hCommandList, phContext); } /////////////////////////////////////////////////////////////////////////////// @@ -2157,12 +6400,12 @@ namespace validation_layer auto pfnGetOrdinal = context.zeDdiTable.CommandList.pfnGetOrdinal; if( nullptr == pfnGetOrdinal ) - return logAndPropagateResult("zeCommandListGetOrdinal", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListGetOrdinal(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, pOrdinal); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetOrdinalPrologue( hCommandList, pOrdinal ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetOrdinal(result, hCommandList, pOrdinal); } @@ -2173,17 +6416,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListGetOrdinalPrologue( hCommandList, pOrdinal ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetOrdinal(result, hCommandList, pOrdinal); } auto driver_result = pfnGetOrdinal( hCommandList, pOrdinal ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetOrdinalEpilogue( hCommandList, pOrdinal ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetOrdinal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetOrdinal(result, hCommandList, pOrdinal); } - return logAndPropagateResult("zeCommandListGetOrdinal", driver_result); + return logAndPropagateResult_zeCommandListGetOrdinal(driver_result, hCommandList, pOrdinal); } /////////////////////////////////////////////////////////////////////////////// @@ -2200,12 +6443,12 @@ namespace validation_layer auto pfnImmediateGetIndex = context.zeDdiTable.CommandList.pfnImmediateGetIndex; if( nullptr == pfnImmediateGetIndex ) - return logAndPropagateResult("zeCommandListImmediateGetIndex", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListImmediateGetIndex(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandListImmediate, pIndex); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListImmediateGetIndexPrologue( hCommandListImmediate, pIndex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateGetIndex(result, hCommandListImmediate, pIndex); } @@ -2216,17 +6459,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListImmediateGetIndexPrologue( hCommandListImmediate, pIndex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateGetIndex(result, hCommandListImmediate, pIndex); } auto driver_result = pfnImmediateGetIndex( hCommandListImmediate, pIndex ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListImmediateGetIndexEpilogue( hCommandListImmediate, pIndex ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateGetIndex", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateGetIndex(result, hCommandListImmediate, pIndex); } - return logAndPropagateResult("zeCommandListImmediateGetIndex", driver_result); + return logAndPropagateResult_zeCommandListImmediateGetIndex(driver_result, hCommandListImmediate, pIndex); } /////////////////////////////////////////////////////////////////////////////// @@ -2243,12 +6486,12 @@ namespace validation_layer auto pfnIsImmediate = context.zeDdiTable.CommandList.pfnIsImmediate; if( nullptr == pfnIsImmediate ) - return logAndPropagateResult("zeCommandListIsImmediate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListIsImmediate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, pIsImmediate); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListIsImmediatePrologue( hCommandList, pIsImmediate ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListIsImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListIsImmediate(result, hCommandList, pIsImmediate); } @@ -2259,17 +6502,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListIsImmediatePrologue( hCommandList, pIsImmediate ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListIsImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListIsImmediate(result, hCommandList, pIsImmediate); } auto driver_result = pfnIsImmediate( hCommandList, pIsImmediate ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListIsImmediateEpilogue( hCommandList, pIsImmediate ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListIsImmediate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListIsImmediate(result, hCommandList, pIsImmediate); } - return logAndPropagateResult("zeCommandListIsImmediate", driver_result); + return logAndPropagateResult_zeCommandListIsImmediate(driver_result, hCommandList, pIsImmediate); } /////////////////////////////////////////////////////////////////////////////// @@ -2289,12 +6532,12 @@ namespace validation_layer auto pfnAppendBarrier = context.zeDdiTable.CommandList.pfnAppendBarrier; if( nullptr == pfnAppendBarrier ) - return logAndPropagateResult("zeCommandListAppendBarrier", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendBarrier(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendBarrierPrologue( hCommandList, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendBarrier(result, hCommandList, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2305,17 +6548,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendBarrierPrologue( hCommandList, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendBarrier(result, hCommandList, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendBarrier( hCommandList, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendBarrierEpilogue( hCommandList, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendBarrier(result, hCommandList, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendBarrier", driver_result); + return logAndPropagateResult_zeCommandListAppendBarrier(driver_result, hCommandList, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2338,12 +6581,12 @@ namespace validation_layer auto pfnAppendMemoryRangesBarrier = context.zeDdiTable.CommandList.pfnAppendMemoryRangesBarrier; if( nullptr == pfnAppendMemoryRangesBarrier ) - return logAndPropagateResult("zeCommandListAppendMemoryRangesBarrier", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryRangesBarrierPrologue( hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryRangesBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier(result, hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2354,17 +6597,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryRangesBarrierPrologue( hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryRangesBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier(result, hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMemoryRangesBarrier( hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryRangesBarrierEpilogue( hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryRangesBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier(result, hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendMemoryRangesBarrier", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryRangesBarrier(driver_result, hCommandList, numRanges, pRangeSizes, pRanges, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2380,12 +6623,12 @@ namespace validation_layer auto pfnSystemBarrier = context.zeDdiTable.Context.pfnSystemBarrier; if( nullptr == pfnSystemBarrier ) - return logAndPropagateResult("zeContextSystemBarrier", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextSystemBarrier(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextSystemBarrierPrologue( hContext, hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextSystemBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextSystemBarrier(result, hContext, hDevice); } @@ -2396,17 +6639,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextSystemBarrierPrologue( hContext, hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextSystemBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextSystemBarrier(result, hContext, hDevice); } auto driver_result = pfnSystemBarrier( hContext, hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextSystemBarrierEpilogue( hContext, hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextSystemBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextSystemBarrier(result, hContext, hDevice); } - return logAndPropagateResult("zeContextSystemBarrier", driver_result); + return logAndPropagateResult_zeContextSystemBarrier(driver_result, hContext, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -2429,12 +6672,12 @@ namespace validation_layer auto pfnAppendMemoryCopy = context.zeDdiTable.CommandList.pfnAppendMemoryCopy; if( nullptr == pfnAppendMemoryCopy ) - return logAndPropagateResult("zeCommandListAppendMemoryCopy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryCopy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyPrologue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopy(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2445,17 +6688,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryCopyPrologue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopy(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMemoryCopy( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyEpilogue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopy(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendMemoryCopy", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryCopy(driver_result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2479,12 +6722,12 @@ namespace validation_layer auto pfnAppendMemoryFill = context.zeDdiTable.CommandList.pfnAppendMemoryFill; if( nullptr == pfnAppendMemoryFill ) - return logAndPropagateResult("zeCommandListAppendMemoryFill", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryFill(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryFillPrologue( hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryFill", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryFill(result, hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2495,17 +6738,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryFillPrologue( hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryFill", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryFill(result, hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMemoryFill( hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryFillEpilogue( hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryFill", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryFill(result, hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendMemoryFill", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryFill(driver_result, hCommandList, ptr, pattern, pattern_size, size, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2537,12 +6780,12 @@ namespace validation_layer auto pfnAppendMemoryCopyRegion = context.zeDdiTable.CommandList.pfnAppendMemoryCopyRegion; if( nullptr == pfnAppendMemoryCopyRegion ) - return logAndPropagateResult("zeCommandListAppendMemoryCopyRegion", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryCopyRegion(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyRegionPrologue( hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyRegion(result, hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2553,17 +6796,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryCopyRegionPrologue( hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyRegion(result, hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMemoryCopyRegion( hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyRegionEpilogue( hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyRegion(result, hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendMemoryCopyRegion", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryCopyRegion(driver_result, hCommandList, dstptr, dstRegion, dstPitch, dstSlicePitch, srcptr, srcRegion, srcPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2587,12 +6830,12 @@ namespace validation_layer auto pfnAppendMemoryCopyFromContext = context.zeDdiTable.CommandList.pfnAppendMemoryCopyFromContext; if( nullptr == pfnAppendMemoryCopyFromContext ) - return logAndPropagateResult("zeCommandListAppendMemoryCopyFromContext", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyFromContextPrologue( hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyFromContext", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext(result, hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2603,17 +6846,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryCopyFromContextPrologue( hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyFromContext", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext(result, hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMemoryCopyFromContext( hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryCopyFromContextEpilogue( hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryCopyFromContext", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext(result, hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendMemoryCopyFromContext", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryCopyFromContext(driver_result, hCommandList, dstptr, hContextSrc, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2635,12 +6878,12 @@ namespace validation_layer auto pfnAppendImageCopy = context.zeDdiTable.CommandList.pfnAppendImageCopy; if( nullptr == pfnAppendImageCopy ) - return logAndPropagateResult("zeCommandListAppendImageCopy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyPrologue( hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopy(result, hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2651,17 +6894,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyPrologue( hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopy(result, hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopy( hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyEpilogue( hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopy(result, hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopy", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopy(driver_result, hCommandList, hDstImage, hSrcImage, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2685,12 +6928,12 @@ namespace validation_layer auto pfnAppendImageCopyRegion = context.zeDdiTable.CommandList.pfnAppendImageCopyRegion; if( nullptr == pfnAppendImageCopyRegion ) - return logAndPropagateResult("zeCommandListAppendImageCopyRegion", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopyRegion(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyRegionPrologue( hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyRegion(result, hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2701,17 +6944,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyRegionPrologue( hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyRegion(result, hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopyRegion( hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyRegionEpilogue( hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyRegion", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyRegion(result, hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopyRegion", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopyRegion(driver_result, hCommandList, hDstImage, hSrcImage, pDstRegion, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2734,12 +6977,12 @@ namespace validation_layer auto pfnAppendImageCopyToMemory = context.zeDdiTable.CommandList.pfnAppendImageCopyToMemory; if( nullptr == pfnAppendImageCopyToMemory ) - return logAndPropagateResult("zeCommandListAppendImageCopyToMemory", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopyToMemory(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyToMemoryPrologue( hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemory(result, hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2750,17 +6993,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyToMemoryPrologue( hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemory(result, hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopyToMemory( hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyToMemoryEpilogue( hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemory(result, hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopyToMemory", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopyToMemory(driver_result, hCommandList, dstptr, hSrcImage, pSrcRegion, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2783,12 +7026,12 @@ namespace validation_layer auto pfnAppendImageCopyFromMemory = context.zeDdiTable.CommandList.pfnAppendImageCopyFromMemory; if( nullptr == pfnAppendImageCopyFromMemory ) - return logAndPropagateResult("zeCommandListAppendImageCopyFromMemory", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopyFromMemory(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyFromMemoryPrologue( hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemory(result, hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -2799,17 +7042,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyFromMemoryPrologue( hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemory(result, hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopyFromMemory( hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyFromMemoryEpilogue( hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemory(result, hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopyFromMemory", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopyFromMemory(driver_result, hCommandList, hDstImage, srcptr, pDstRegion, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2826,12 +7069,12 @@ namespace validation_layer auto pfnAppendMemoryPrefetch = context.zeDdiTable.CommandList.pfnAppendMemoryPrefetch; if( nullptr == pfnAppendMemoryPrefetch ) - return logAndPropagateResult("zeCommandListAppendMemoryPrefetch", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemoryPrefetch(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, ptr, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryPrefetchPrologue( hCommandList, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryPrefetch", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryPrefetch(result, hCommandList, ptr, size); } @@ -2842,17 +7085,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemoryPrefetchPrologue( hCommandList, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryPrefetch", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryPrefetch(result, hCommandList, ptr, size); } auto driver_result = pfnAppendMemoryPrefetch( hCommandList, ptr, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemoryPrefetchEpilogue( hCommandList, ptr, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemoryPrefetch", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemoryPrefetch(result, hCommandList, ptr, size); } - return logAndPropagateResult("zeCommandListAppendMemoryPrefetch", driver_result); + return logAndPropagateResult_zeCommandListAppendMemoryPrefetch(driver_result, hCommandList, ptr, size); } /////////////////////////////////////////////////////////////////////////////// @@ -2871,12 +7114,12 @@ namespace validation_layer auto pfnAppendMemAdvise = context.zeDdiTable.CommandList.pfnAppendMemAdvise; if( nullptr == pfnAppendMemAdvise ) - return logAndPropagateResult("zeCommandListAppendMemAdvise", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendMemAdvise(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hDevice, ptr, size, advice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemAdvisePrologue( hCommandList, hDevice, ptr, size, advice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemAdvise", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemAdvise(result, hCommandList, hDevice, ptr, size, advice); } @@ -2887,17 +7130,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendMemAdvisePrologue( hCommandList, hDevice, ptr, size, advice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemAdvise", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemAdvise(result, hCommandList, hDevice, ptr, size, advice); } auto driver_result = pfnAppendMemAdvise( hCommandList, hDevice, ptr, size, advice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendMemAdviseEpilogue( hCommandList, hDevice, ptr, size, advice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendMemAdvise", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendMemAdvise(result, hCommandList, hDevice, ptr, size, advice); } - return logAndPropagateResult("zeCommandListAppendMemAdvise", driver_result); + return logAndPropagateResult_zeCommandListAppendMemAdvise(driver_result, hCommandList, hDevice, ptr, size, advice); } /////////////////////////////////////////////////////////////////////////////// @@ -2920,12 +7163,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.EventPool.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeEventPoolCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, desc, numDevices, phDevices, phEventPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolCreatePrologue( hContext, desc, numDevices, phDevices, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCreate(result, hContext, desc, numDevices, phDevices, phEventPool); } @@ -2936,14 +7179,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolCreatePrologue( hContext, desc, numDevices, phDevices, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCreate(result, hContext, desc, numDevices, phDevices, phEventPool); } auto driver_result = pfnCreate( hContext, desc, numDevices, phDevices, phEventPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolCreateEpilogue( hContext, desc, numDevices, phDevices, phEventPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCreate(result, hContext, desc, numDevices, phDevices, phEventPool); } @@ -2955,7 +7198,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeEventPoolCreate", driver_result); + return logAndPropagateResult_zeEventPoolCreate(driver_result, hContext, desc, numDevices, phDevices, phEventPool); } /////////////////////////////////////////////////////////////////////////////// @@ -2970,12 +7213,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.EventPool.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeEventPoolDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolDestroyPrologue( hEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolDestroy(result, hEventPool); } @@ -2986,17 +7229,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolDestroyPrologue( hEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolDestroy(result, hEventPool); } auto driver_result = pfnDestroy( hEventPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolDestroyEpilogue( hEventPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolDestroy(result, hEventPool); } - return logAndPropagateResult("zeEventPoolDestroy", driver_result); + return logAndPropagateResult_zeEventPoolDestroy(driver_result, hEventPool); } /////////////////////////////////////////////////////////////////////////////// @@ -3013,12 +7256,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Event.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeEventCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool, desc, phEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventCreatePrologue( hEventPool, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventCreate(result, hEventPool, desc, phEvent); } @@ -3029,14 +7272,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventCreatePrologue( hEventPool, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventCreate(result, hEventPool, desc, phEvent); } auto driver_result = pfnCreate( hEventPool, desc, phEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventCreateEpilogue( hEventPool, desc, phEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventCreate(result, hEventPool, desc, phEvent); } @@ -3048,7 +7291,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeEventCreate", driver_result); + return logAndPropagateResult_zeEventCreate(driver_result, hEventPool, desc, phEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3063,12 +7306,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Event.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeEventDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventDestroyPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventDestroy(result, hEvent); } @@ -3079,17 +7322,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventDestroyPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventDestroy(result, hEvent); } auto driver_result = pfnDestroy( hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventDestroyEpilogue( hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventDestroy(result, hEvent); } - return logAndPropagateResult("zeEventDestroy", driver_result); + return logAndPropagateResult_zeEventDestroy(driver_result, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3105,12 +7348,12 @@ namespace validation_layer auto pfnGetIpcHandle = context.zeDdiTable.EventPool.pfnGetIpcHandle; if( nullptr == pfnGetIpcHandle ) - return logAndPropagateResult("zeEventPoolGetIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolGetIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool, phIpc); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetIpcHandlePrologue( hEventPool, phIpc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetIpcHandle(result, hEventPool, phIpc); } @@ -3121,21 +7364,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolGetIpcHandlePrologue( hEventPool, phIpc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetIpcHandle(result, hEventPool, phIpc); } auto driver_result = pfnGetIpcHandle( hEventPool, phIpc ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetIpcHandleEpilogue( hEventPool, phIpc ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetIpcHandle(result, hEventPool, phIpc); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeEventPoolGetIpcHandle", driver_result); + return logAndPropagateResult_zeEventPoolGetIpcHandle(driver_result, hEventPool, phIpc); } /////////////////////////////////////////////////////////////////////////////// @@ -3152,12 +7395,12 @@ namespace validation_layer auto pfnPutIpcHandle = context.zeDdiTable.EventPool.pfnPutIpcHandle; if( nullptr == pfnPutIpcHandle ) - return logAndPropagateResult("zeEventPoolPutIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolPutIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hIpc); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolPutIpcHandlePrologue( hContext, hIpc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolPutIpcHandle(result, hContext, hIpc); } @@ -3168,17 +7411,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolPutIpcHandlePrologue( hContext, hIpc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolPutIpcHandle(result, hContext, hIpc); } auto driver_result = pfnPutIpcHandle( hContext, hIpc ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolPutIpcHandleEpilogue( hContext, hIpc ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolPutIpcHandle(result, hContext, hIpc); } - return logAndPropagateResult("zeEventPoolPutIpcHandle", driver_result); + return logAndPropagateResult_zeEventPoolPutIpcHandle(driver_result, hContext, hIpc); } /////////////////////////////////////////////////////////////////////////////// @@ -3196,12 +7439,12 @@ namespace validation_layer auto pfnOpenIpcHandle = context.zeDdiTable.EventPool.pfnOpenIpcHandle; if( nullptr == pfnOpenIpcHandle ) - return logAndPropagateResult("zeEventPoolOpenIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolOpenIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hIpc, phEventPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolOpenIpcHandlePrologue( hContext, hIpc, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolOpenIpcHandle(result, hContext, hIpc, phEventPool); } @@ -3212,17 +7455,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolOpenIpcHandlePrologue( hContext, hIpc, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolOpenIpcHandle(result, hContext, hIpc, phEventPool); } auto driver_result = pfnOpenIpcHandle( hContext, hIpc, phEventPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolOpenIpcHandleEpilogue( hContext, hIpc, phEventPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolOpenIpcHandle(result, hContext, hIpc, phEventPool); } - return logAndPropagateResult("zeEventPoolOpenIpcHandle", driver_result); + return logAndPropagateResult_zeEventPoolOpenIpcHandle(driver_result, hContext, hIpc, phEventPool); } /////////////////////////////////////////////////////////////////////////////// @@ -3237,12 +7480,12 @@ namespace validation_layer auto pfnCloseIpcHandle = context.zeDdiTable.EventPool.pfnCloseIpcHandle; if( nullptr == pfnCloseIpcHandle ) - return logAndPropagateResult("zeEventPoolCloseIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolCloseIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolCloseIpcHandlePrologue( hEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCloseIpcHandle(result, hEventPool); } @@ -3253,17 +7496,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolCloseIpcHandlePrologue( hEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCloseIpcHandle(result, hEventPool); } auto driver_result = pfnCloseIpcHandle( hEventPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolCloseIpcHandleEpilogue( hEventPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolCloseIpcHandle(result, hEventPool); } - return logAndPropagateResult("zeEventPoolCloseIpcHandle", driver_result); + return logAndPropagateResult_zeEventPoolCloseIpcHandle(driver_result, hEventPool); } /////////////////////////////////////////////////////////////////////////////// @@ -3279,12 +7522,12 @@ namespace validation_layer auto pfnAppendSignalEvent = context.zeDdiTable.CommandList.pfnAppendSignalEvent; if( nullptr == pfnAppendSignalEvent ) - return logAndPropagateResult("zeCommandListAppendSignalEvent", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendSignalEvent(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendSignalEventPrologue( hCommandList, hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalEvent(result, hCommandList, hEvent); } @@ -3295,17 +7538,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendSignalEventPrologue( hCommandList, hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalEvent(result, hCommandList, hEvent); } auto driver_result = pfnAppendSignalEvent( hCommandList, hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendSignalEventEpilogue( hCommandList, hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalEvent(result, hCommandList, hEvent); } - return logAndPropagateResult("zeCommandListAppendSignalEvent", driver_result); + return logAndPropagateResult_zeCommandListAppendSignalEvent(driver_result, hCommandList, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3323,12 +7566,12 @@ namespace validation_layer auto pfnAppendWaitOnEvents = context.zeDdiTable.CommandList.pfnAppendWaitOnEvents; if( nullptr == pfnAppendWaitOnEvents ) - return logAndPropagateResult("zeCommandListAppendWaitOnEvents", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendWaitOnEvents(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numEvents, phEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWaitOnEventsPrologue( hCommandList, numEvents, phEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitOnEvents", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitOnEvents(result, hCommandList, numEvents, phEvents); } @@ -3339,17 +7582,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendWaitOnEventsPrologue( hCommandList, numEvents, phEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitOnEvents", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitOnEvents(result, hCommandList, numEvents, phEvents); } auto driver_result = pfnAppendWaitOnEvents( hCommandList, numEvents, phEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWaitOnEventsEpilogue( hCommandList, numEvents, phEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitOnEvents", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitOnEvents(result, hCommandList, numEvents, phEvents); } - return logAndPropagateResult("zeCommandListAppendWaitOnEvents", driver_result); + return logAndPropagateResult_zeCommandListAppendWaitOnEvents(driver_result, hCommandList, numEvents, phEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -3364,12 +7607,12 @@ namespace validation_layer auto pfnHostSignal = context.zeDdiTable.Event.pfnHostSignal; if( nullptr == pfnHostSignal ) - return logAndPropagateResult("zeEventHostSignal", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventHostSignal(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostSignalPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSignal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSignal(result, hEvent); } @@ -3380,17 +7623,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventHostSignalPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSignal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSignal(result, hEvent); } auto driver_result = pfnHostSignal( hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostSignalEpilogue( hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSignal", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSignal(result, hEvent); } - return logAndPropagateResult("zeEventHostSignal", driver_result); + return logAndPropagateResult_zeEventHostSignal(driver_result, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3412,12 +7655,12 @@ namespace validation_layer auto pfnHostSynchronize = context.zeDdiTable.Event.pfnHostSynchronize; if( nullptr == pfnHostSynchronize ) - return logAndPropagateResult("zeEventHostSynchronize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventHostSynchronize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, timeout); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostSynchronizePrologue( hEvent, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSynchronize(result, hEvent, timeout); } @@ -3428,17 +7671,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventHostSynchronizePrologue( hEvent, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSynchronize(result, hEvent, timeout); } auto driver_result = pfnHostSynchronize( hEvent, timeout ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostSynchronizeEpilogue( hEvent, timeout ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostSynchronize(result, hEvent, timeout); } - return logAndPropagateResult("zeEventHostSynchronize", driver_result); + return logAndPropagateResult_zeEventHostSynchronize(driver_result, hEvent, timeout); } /////////////////////////////////////////////////////////////////////////////// @@ -3453,12 +7696,12 @@ namespace validation_layer auto pfnQueryStatus = context.zeDdiTable.Event.pfnQueryStatus; if( nullptr == pfnQueryStatus ) - return logAndPropagateResult("zeEventQueryStatus", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventQueryStatus(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryStatusPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryStatus(result, hEvent); } @@ -3469,17 +7712,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventQueryStatusPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryStatus(result, hEvent); } auto driver_result = pfnQueryStatus( hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryStatusEpilogue( hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryStatus(result, hEvent); } - return logAndPropagateResult("zeEventQueryStatus", driver_result); + return logAndPropagateResult_zeEventQueryStatus(driver_result, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3495,12 +7738,12 @@ namespace validation_layer auto pfnAppendEventReset = context.zeDdiTable.CommandList.pfnAppendEventReset; if( nullptr == pfnAppendEventReset ) - return logAndPropagateResult("zeCommandListAppendEventReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendEventReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendEventResetPrologue( hCommandList, hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendEventReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendEventReset(result, hCommandList, hEvent); } @@ -3511,17 +7754,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendEventResetPrologue( hCommandList, hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendEventReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendEventReset(result, hCommandList, hEvent); } auto driver_result = pfnAppendEventReset( hCommandList, hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendEventResetEpilogue( hCommandList, hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendEventReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendEventReset(result, hCommandList, hEvent); } - return logAndPropagateResult("zeCommandListAppendEventReset", driver_result); + return logAndPropagateResult_zeCommandListAppendEventReset(driver_result, hCommandList, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3536,12 +7779,12 @@ namespace validation_layer auto pfnHostReset = context.zeDdiTable.Event.pfnHostReset; if( nullptr == pfnHostReset ) - return logAndPropagateResult("zeEventHostReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventHostReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostResetPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostReset(result, hEvent); } @@ -3552,17 +7795,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventHostResetPrologue( hEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostReset(result, hEvent); } auto driver_result = pfnHostReset( hEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventHostResetEpilogue( hEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventHostReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventHostReset(result, hEvent); } - return logAndPropagateResult("zeEventHostReset", driver_result); + return logAndPropagateResult_zeEventHostReset(driver_result, hEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -3578,12 +7821,12 @@ namespace validation_layer auto pfnQueryKernelTimestamp = context.zeDdiTable.Event.pfnQueryKernelTimestamp; if( nullptr == pfnQueryKernelTimestamp ) - return logAndPropagateResult("zeEventQueryKernelTimestamp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventQueryKernelTimestamp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, dstptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryKernelTimestampPrologue( hEvent, dstptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestamp(result, hEvent, dstptr); } @@ -3594,17 +7837,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventQueryKernelTimestampPrologue( hEvent, dstptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestamp(result, hEvent, dstptr); } auto driver_result = pfnQueryKernelTimestamp( hEvent, dstptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryKernelTimestampEpilogue( hEvent, dstptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestamp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestamp(result, hEvent, dstptr); } - return logAndPropagateResult("zeEventQueryKernelTimestamp", driver_result); + return logAndPropagateResult_zeEventQueryKernelTimestamp(driver_result, hEvent, dstptr); } /////////////////////////////////////////////////////////////////////////////// @@ -3631,12 +7874,12 @@ namespace validation_layer auto pfnAppendQueryKernelTimestamps = context.zeDdiTable.CommandList.pfnAppendQueryKernelTimestamps; if( nullptr == pfnAppendQueryKernelTimestamps ) - return logAndPropagateResult("zeCommandListAppendQueryKernelTimestamps", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendQueryKernelTimestampsPrologue( hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendQueryKernelTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps(result, hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -3647,17 +7890,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendQueryKernelTimestampsPrologue( hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendQueryKernelTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps(result, hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendQueryKernelTimestamps( hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendQueryKernelTimestampsEpilogue( hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendQueryKernelTimestamps", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps(result, hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendQueryKernelTimestamps", driver_result); + return logAndPropagateResult_zeCommandListAppendQueryKernelTimestamps(driver_result, hCommandList, numEvents, phEvents, dstptr, pOffsets, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -3673,12 +7916,12 @@ namespace validation_layer auto pfnGetEventPool = context.zeDdiTable.Event.pfnGetEventPool; if( nullptr == pfnGetEventPool ) - return logAndPropagateResult("zeEventGetEventPool", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventGetEventPool(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, phEventPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetEventPoolPrologue( hEvent, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetEventPool", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetEventPool(result, hEvent, phEventPool); } @@ -3689,17 +7932,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventGetEventPoolPrologue( hEvent, phEventPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetEventPool", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetEventPool(result, hEvent, phEventPool); } auto driver_result = pfnGetEventPool( hEvent, phEventPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetEventPoolEpilogue( hEvent, phEventPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetEventPool", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetEventPool(result, hEvent, phEventPool); } - return logAndPropagateResult("zeEventGetEventPool", driver_result); + return logAndPropagateResult_zeEventGetEventPool(driver_result, hEvent, phEventPool); } /////////////////////////////////////////////////////////////////////////////// @@ -3717,12 +7960,12 @@ namespace validation_layer auto pfnGetSignalScope = context.zeDdiTable.Event.pfnGetSignalScope; if( nullptr == pfnGetSignalScope ) - return logAndPropagateResult("zeEventGetSignalScope", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventGetSignalScope(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, pSignalScope); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetSignalScopePrologue( hEvent, pSignalScope ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetSignalScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetSignalScope(result, hEvent, pSignalScope); } @@ -3733,17 +7976,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventGetSignalScopePrologue( hEvent, pSignalScope ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetSignalScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetSignalScope(result, hEvent, pSignalScope); } auto driver_result = pfnGetSignalScope( hEvent, pSignalScope ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetSignalScopeEpilogue( hEvent, pSignalScope ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetSignalScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetSignalScope(result, hEvent, pSignalScope); } - return logAndPropagateResult("zeEventGetSignalScope", driver_result); + return logAndPropagateResult_zeEventGetSignalScope(driver_result, hEvent, pSignalScope); } /////////////////////////////////////////////////////////////////////////////// @@ -3761,12 +8004,12 @@ namespace validation_layer auto pfnGetWaitScope = context.zeDdiTable.Event.pfnGetWaitScope; if( nullptr == pfnGetWaitScope ) - return logAndPropagateResult("zeEventGetWaitScope", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventGetWaitScope(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, pWaitScope); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetWaitScopePrologue( hEvent, pWaitScope ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetWaitScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetWaitScope(result, hEvent, pWaitScope); } @@ -3777,17 +8020,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventGetWaitScopePrologue( hEvent, pWaitScope ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetWaitScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetWaitScope(result, hEvent, pWaitScope); } auto driver_result = pfnGetWaitScope( hEvent, pWaitScope ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventGetWaitScopeEpilogue( hEvent, pWaitScope ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventGetWaitScope", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventGetWaitScope(result, hEvent, pWaitScope); } - return logAndPropagateResult("zeEventGetWaitScope", driver_result); + return logAndPropagateResult_zeEventGetWaitScope(driver_result, hEvent, pWaitScope); } /////////////////////////////////////////////////////////////////////////////// @@ -3803,12 +8046,12 @@ namespace validation_layer auto pfnGetContextHandle = context.zeDdiTable.EventPool.pfnGetContextHandle; if( nullptr == pfnGetContextHandle ) - return logAndPropagateResult("zeEventPoolGetContextHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolGetContextHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool, phContext); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetContextHandlePrologue( hEventPool, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetContextHandle(result, hEventPool, phContext); } @@ -3819,17 +8062,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolGetContextHandlePrologue( hEventPool, phContext ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetContextHandle(result, hEventPool, phContext); } auto driver_result = pfnGetContextHandle( hEventPool, phContext ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetContextHandleEpilogue( hEventPool, phContext ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetContextHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetContextHandle(result, hEventPool, phContext); } - return logAndPropagateResult("zeEventPoolGetContextHandle", driver_result); + return logAndPropagateResult_zeEventPoolGetContextHandle(driver_result, hEventPool, phContext); } /////////////////////////////////////////////////////////////////////////////// @@ -3846,12 +8089,12 @@ namespace validation_layer auto pfnGetFlags = context.zeDdiTable.EventPool.pfnGetFlags; if( nullptr == pfnGetFlags ) - return logAndPropagateResult("zeEventPoolGetFlags", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventPoolGetFlags(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEventPool, pFlags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetFlagsPrologue( hEventPool, pFlags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetFlags", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetFlags(result, hEventPool, pFlags); } @@ -3862,17 +8105,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventPoolGetFlagsPrologue( hEventPool, pFlags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetFlags", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetFlags(result, hEventPool, pFlags); } auto driver_result = pfnGetFlags( hEventPool, pFlags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventPoolGetFlagsEpilogue( hEventPool, pFlags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventPoolGetFlags", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventPoolGetFlags(result, hEventPool, pFlags); } - return logAndPropagateResult("zeEventPoolGetFlags", driver_result); + return logAndPropagateResult_zeEventPoolGetFlags(driver_result, hEventPool, pFlags); } /////////////////////////////////////////////////////////////////////////////// @@ -3889,12 +8132,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Fence.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeFenceCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFenceCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandQueue, desc, phFence); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceCreatePrologue( hCommandQueue, desc, phFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceCreate(result, hCommandQueue, desc, phFence); } @@ -3905,14 +8148,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFenceCreatePrologue( hCommandQueue, desc, phFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceCreate(result, hCommandQueue, desc, phFence); } auto driver_result = pfnCreate( hCommandQueue, desc, phFence ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceCreateEpilogue( hCommandQueue, desc, phFence ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceCreate(result, hCommandQueue, desc, phFence); } @@ -3924,7 +8167,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeFenceCreate", driver_result); + return logAndPropagateResult_zeFenceCreate(driver_result, hCommandQueue, desc, phFence); } /////////////////////////////////////////////////////////////////////////////// @@ -3939,12 +8182,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Fence.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeFenceDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFenceDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFence); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceDestroyPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceDestroy(result, hFence); } @@ -3955,17 +8198,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFenceDestroyPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceDestroy(result, hFence); } auto driver_result = pfnDestroy( hFence ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceDestroyEpilogue( hFence ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceDestroy(result, hFence); } - return logAndPropagateResult("zeFenceDestroy", driver_result); + return logAndPropagateResult_zeFenceDestroy(driver_result, hFence); } /////////////////////////////////////////////////////////////////////////////// @@ -3987,12 +8230,12 @@ namespace validation_layer auto pfnHostSynchronize = context.zeDdiTable.Fence.pfnHostSynchronize; if( nullptr == pfnHostSynchronize ) - return logAndPropagateResult("zeFenceHostSynchronize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFenceHostSynchronize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFence, timeout); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceHostSynchronizePrologue( hFence, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceHostSynchronize(result, hFence, timeout); } @@ -4003,17 +8246,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFenceHostSynchronizePrologue( hFence, timeout ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceHostSynchronize(result, hFence, timeout); } auto driver_result = pfnHostSynchronize( hFence, timeout ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceHostSynchronizeEpilogue( hFence, timeout ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceHostSynchronize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceHostSynchronize(result, hFence, timeout); } - return logAndPropagateResult("zeFenceHostSynchronize", driver_result); + return logAndPropagateResult_zeFenceHostSynchronize(driver_result, hFence, timeout); } /////////////////////////////////////////////////////////////////////////////// @@ -4028,12 +8271,12 @@ namespace validation_layer auto pfnQueryStatus = context.zeDdiTable.Fence.pfnQueryStatus; if( nullptr == pfnQueryStatus ) - return logAndPropagateResult("zeFenceQueryStatus", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFenceQueryStatus(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFence); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceQueryStatusPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceQueryStatus(result, hFence); } @@ -4044,17 +8287,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFenceQueryStatusPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceQueryStatus(result, hFence); } auto driver_result = pfnQueryStatus( hFence ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceQueryStatusEpilogue( hFence ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceQueryStatus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceQueryStatus(result, hFence); } - return logAndPropagateResult("zeFenceQueryStatus", driver_result); + return logAndPropagateResult_zeFenceQueryStatus(driver_result, hFence); } /////////////////////////////////////////////////////////////////////////////// @@ -4069,12 +8312,12 @@ namespace validation_layer auto pfnReset = context.zeDdiTable.Fence.pfnReset; if( nullptr == pfnReset ) - return logAndPropagateResult("zeFenceReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFenceReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFence); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceResetPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceReset(result, hFence); } @@ -4085,17 +8328,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFenceResetPrologue( hFence ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceReset(result, hFence); } auto driver_result = pfnReset( hFence ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFenceResetEpilogue( hFence ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFenceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFenceReset(result, hFence); } - return logAndPropagateResult("zeFenceReset", driver_result); + return logAndPropagateResult_zeFenceReset(driver_result, hFence); } /////////////////////////////////////////////////////////////////////////////// @@ -4112,12 +8355,12 @@ namespace validation_layer auto pfnGetProperties = context.zeDdiTable.Image.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zeImageGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, desc, pImageProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetPropertiesPrologue( hDevice, desc, pImageProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetProperties(result, hDevice, desc, pImageProperties); } @@ -4128,17 +8371,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageGetPropertiesPrologue( hDevice, desc, pImageProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetProperties(result, hDevice, desc, pImageProperties); } auto driver_result = pfnGetProperties( hDevice, desc, pImageProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetPropertiesEpilogue( hDevice, desc, pImageProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetProperties(result, hDevice, desc, pImageProperties); } - return logAndPropagateResult("zeImageGetProperties", driver_result); + return logAndPropagateResult_zeImageGetProperties(driver_result, hDevice, desc, pImageProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4156,12 +8399,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Image.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeImageCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phImage); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageCreatePrologue( hContext, hDevice, desc, phImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageCreate(result, hContext, hDevice, desc, phImage); } @@ -4172,14 +8415,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageCreatePrologue( hContext, hDevice, desc, phImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageCreate(result, hContext, hDevice, desc, phImage); } auto driver_result = pfnCreate( hContext, hDevice, desc, phImage ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageCreateEpilogue( hContext, hDevice, desc, phImage ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageCreate(result, hContext, hDevice, desc, phImage); } @@ -4191,7 +8434,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeImageCreate", driver_result); + return logAndPropagateResult_zeImageCreate(driver_result, hContext, hDevice, desc, phImage); } /////////////////////////////////////////////////////////////////////////////// @@ -4206,12 +8449,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Image.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeImageDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hImage); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageDestroyPrologue( hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageDestroy(result, hImage); } @@ -4222,17 +8465,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageDestroyPrologue( hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageDestroy(result, hImage); } auto driver_result = pfnDestroy( hImage ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageDestroyEpilogue( hImage ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageDestroy(result, hImage); } - return logAndPropagateResult("zeImageDestroy", driver_result); + return logAndPropagateResult_zeImageDestroy(driver_result, hImage); } /////////////////////////////////////////////////////////////////////////////// @@ -4255,12 +8498,12 @@ namespace validation_layer auto pfnAllocShared = context.zeDdiTable.Mem.pfnAllocShared; if( nullptr == pfnAllocShared ) - return logAndPropagateResult("zeMemAllocShared", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemAllocShared(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, device_desc, host_desc, size, alignment, hDevice, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocSharedPrologue( hContext, device_desc, host_desc, size, alignment, hDevice, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocShared", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocShared(result, hContext, device_desc, host_desc, size, alignment, hDevice, pptr); } @@ -4271,17 +8514,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemAllocSharedPrologue( hContext, device_desc, host_desc, size, alignment, hDevice, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocShared", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocShared(result, hContext, device_desc, host_desc, size, alignment, hDevice, pptr); } auto driver_result = pfnAllocShared( hContext, device_desc, host_desc, size, alignment, hDevice, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocSharedEpilogue( hContext, device_desc, host_desc, size, alignment, hDevice, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocShared", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocShared(result, hContext, device_desc, host_desc, size, alignment, hDevice, pptr); } - return logAndPropagateResult("zeMemAllocShared", driver_result); + return logAndPropagateResult_zeMemAllocShared(driver_result, hContext, device_desc, host_desc, size, alignment, hDevice, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4303,12 +8546,12 @@ namespace validation_layer auto pfnAllocDevice = context.zeDdiTable.Mem.pfnAllocDevice; if( nullptr == pfnAllocDevice ) - return logAndPropagateResult("zeMemAllocDevice", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemAllocDevice(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, device_desc, size, alignment, hDevice, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocDevicePrologue( hContext, device_desc, size, alignment, hDevice, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocDevice(result, hContext, device_desc, size, alignment, hDevice, pptr); } @@ -4319,17 +8562,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemAllocDevicePrologue( hContext, device_desc, size, alignment, hDevice, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocDevice(result, hContext, device_desc, size, alignment, hDevice, pptr); } auto driver_result = pfnAllocDevice( hContext, device_desc, size, alignment, hDevice, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocDeviceEpilogue( hContext, device_desc, size, alignment, hDevice, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocDevice", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocDevice(result, hContext, device_desc, size, alignment, hDevice, pptr); } - return logAndPropagateResult("zeMemAllocDevice", driver_result); + return logAndPropagateResult_zeMemAllocDevice(driver_result, hContext, device_desc, size, alignment, hDevice, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4350,12 +8593,12 @@ namespace validation_layer auto pfnAllocHost = context.zeDdiTable.Mem.pfnAllocHost; if( nullptr == pfnAllocHost ) - return logAndPropagateResult("zeMemAllocHost", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemAllocHost(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, host_desc, size, alignment, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocHostPrologue( hContext, host_desc, size, alignment, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocHost", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocHost(result, hContext, host_desc, size, alignment, pptr); } @@ -4366,17 +8609,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemAllocHostPrologue( hContext, host_desc, size, alignment, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocHost", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocHost(result, hContext, host_desc, size, alignment, pptr); } auto driver_result = pfnAllocHost( hContext, host_desc, size, alignment, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemAllocHostEpilogue( hContext, host_desc, size, alignment, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemAllocHost", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemAllocHost(result, hContext, host_desc, size, alignment, pptr); } - return logAndPropagateResult("zeMemAllocHost", driver_result); + return logAndPropagateResult_zeMemAllocHost(driver_result, hContext, host_desc, size, alignment, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4392,12 +8635,12 @@ namespace validation_layer auto pfnFree = context.zeDdiTable.Mem.pfnFree; if( nullptr == pfnFree ) - return logAndPropagateResult("zeMemFree", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemFree(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemFreePrologue( hContext, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFree(result, hContext, ptr); } @@ -4408,17 +8651,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemFreePrologue( hContext, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFree(result, hContext, ptr); } auto driver_result = pfnFree( hContext, ptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemFreeEpilogue( hContext, ptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFree(result, hContext, ptr); } - return logAndPropagateResult("zeMemFree", driver_result); + return logAndPropagateResult_zeMemFree(driver_result, hContext, ptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4436,12 +8679,12 @@ namespace validation_layer auto pfnGetAllocProperties = context.zeDdiTable.Mem.pfnGetAllocProperties; if( nullptr == pfnGetAllocProperties ) - return logAndPropagateResult("zeMemGetAllocProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetAllocProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, pMemAllocProperties, phDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAllocPropertiesPrologue( hContext, ptr, pMemAllocProperties, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAllocProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAllocProperties(result, hContext, ptr, pMemAllocProperties, phDevice); } @@ -4452,17 +8695,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetAllocPropertiesPrologue( hContext, ptr, pMemAllocProperties, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAllocProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAllocProperties(result, hContext, ptr, pMemAllocProperties, phDevice); } auto driver_result = pfnGetAllocProperties( hContext, ptr, pMemAllocProperties, phDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAllocPropertiesEpilogue( hContext, ptr, pMemAllocProperties, phDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAllocProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAllocProperties(result, hContext, ptr, pMemAllocProperties, phDevice); } - return logAndPropagateResult("zeMemGetAllocProperties", driver_result); + return logAndPropagateResult_zeMemGetAllocProperties(driver_result, hContext, ptr, pMemAllocProperties, phDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -4480,12 +8723,12 @@ namespace validation_layer auto pfnGetAddressRange = context.zeDdiTable.Mem.pfnGetAddressRange; if( nullptr == pfnGetAddressRange ) - return logAndPropagateResult("zeMemGetAddressRange", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetAddressRange(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, pBase, pSize); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAddressRangePrologue( hContext, ptr, pBase, pSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAddressRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAddressRange(result, hContext, ptr, pBase, pSize); } @@ -4496,17 +8739,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetAddressRangePrologue( hContext, ptr, pBase, pSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAddressRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAddressRange(result, hContext, ptr, pBase, pSize); } auto driver_result = pfnGetAddressRange( hContext, ptr, pBase, pSize ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAddressRangeEpilogue( hContext, ptr, pBase, pSize ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAddressRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAddressRange(result, hContext, ptr, pBase, pSize); } - return logAndPropagateResult("zeMemGetAddressRange", driver_result); + return logAndPropagateResult_zeMemGetAddressRange(driver_result, hContext, ptr, pBase, pSize); } /////////////////////////////////////////////////////////////////////////////// @@ -4523,12 +8766,12 @@ namespace validation_layer auto pfnGetIpcHandle = context.zeDdiTable.Mem.pfnGetIpcHandle; if( nullptr == pfnGetIpcHandle ) - return logAndPropagateResult("zeMemGetIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, pIpcHandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetIpcHandlePrologue( hContext, ptr, pIpcHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandle(result, hContext, ptr, pIpcHandle); } @@ -4539,21 +8782,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetIpcHandlePrologue( hContext, ptr, pIpcHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandle(result, hContext, ptr, pIpcHandle); } auto driver_result = pfnGetIpcHandle( hContext, ptr, pIpcHandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetIpcHandleEpilogue( hContext, ptr, pIpcHandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandle(result, hContext, ptr, pIpcHandle); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeMemGetIpcHandle", driver_result); + return logAndPropagateResult_zeMemGetIpcHandle(driver_result, hContext, ptr, pIpcHandle); } /////////////////////////////////////////////////////////////////////////////// @@ -4570,12 +8813,12 @@ namespace validation_layer auto pfnGetIpcHandleFromFileDescriptorExp = context.zeDdiTable.MemExp.pfnGetIpcHandleFromFileDescriptorExp; if( nullptr == pfnGetIpcHandleFromFileDescriptorExp ) - return logAndPropagateResult("zeMemGetIpcHandleFromFileDescriptorExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, handle, pIpcHandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetIpcHandleFromFileDescriptorExpPrologue( hContext, handle, pIpcHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandleFromFileDescriptorExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp(result, hContext, handle, pIpcHandle); } @@ -4586,21 +8829,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetIpcHandleFromFileDescriptorExpPrologue( hContext, handle, pIpcHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandleFromFileDescriptorExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp(result, hContext, handle, pIpcHandle); } auto driver_result = pfnGetIpcHandleFromFileDescriptorExp( hContext, handle, pIpcHandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetIpcHandleFromFileDescriptorExpEpilogue( hContext, handle, pIpcHandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetIpcHandleFromFileDescriptorExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp(result, hContext, handle, pIpcHandle); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeMemGetIpcHandleFromFileDescriptorExp", driver_result); + return logAndPropagateResult_zeMemGetIpcHandleFromFileDescriptorExp(driver_result, hContext, handle, pIpcHandle); } /////////////////////////////////////////////////////////////////////////////// @@ -4617,12 +8860,12 @@ namespace validation_layer auto pfnGetFileDescriptorFromIpcHandleExp = context.zeDdiTable.MemExp.pfnGetFileDescriptorFromIpcHandleExp; if( nullptr == pfnGetFileDescriptorFromIpcHandleExp ) - return logAndPropagateResult("zeMemGetFileDescriptorFromIpcHandleExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ipcHandle, pHandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetFileDescriptorFromIpcHandleExpPrologue( hContext, ipcHandle, pHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetFileDescriptorFromIpcHandleExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp(result, hContext, ipcHandle, pHandle); } @@ -4633,21 +8876,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetFileDescriptorFromIpcHandleExpPrologue( hContext, ipcHandle, pHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetFileDescriptorFromIpcHandleExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp(result, hContext, ipcHandle, pHandle); } auto driver_result = pfnGetFileDescriptorFromIpcHandleExp( hContext, ipcHandle, pHandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetFileDescriptorFromIpcHandleExpEpilogue( hContext, ipcHandle, pHandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetFileDescriptorFromIpcHandleExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp(result, hContext, ipcHandle, pHandle); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeMemGetFileDescriptorFromIpcHandleExp", driver_result); + return logAndPropagateResult_zeMemGetFileDescriptorFromIpcHandleExp(driver_result, hContext, ipcHandle, pHandle); } /////////////////////////////////////////////////////////////////////////////// @@ -4663,12 +8906,12 @@ namespace validation_layer auto pfnPutIpcHandle = context.zeDdiTable.Mem.pfnPutIpcHandle; if( nullptr == pfnPutIpcHandle ) - return logAndPropagateResult("zeMemPutIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemPutIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, handle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemPutIpcHandlePrologue( hContext, handle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemPutIpcHandle(result, hContext, handle); } @@ -4679,17 +8922,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemPutIpcHandlePrologue( hContext, handle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemPutIpcHandle(result, hContext, handle); } auto driver_result = pfnPutIpcHandle( hContext, handle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemPutIpcHandleEpilogue( hContext, handle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemPutIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemPutIpcHandle(result, hContext, handle); } - return logAndPropagateResult("zeMemPutIpcHandle", driver_result); + return logAndPropagateResult_zeMemPutIpcHandle(driver_result, hContext, handle); } /////////////////////////////////////////////////////////////////////////////// @@ -4709,12 +8952,12 @@ namespace validation_layer auto pfnOpenIpcHandle = context.zeDdiTable.Mem.pfnOpenIpcHandle; if( nullptr == pfnOpenIpcHandle ) - return logAndPropagateResult("zeMemOpenIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemOpenIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, handle, flags, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemOpenIpcHandlePrologue( hContext, hDevice, handle, flags, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemOpenIpcHandle(result, hContext, hDevice, handle, flags, pptr); } @@ -4725,17 +8968,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemOpenIpcHandlePrologue( hContext, hDevice, handle, flags, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemOpenIpcHandle(result, hContext, hDevice, handle, flags, pptr); } auto driver_result = pfnOpenIpcHandle( hContext, hDevice, handle, flags, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemOpenIpcHandleEpilogue( hContext, hDevice, handle, flags, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemOpenIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemOpenIpcHandle(result, hContext, hDevice, handle, flags, pptr); } - return logAndPropagateResult("zeMemOpenIpcHandle", driver_result); + return logAndPropagateResult_zeMemOpenIpcHandle(driver_result, hContext, hDevice, handle, flags, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4751,12 +8994,12 @@ namespace validation_layer auto pfnCloseIpcHandle = context.zeDdiTable.Mem.pfnCloseIpcHandle; if( nullptr == pfnCloseIpcHandle ) - return logAndPropagateResult("zeMemCloseIpcHandle", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemCloseIpcHandle(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemCloseIpcHandlePrologue( hContext, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemCloseIpcHandle(result, hContext, ptr); } @@ -4767,17 +9010,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemCloseIpcHandlePrologue( hContext, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemCloseIpcHandle(result, hContext, ptr); } auto driver_result = pfnCloseIpcHandle( hContext, ptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemCloseIpcHandleEpilogue( hContext, ptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemCloseIpcHandle", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemCloseIpcHandle(result, hContext, ptr); } - return logAndPropagateResult("zeMemCloseIpcHandle", driver_result); + return logAndPropagateResult_zeMemCloseIpcHandle(driver_result, hContext, ptr); } /////////////////////////////////////////////////////////////////////////////// @@ -4797,12 +9040,12 @@ namespace validation_layer auto pfnSetAtomicAccessAttributeExp = context.zeDdiTable.MemExp.pfnSetAtomicAccessAttributeExp; if( nullptr == pfnSetAtomicAccessAttributeExp ) - return logAndPropagateResult("zeMemSetAtomicAccessAttributeExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemSetAtomicAccessAttributeExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, ptr, size, attr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemSetAtomicAccessAttributeExpPrologue( hContext, hDevice, ptr, size, attr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemSetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemSetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, attr); } @@ -4813,17 +9056,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemSetAtomicAccessAttributeExpPrologue( hContext, hDevice, ptr, size, attr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemSetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemSetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, attr); } auto driver_result = pfnSetAtomicAccessAttributeExp( hContext, hDevice, ptr, size, attr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemSetAtomicAccessAttributeExpEpilogue( hContext, hDevice, ptr, size, attr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemSetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemSetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, attr); } - return logAndPropagateResult("zeMemSetAtomicAccessAttributeExp", driver_result); + return logAndPropagateResult_zeMemSetAtomicAccessAttributeExp(driver_result, hContext, hDevice, ptr, size, attr); } /////////////////////////////////////////////////////////////////////////////// @@ -4842,12 +9085,12 @@ namespace validation_layer auto pfnGetAtomicAccessAttributeExp = context.zeDdiTable.MemExp.pfnGetAtomicAccessAttributeExp; if( nullptr == pfnGetAtomicAccessAttributeExp ) - return logAndPropagateResult("zeMemGetAtomicAccessAttributeExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetAtomicAccessAttributeExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, ptr, size, pAttr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAtomicAccessAttributeExpPrologue( hContext, hDevice, ptr, size, pAttr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, pAttr); } @@ -4858,21 +9101,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetAtomicAccessAttributeExpPrologue( hContext, hDevice, ptr, size, pAttr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, pAttr); } auto driver_result = pfnGetAtomicAccessAttributeExp( hContext, hDevice, ptr, size, pAttr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetAtomicAccessAttributeExpEpilogue( hContext, hDevice, ptr, size, pAttr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetAtomicAccessAttributeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetAtomicAccessAttributeExp(result, hContext, hDevice, ptr, size, pAttr); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeMemGetAtomicAccessAttributeExp", driver_result); + return logAndPropagateResult_zeMemGetAtomicAccessAttributeExp(driver_result, hContext, hDevice, ptr, size, pAttr); } /////////////////////////////////////////////////////////////////////////////// @@ -4891,12 +9134,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Module.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeModuleCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phModule, phBuildLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleCreatePrologue( hContext, hDevice, desc, phModule, phBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleCreate(result, hContext, hDevice, desc, phModule, phBuildLog); } @@ -4907,14 +9150,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleCreatePrologue( hContext, hDevice, desc, phModule, phBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleCreate(result, hContext, hDevice, desc, phModule, phBuildLog); } auto driver_result = pfnCreate( hContext, hDevice, desc, phModule, phBuildLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleCreateEpilogue( hContext, hDevice, desc, phModule, phBuildLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleCreate(result, hContext, hDevice, desc, phModule, phBuildLog); } @@ -4931,7 +9174,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeModuleCreate", driver_result); + return logAndPropagateResult_zeModuleCreate(driver_result, hContext, hDevice, desc, phModule, phBuildLog); } /////////////////////////////////////////////////////////////////////////////// @@ -4946,12 +9189,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Module.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeModuleDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleDestroyPrologue( hModule ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDestroy(result, hModule); } @@ -4962,17 +9205,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleDestroyPrologue( hModule ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDestroy(result, hModule); } auto driver_result = pfnDestroy( hModule ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleDestroyEpilogue( hModule ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDestroy(result, hModule); } - return logAndPropagateResult("zeModuleDestroy", driver_result); + return logAndPropagateResult_zeModuleDestroy(driver_result, hModule); } /////////////////////////////////////////////////////////////////////////////// @@ -4990,12 +9233,12 @@ namespace validation_layer auto pfnDynamicLink = context.zeDdiTable.Module.pfnDynamicLink; if( nullptr == pfnDynamicLink ) - return logAndPropagateResult("zeModuleDynamicLink", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleDynamicLink(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, numModules, phModules, phLinkLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleDynamicLinkPrologue( numModules, phModules, phLinkLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDynamicLink", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDynamicLink(result, numModules, phModules, phLinkLog); } @@ -5006,17 +9249,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleDynamicLinkPrologue( numModules, phModules, phLinkLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDynamicLink", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDynamicLink(result, numModules, phModules, phLinkLog); } auto driver_result = pfnDynamicLink( numModules, phModules, phLinkLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleDynamicLinkEpilogue( numModules, phModules, phLinkLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleDynamicLink", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleDynamicLink(result, numModules, phModules, phLinkLog); } - return logAndPropagateResult("zeModuleDynamicLink", driver_result); + return logAndPropagateResult_zeModuleDynamicLink(driver_result, numModules, phModules, phLinkLog); } /////////////////////////////////////////////////////////////////////////////// @@ -5031,12 +9274,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.ModuleBuildLog.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeModuleBuildLogDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleBuildLogDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModuleBuildLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleBuildLogDestroyPrologue( hModuleBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogDestroy(result, hModuleBuildLog); } @@ -5047,17 +9290,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleBuildLogDestroyPrologue( hModuleBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogDestroy(result, hModuleBuildLog); } auto driver_result = pfnDestroy( hModuleBuildLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleBuildLogDestroyEpilogue( hModuleBuildLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogDestroy(result, hModuleBuildLog); } - return logAndPropagateResult("zeModuleBuildLogDestroy", driver_result); + return logAndPropagateResult_zeModuleBuildLogDestroy(driver_result, hModuleBuildLog); } /////////////////////////////////////////////////////////////////////////////// @@ -5074,12 +9317,12 @@ namespace validation_layer auto pfnGetString = context.zeDdiTable.ModuleBuildLog.pfnGetString; if( nullptr == pfnGetString ) - return logAndPropagateResult("zeModuleBuildLogGetString", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleBuildLogGetString(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModuleBuildLog, pSize, pBuildLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleBuildLogGetStringPrologue( hModuleBuildLog, pSize, pBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogGetString", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogGetString(result, hModuleBuildLog, pSize, pBuildLog); } @@ -5090,17 +9333,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleBuildLogGetStringPrologue( hModuleBuildLog, pSize, pBuildLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogGetString", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogGetString(result, hModuleBuildLog, pSize, pBuildLog); } auto driver_result = pfnGetString( hModuleBuildLog, pSize, pBuildLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleBuildLogGetStringEpilogue( hModuleBuildLog, pSize, pBuildLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleBuildLogGetString", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleBuildLogGetString(result, hModuleBuildLog, pSize, pBuildLog); } - return logAndPropagateResult("zeModuleBuildLogGetString", driver_result); + return logAndPropagateResult_zeModuleBuildLogGetString(driver_result, hModuleBuildLog, pSize, pBuildLog); } /////////////////////////////////////////////////////////////////////////////// @@ -5117,12 +9360,12 @@ namespace validation_layer auto pfnGetNativeBinary = context.zeDdiTable.Module.pfnGetNativeBinary; if( nullptr == pfnGetNativeBinary ) - return logAndPropagateResult("zeModuleGetNativeBinary", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleGetNativeBinary(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, pSize, pModuleNativeBinary); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetNativeBinaryPrologue( hModule, pSize, pModuleNativeBinary ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetNativeBinary", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetNativeBinary(result, hModule, pSize, pModuleNativeBinary); } @@ -5133,17 +9376,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleGetNativeBinaryPrologue( hModule, pSize, pModuleNativeBinary ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetNativeBinary", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetNativeBinary(result, hModule, pSize, pModuleNativeBinary); } auto driver_result = pfnGetNativeBinary( hModule, pSize, pModuleNativeBinary ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetNativeBinaryEpilogue( hModule, pSize, pModuleNativeBinary ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetNativeBinary", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetNativeBinary(result, hModule, pSize, pModuleNativeBinary); } - return logAndPropagateResult("zeModuleGetNativeBinary", driver_result); + return logAndPropagateResult_zeModuleGetNativeBinary(driver_result, hModule, pSize, pModuleNativeBinary); } /////////////////////////////////////////////////////////////////////////////// @@ -5161,12 +9404,12 @@ namespace validation_layer auto pfnGetGlobalPointer = context.zeDdiTable.Module.pfnGetGlobalPointer; if( nullptr == pfnGetGlobalPointer ) - return logAndPropagateResult("zeModuleGetGlobalPointer", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleGetGlobalPointer(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, pGlobalName, pSize, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetGlobalPointerPrologue( hModule, pGlobalName, pSize, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetGlobalPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetGlobalPointer(result, hModule, pGlobalName, pSize, pptr); } @@ -5177,17 +9420,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleGetGlobalPointerPrologue( hModule, pGlobalName, pSize, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetGlobalPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetGlobalPointer(result, hModule, pGlobalName, pSize, pptr); } auto driver_result = pfnGetGlobalPointer( hModule, pGlobalName, pSize, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetGlobalPointerEpilogue( hModule, pGlobalName, pSize, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetGlobalPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetGlobalPointer(result, hModule, pGlobalName, pSize, pptr); } - return logAndPropagateResult("zeModuleGetGlobalPointer", driver_result); + return logAndPropagateResult_zeModuleGetGlobalPointer(driver_result, hModule, pGlobalName, pSize, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -5210,12 +9453,12 @@ namespace validation_layer auto pfnGetKernelNames = context.zeDdiTable.Module.pfnGetKernelNames; if( nullptr == pfnGetKernelNames ) - return logAndPropagateResult("zeModuleGetKernelNames", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleGetKernelNames(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, pCount, pNames); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetKernelNamesPrologue( hModule, pCount, pNames ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetKernelNames", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetKernelNames(result, hModule, pCount, pNames); } @@ -5226,17 +9469,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleGetKernelNamesPrologue( hModule, pCount, pNames ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetKernelNames", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetKernelNames(result, hModule, pCount, pNames); } auto driver_result = pfnGetKernelNames( hModule, pCount, pNames ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetKernelNamesEpilogue( hModule, pCount, pNames ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetKernelNames", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetKernelNames(result, hModule, pCount, pNames); } - return logAndPropagateResult("zeModuleGetKernelNames", driver_result); + return logAndPropagateResult_zeModuleGetKernelNames(driver_result, hModule, pCount, pNames); } /////////////////////////////////////////////////////////////////////////////// @@ -5252,12 +9495,12 @@ namespace validation_layer auto pfnGetProperties = context.zeDdiTable.Module.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zeModuleGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, pModuleProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetPropertiesPrologue( hModule, pModuleProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetProperties(result, hModule, pModuleProperties); } @@ -5268,17 +9511,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleGetPropertiesPrologue( hModule, pModuleProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetProperties(result, hModule, pModuleProperties); } auto driver_result = pfnGetProperties( hModule, pModuleProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetPropertiesEpilogue( hModule, pModuleProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetProperties(result, hModule, pModuleProperties); } - return logAndPropagateResult("zeModuleGetProperties", driver_result); + return logAndPropagateResult_zeModuleGetProperties(driver_result, hModule, pModuleProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -5295,12 +9538,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Kernel.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeKernelCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, desc, phKernel); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelCreatePrologue( hModule, desc, phKernel ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelCreate(result, hModule, desc, phKernel); } @@ -5311,14 +9554,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelCreatePrologue( hModule, desc, phKernel ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelCreate(result, hModule, desc, phKernel); } auto driver_result = pfnCreate( hModule, desc, phKernel ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelCreateEpilogue( hModule, desc, phKernel ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelCreate(result, hModule, desc, phKernel); } @@ -5330,7 +9573,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeKernelCreate", driver_result); + return logAndPropagateResult_zeKernelCreate(driver_result, hModule, desc, phKernel); } /////////////////////////////////////////////////////////////////////////////// @@ -5345,12 +9588,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Kernel.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeKernelDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelDestroyPrologue( hKernel ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelDestroy(result, hKernel); } @@ -5361,17 +9604,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelDestroyPrologue( hKernel ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelDestroy(result, hKernel); } auto driver_result = pfnDestroy( hKernel ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelDestroyEpilogue( hKernel ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelDestroy(result, hKernel); } - return logAndPropagateResult("zeKernelDestroy", driver_result); + return logAndPropagateResult_zeKernelDestroy(driver_result, hKernel); } /////////////////////////////////////////////////////////////////////////////// @@ -5388,12 +9631,12 @@ namespace validation_layer auto pfnGetFunctionPointer = context.zeDdiTable.Module.pfnGetFunctionPointer; if( nullptr == pfnGetFunctionPointer ) - return logAndPropagateResult("zeModuleGetFunctionPointer", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleGetFunctionPointer(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, pFunctionName, pfnFunction); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetFunctionPointerPrologue( hModule, pFunctionName, pfnFunction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetFunctionPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetFunctionPointer(result, hModule, pFunctionName, pfnFunction); } @@ -5404,17 +9647,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleGetFunctionPointerPrologue( hModule, pFunctionName, pfnFunction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetFunctionPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetFunctionPointer(result, hModule, pFunctionName, pfnFunction); } auto driver_result = pfnGetFunctionPointer( hModule, pFunctionName, pfnFunction ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleGetFunctionPointerEpilogue( hModule, pFunctionName, pfnFunction ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleGetFunctionPointer", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleGetFunctionPointer(result, hModule, pFunctionName, pfnFunction); } - return logAndPropagateResult("zeModuleGetFunctionPointer", driver_result); + return logAndPropagateResult_zeModuleGetFunctionPointer(driver_result, hModule, pFunctionName, pfnFunction); } /////////////////////////////////////////////////////////////////////////////// @@ -5432,12 +9675,12 @@ namespace validation_layer auto pfnSetGroupSize = context.zeDdiTable.Kernel.pfnSetGroupSize; if( nullptr == pfnSetGroupSize ) - return logAndPropagateResult("zeKernelSetGroupSize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSetGroupSize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, groupSizeX, groupSizeY, groupSizeZ); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetGroupSizePrologue( hKernel, groupSizeX, groupSizeY, groupSizeZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGroupSize(result, hKernel, groupSizeX, groupSizeY, groupSizeZ); } @@ -5448,17 +9691,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSetGroupSizePrologue( hKernel, groupSizeX, groupSizeY, groupSizeZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGroupSize(result, hKernel, groupSizeX, groupSizeY, groupSizeZ); } auto driver_result = pfnSetGroupSize( hKernel, groupSizeX, groupSizeY, groupSizeZ ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetGroupSizeEpilogue( hKernel, groupSizeX, groupSizeY, groupSizeZ ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGroupSize(result, hKernel, groupSizeX, groupSizeY, groupSizeZ); } - return logAndPropagateResult("zeKernelSetGroupSize", driver_result); + return logAndPropagateResult_zeKernelSetGroupSize(driver_result, hKernel, groupSizeX, groupSizeY, groupSizeZ); } /////////////////////////////////////////////////////////////////////////////// @@ -5479,12 +9722,12 @@ namespace validation_layer auto pfnSuggestGroupSize = context.zeDdiTable.Kernel.pfnSuggestGroupSize; if( nullptr == pfnSuggestGroupSize ) - return logAndPropagateResult("zeKernelSuggestGroupSize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSuggestGroupSize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSuggestGroupSizePrologue( hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestGroupSize(result, hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ); } @@ -5495,17 +9738,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSuggestGroupSizePrologue( hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestGroupSize(result, hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ); } auto driver_result = pfnSuggestGroupSize( hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSuggestGroupSizeEpilogue( hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestGroupSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestGroupSize(result, hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ); } - return logAndPropagateResult("zeKernelSuggestGroupSize", driver_result); + return logAndPropagateResult_zeKernelSuggestGroupSize(driver_result, hKernel, globalSizeX, globalSizeY, globalSizeZ, groupSizeX, groupSizeY, groupSizeZ); } /////////////////////////////////////////////////////////////////////////////// @@ -5521,12 +9764,12 @@ namespace validation_layer auto pfnSuggestMaxCooperativeGroupCount = context.zeDdiTable.Kernel.pfnSuggestMaxCooperativeGroupCount; if( nullptr == pfnSuggestMaxCooperativeGroupCount ) - return logAndPropagateResult("zeKernelSuggestMaxCooperativeGroupCount", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, totalGroupCount); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSuggestMaxCooperativeGroupCountPrologue( hKernel, totalGroupCount ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestMaxCooperativeGroupCount", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount(result, hKernel, totalGroupCount); } @@ -5537,17 +9780,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSuggestMaxCooperativeGroupCountPrologue( hKernel, totalGroupCount ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestMaxCooperativeGroupCount", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount(result, hKernel, totalGroupCount); } auto driver_result = pfnSuggestMaxCooperativeGroupCount( hKernel, totalGroupCount ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSuggestMaxCooperativeGroupCountEpilogue( hKernel, totalGroupCount ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSuggestMaxCooperativeGroupCount", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount(result, hKernel, totalGroupCount); } - return logAndPropagateResult("zeKernelSuggestMaxCooperativeGroupCount", driver_result); + return logAndPropagateResult_zeKernelSuggestMaxCooperativeGroupCount(driver_result, hKernel, totalGroupCount); } /////////////////////////////////////////////////////////////////////////////// @@ -5566,12 +9809,12 @@ namespace validation_layer auto pfnSetArgumentValue = context.zeDdiTable.Kernel.pfnSetArgumentValue; if( nullptr == pfnSetArgumentValue ) - return logAndPropagateResult("zeKernelSetArgumentValue", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSetArgumentValue(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, argIndex, argSize, pArgValue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetArgumentValuePrologue( hKernel, argIndex, argSize, pArgValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetArgumentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetArgumentValue(result, hKernel, argIndex, argSize, pArgValue); } @@ -5582,17 +9825,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSetArgumentValuePrologue( hKernel, argIndex, argSize, pArgValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetArgumentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetArgumentValue(result, hKernel, argIndex, argSize, pArgValue); } auto driver_result = pfnSetArgumentValue( hKernel, argIndex, argSize, pArgValue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetArgumentValueEpilogue( hKernel, argIndex, argSize, pArgValue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetArgumentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetArgumentValue(result, hKernel, argIndex, argSize, pArgValue); } - return logAndPropagateResult("zeKernelSetArgumentValue", driver_result); + return logAndPropagateResult_zeKernelSetArgumentValue(driver_result, hKernel, argIndex, argSize, pArgValue); } /////////////////////////////////////////////////////////////////////////////// @@ -5608,12 +9851,12 @@ namespace validation_layer auto pfnSetIndirectAccess = context.zeDdiTable.Kernel.pfnSetIndirectAccess; if( nullptr == pfnSetIndirectAccess ) - return logAndPropagateResult("zeKernelSetIndirectAccess", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSetIndirectAccess(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, flags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetIndirectAccessPrologue( hKernel, flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetIndirectAccess(result, hKernel, flags); } @@ -5624,17 +9867,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSetIndirectAccessPrologue( hKernel, flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetIndirectAccess(result, hKernel, flags); } auto driver_result = pfnSetIndirectAccess( hKernel, flags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetIndirectAccessEpilogue( hKernel, flags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetIndirectAccess(result, hKernel, flags); } - return logAndPropagateResult("zeKernelSetIndirectAccess", driver_result); + return logAndPropagateResult_zeKernelSetIndirectAccess(driver_result, hKernel, flags); } /////////////////////////////////////////////////////////////////////////////// @@ -5650,12 +9893,12 @@ namespace validation_layer auto pfnGetIndirectAccess = context.zeDdiTable.Kernel.pfnGetIndirectAccess; if( nullptr == pfnGetIndirectAccess ) - return logAndPropagateResult("zeKernelGetIndirectAccess", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetIndirectAccess(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pFlags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetIndirectAccessPrologue( hKernel, pFlags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetIndirectAccess(result, hKernel, pFlags); } @@ -5666,17 +9909,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetIndirectAccessPrologue( hKernel, pFlags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetIndirectAccess(result, hKernel, pFlags); } auto driver_result = pfnGetIndirectAccess( hKernel, pFlags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetIndirectAccessEpilogue( hKernel, pFlags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetIndirectAccess", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetIndirectAccess(result, hKernel, pFlags); } - return logAndPropagateResult("zeKernelGetIndirectAccess", driver_result); + return logAndPropagateResult_zeKernelGetIndirectAccess(driver_result, hKernel, pFlags); } /////////////////////////////////////////////////////////////////////////////// @@ -5704,12 +9947,12 @@ namespace validation_layer auto pfnGetSourceAttributes = context.zeDdiTable.Kernel.pfnGetSourceAttributes; if( nullptr == pfnGetSourceAttributes ) - return logAndPropagateResult("zeKernelGetSourceAttributes", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetSourceAttributes(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pSize, pString); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetSourceAttributesPrologue( hKernel, pSize, pString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetSourceAttributes", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetSourceAttributes(result, hKernel, pSize, pString); } @@ -5720,17 +9963,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetSourceAttributesPrologue( hKernel, pSize, pString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetSourceAttributes", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetSourceAttributes(result, hKernel, pSize, pString); } auto driver_result = pfnGetSourceAttributes( hKernel, pSize, pString ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetSourceAttributesEpilogue( hKernel, pSize, pString ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetSourceAttributes", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetSourceAttributes(result, hKernel, pSize, pString); } - return logAndPropagateResult("zeKernelGetSourceAttributes", driver_result); + return logAndPropagateResult_zeKernelGetSourceAttributes(driver_result, hKernel, pSize, pString); } /////////////////////////////////////////////////////////////////////////////// @@ -5747,12 +9990,12 @@ namespace validation_layer auto pfnSetCacheConfig = context.zeDdiTable.Kernel.pfnSetCacheConfig; if( nullptr == pfnSetCacheConfig ) - return logAndPropagateResult("zeKernelSetCacheConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSetCacheConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, flags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetCacheConfigPrologue( hKernel, flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetCacheConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetCacheConfig(result, hKernel, flags); } @@ -5763,17 +10006,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSetCacheConfigPrologue( hKernel, flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetCacheConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetCacheConfig(result, hKernel, flags); } auto driver_result = pfnSetCacheConfig( hKernel, flags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetCacheConfigEpilogue( hKernel, flags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetCacheConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetCacheConfig(result, hKernel, flags); } - return logAndPropagateResult("zeKernelSetCacheConfig", driver_result); + return logAndPropagateResult_zeKernelSetCacheConfig(driver_result, hKernel, flags); } /////////////////////////////////////////////////////////////////////////////// @@ -5789,12 +10032,12 @@ namespace validation_layer auto pfnGetProperties = context.zeDdiTable.Kernel.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zeKernelGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pKernelProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetPropertiesPrologue( hKernel, pKernelProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetProperties(result, hKernel, pKernelProperties); } @@ -5805,17 +10048,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetPropertiesPrologue( hKernel, pKernelProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetProperties(result, hKernel, pKernelProperties); } auto driver_result = pfnGetProperties( hKernel, pKernelProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetPropertiesEpilogue( hKernel, pKernelProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetProperties(result, hKernel, pKernelProperties); } - return logAndPropagateResult("zeKernelGetProperties", driver_result); + return logAndPropagateResult_zeKernelGetProperties(driver_result, hKernel, pKernelProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -5833,12 +10076,12 @@ namespace validation_layer auto pfnGetName = context.zeDdiTable.Kernel.pfnGetName; if( nullptr == pfnGetName ) - return logAndPropagateResult("zeKernelGetName", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetName(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pSize, pName); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetNamePrologue( hKernel, pSize, pName ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetName", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetName(result, hKernel, pSize, pName); } @@ -5849,17 +10092,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetNamePrologue( hKernel, pSize, pName ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetName", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetName(result, hKernel, pSize, pName); } auto driver_result = pfnGetName( hKernel, pSize, pName ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetNameEpilogue( hKernel, pSize, pName ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetName", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetName(result, hKernel, pSize, pName); } - return logAndPropagateResult("zeKernelGetName", driver_result); + return logAndPropagateResult_zeKernelGetName(driver_result, hKernel, pSize, pName); } /////////////////////////////////////////////////////////////////////////////// @@ -5881,12 +10124,12 @@ namespace validation_layer auto pfnAppendLaunchKernel = context.zeDdiTable.CommandList.pfnAppendLaunchKernel; if( nullptr == pfnAppendLaunchKernel ) - return logAndPropagateResult("zeCommandListAppendLaunchKernel", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchKernel(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelPrologue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -5897,17 +10140,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchKernelPrologue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchKernel( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelEpilogue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchKernel", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchKernel(driver_result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -5930,12 +10173,12 @@ namespace validation_layer auto pfnAppendLaunchKernelWithParameters = context.zeDdiTable.CommandList.pfnAppendLaunchKernelWithParameters; if( nullptr == pfnAppendLaunchKernelWithParameters ) - return logAndPropagateResult("zeCommandListAppendLaunchKernelWithParameters", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelWithParametersPrologue( hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithParameters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters(result, hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -5946,17 +10189,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchKernelWithParametersPrologue( hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithParameters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters(result, hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchKernelWithParameters( hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelWithParametersEpilogue( hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithParameters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters(result, hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchKernelWithParameters", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchKernelWithParameters(driver_result, hCommandList, hKernel, pGroupCounts, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -5981,12 +10224,12 @@ namespace validation_layer auto pfnAppendLaunchKernelWithArguments = context.zeDdiTable.CommandList.pfnAppendLaunchKernelWithArguments; if( nullptr == pfnAppendLaunchKernelWithArguments ) - return logAndPropagateResult("zeCommandListAppendLaunchKernelWithArguments", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelWithArgumentsPrologue( hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithArguments", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments(result, hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -5997,17 +10240,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchKernelWithArgumentsPrologue( hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithArguments", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments(result, hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchKernelWithArguments( hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelWithArgumentsEpilogue( hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelWithArguments", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments(result, hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchKernelWithArguments", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchKernelWithArguments(driver_result, hCommandList, hKernel, groupCounts, groupSizes, pArguments, pNext, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -6029,12 +10272,12 @@ namespace validation_layer auto pfnAppendLaunchCooperativeKernel = context.zeDdiTable.CommandList.pfnAppendLaunchCooperativeKernel; if( nullptr == pfnAppendLaunchCooperativeKernel ) - return logAndPropagateResult("zeCommandListAppendLaunchCooperativeKernel", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchCooperativeKernelPrologue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchCooperativeKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -6045,17 +10288,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchCooperativeKernelPrologue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchCooperativeKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchCooperativeKernel( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchCooperativeKernelEpilogue( hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchCooperativeKernel", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel(result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchCooperativeKernel", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchCooperativeKernel(driver_result, hCommandList, hKernel, pLaunchFuncArgs, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -6078,12 +10321,12 @@ namespace validation_layer auto pfnAppendLaunchKernelIndirect = context.zeDdiTable.CommandList.pfnAppendLaunchKernelIndirect; if( nullptr == pfnAppendLaunchKernelIndirect ) - return logAndPropagateResult("zeCommandListAppendLaunchKernelIndirect", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelIndirectPrologue( hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect(result, hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -6094,17 +10337,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchKernelIndirectPrologue( hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect(result, hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchKernelIndirect( hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchKernelIndirectEpilogue( hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchKernelIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect(result, hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchKernelIndirect", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchKernelIndirect(driver_result, hCommandList, hKernel, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -6131,12 +10374,12 @@ namespace validation_layer auto pfnAppendLaunchMultipleKernelsIndirect = context.zeDdiTable.CommandList.pfnAppendLaunchMultipleKernelsIndirect; if( nullptr == pfnAppendLaunchMultipleKernelsIndirect ) - return logAndPropagateResult("zeCommandListAppendLaunchMultipleKernelsIndirect", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchMultipleKernelsIndirectPrologue( hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchMultipleKernelsIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect(result, hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -6147,17 +10390,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendLaunchMultipleKernelsIndirectPrologue( hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchMultipleKernelsIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect(result, hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendLaunchMultipleKernelsIndirect( hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendLaunchMultipleKernelsIndirectEpilogue( hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendLaunchMultipleKernelsIndirect", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect(result, hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendLaunchMultipleKernelsIndirect", driver_result); + return logAndPropagateResult_zeCommandListAppendLaunchMultipleKernelsIndirect(driver_result, hCommandList, numKernels, phKernels, pCountBuffer, pLaunchArgumentsBuffer, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -6175,12 +10418,12 @@ namespace validation_layer auto pfnMakeMemoryResident = context.zeDdiTable.Context.pfnMakeMemoryResident; if( nullptr == pfnMakeMemoryResident ) - return logAndPropagateResult("zeContextMakeMemoryResident", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextMakeMemoryResident(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, ptr, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextMakeMemoryResidentPrologue( hContext, hDevice, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeMemoryResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeMemoryResident(result, hContext, hDevice, ptr, size); } @@ -6191,17 +10434,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextMakeMemoryResidentPrologue( hContext, hDevice, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeMemoryResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeMemoryResident(result, hContext, hDevice, ptr, size); } auto driver_result = pfnMakeMemoryResident( hContext, hDevice, ptr, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextMakeMemoryResidentEpilogue( hContext, hDevice, ptr, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeMemoryResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeMemoryResident(result, hContext, hDevice, ptr, size); } - return logAndPropagateResult("zeContextMakeMemoryResident", driver_result); + return logAndPropagateResult_zeContextMakeMemoryResident(driver_result, hContext, hDevice, ptr, size); } /////////////////////////////////////////////////////////////////////////////// @@ -6219,12 +10462,12 @@ namespace validation_layer auto pfnEvictMemory = context.zeDdiTable.Context.pfnEvictMemory; if( nullptr == pfnEvictMemory ) - return logAndPropagateResult("zeContextEvictMemory", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextEvictMemory(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, ptr, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextEvictMemoryPrologue( hContext, hDevice, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictMemory(result, hContext, hDevice, ptr, size); } @@ -6235,17 +10478,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextEvictMemoryPrologue( hContext, hDevice, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictMemory(result, hContext, hDevice, ptr, size); } auto driver_result = pfnEvictMemory( hContext, hDevice, ptr, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextEvictMemoryEpilogue( hContext, hDevice, ptr, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictMemory(result, hContext, hDevice, ptr, size); } - return logAndPropagateResult("zeContextEvictMemory", driver_result); + return logAndPropagateResult_zeContextEvictMemory(driver_result, hContext, hDevice, ptr, size); } /////////////////////////////////////////////////////////////////////////////// @@ -6262,12 +10505,12 @@ namespace validation_layer auto pfnMakeImageResident = context.zeDdiTable.Context.pfnMakeImageResident; if( nullptr == pfnMakeImageResident ) - return logAndPropagateResult("zeContextMakeImageResident", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextMakeImageResident(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, hImage); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextMakeImageResidentPrologue( hContext, hDevice, hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeImageResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeImageResident(result, hContext, hDevice, hImage); } @@ -6278,17 +10521,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextMakeImageResidentPrologue( hContext, hDevice, hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeImageResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeImageResident(result, hContext, hDevice, hImage); } auto driver_result = pfnMakeImageResident( hContext, hDevice, hImage ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextMakeImageResidentEpilogue( hContext, hDevice, hImage ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextMakeImageResident", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextMakeImageResident(result, hContext, hDevice, hImage); } - return logAndPropagateResult("zeContextMakeImageResident", driver_result); + return logAndPropagateResult_zeContextMakeImageResident(driver_result, hContext, hDevice, hImage); } /////////////////////////////////////////////////////////////////////////////// @@ -6305,12 +10548,12 @@ namespace validation_layer auto pfnEvictImage = context.zeDdiTable.Context.pfnEvictImage; if( nullptr == pfnEvictImage ) - return logAndPropagateResult("zeContextEvictImage", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeContextEvictImage(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, hImage); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextEvictImagePrologue( hContext, hDevice, hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictImage(result, hContext, hDevice, hImage); } @@ -6321,17 +10564,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeContextEvictImagePrologue( hContext, hDevice, hImage ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictImage(result, hContext, hDevice, hImage); } auto driver_result = pfnEvictImage( hContext, hDevice, hImage ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeContextEvictImageEpilogue( hContext, hDevice, hImage ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeContextEvictImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeContextEvictImage(result, hContext, hDevice, hImage); } - return logAndPropagateResult("zeContextEvictImage", driver_result); + return logAndPropagateResult_zeContextEvictImage(driver_result, hContext, hDevice, hImage); } /////////////////////////////////////////////////////////////////////////////// @@ -6349,12 +10592,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.Sampler.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zeSamplerCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeSamplerCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phSampler); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeSamplerCreatePrologue( hContext, hDevice, desc, phSampler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerCreate(result, hContext, hDevice, desc, phSampler); } @@ -6365,14 +10608,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeSamplerCreatePrologue( hContext, hDevice, desc, phSampler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerCreate(result, hContext, hDevice, desc, phSampler); } auto driver_result = pfnCreate( hContext, hDevice, desc, phSampler ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeSamplerCreateEpilogue( hContext, hDevice, desc, phSampler ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerCreate(result, hContext, hDevice, desc, phSampler); } @@ -6384,7 +10627,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeSamplerCreate", driver_result); + return logAndPropagateResult_zeSamplerCreate(driver_result, hContext, hDevice, desc, phSampler); } /////////////////////////////////////////////////////////////////////////////// @@ -6399,12 +10642,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.Sampler.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zeSamplerDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeSamplerDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hSampler); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeSamplerDestroyPrologue( hSampler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerDestroy(result, hSampler); } @@ -6415,17 +10658,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeSamplerDestroyPrologue( hSampler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerDestroy(result, hSampler); } auto driver_result = pfnDestroy( hSampler ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeSamplerDestroyEpilogue( hSampler ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeSamplerDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeSamplerDestroy(result, hSampler); } - return logAndPropagateResult("zeSamplerDestroy", driver_result); + return logAndPropagateResult_zeSamplerDestroy(driver_result, hSampler); } /////////////////////////////////////////////////////////////////////////////// @@ -6444,12 +10687,12 @@ namespace validation_layer auto pfnReserve = context.zeDdiTable.VirtualMem.pfnReserve; if( nullptr == pfnReserve ) - return logAndPropagateResult("zeVirtualMemReserve", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemReserve(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, pStart, size, pptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemReservePrologue( hContext, pStart, size, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemReserve", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemReserve(result, hContext, pStart, size, pptr); } @@ -6460,17 +10703,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemReservePrologue( hContext, pStart, size, pptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemReserve", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemReserve(result, hContext, pStart, size, pptr); } auto driver_result = pfnReserve( hContext, pStart, size, pptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemReserveEpilogue( hContext, pStart, size, pptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemReserve", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemReserve(result, hContext, pStart, size, pptr); } - return logAndPropagateResult("zeVirtualMemReserve", driver_result); + return logAndPropagateResult_zeVirtualMemReserve(driver_result, hContext, pStart, size, pptr); } /////////////////////////////////////////////////////////////////////////////// @@ -6487,12 +10730,12 @@ namespace validation_layer auto pfnFree = context.zeDdiTable.VirtualMem.pfnFree; if( nullptr == pfnFree ) - return logAndPropagateResult("zeVirtualMemFree", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemFree(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemFreePrologue( hContext, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemFree(result, hContext, ptr, size); } @@ -6503,17 +10746,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemFreePrologue( hContext, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemFree(result, hContext, ptr, size); } auto driver_result = pfnFree( hContext, ptr, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemFreeEpilogue( hContext, ptr, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemFree", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemFree(result, hContext, ptr, size); } - return logAndPropagateResult("zeVirtualMemFree", driver_result); + return logAndPropagateResult_zeVirtualMemFree(driver_result, hContext, ptr, size); } /////////////////////////////////////////////////////////////////////////////// @@ -6532,12 +10775,12 @@ namespace validation_layer auto pfnQueryPageSize = context.zeDdiTable.VirtualMem.pfnQueryPageSize; if( nullptr == pfnQueryPageSize ) - return logAndPropagateResult("zeVirtualMemQueryPageSize", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemQueryPageSize(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, size, pagesize); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemQueryPageSizePrologue( hContext, hDevice, size, pagesize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemQueryPageSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemQueryPageSize(result, hContext, hDevice, size, pagesize); } @@ -6548,17 +10791,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemQueryPageSizePrologue( hContext, hDevice, size, pagesize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemQueryPageSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemQueryPageSize(result, hContext, hDevice, size, pagesize); } auto driver_result = pfnQueryPageSize( hContext, hDevice, size, pagesize ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemQueryPageSizeEpilogue( hContext, hDevice, size, pagesize ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemQueryPageSize", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemQueryPageSize(result, hContext, hDevice, size, pagesize); } - return logAndPropagateResult("zeVirtualMemQueryPageSize", driver_result); + return logAndPropagateResult_zeVirtualMemQueryPageSize(driver_result, hContext, hDevice, size, pagesize); } /////////////////////////////////////////////////////////////////////////////// @@ -6577,12 +10820,12 @@ namespace validation_layer auto pfnCreate = context.zeDdiTable.PhysicalMem.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zePhysicalMemCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zePhysicalMemCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, phPhysicalMemory); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zePhysicalMemCreatePrologue( hContext, hDevice, desc, phPhysicalMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemCreate(result, hContext, hDevice, desc, phPhysicalMemory); } @@ -6593,14 +10836,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zePhysicalMemCreatePrologue( hContext, hDevice, desc, phPhysicalMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemCreate(result, hContext, hDevice, desc, phPhysicalMemory); } auto driver_result = pfnCreate( hContext, hDevice, desc, phPhysicalMemory ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zePhysicalMemCreateEpilogue( hContext, hDevice, desc, phPhysicalMemory ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemCreate(result, hContext, hDevice, desc, phPhysicalMemory); } @@ -6612,7 +10855,7 @@ namespace validation_layer } } - return logAndPropagateResult("zePhysicalMemCreate", driver_result); + return logAndPropagateResult_zePhysicalMemCreate(driver_result, hContext, hDevice, desc, phPhysicalMemory); } /////////////////////////////////////////////////////////////////////////////// @@ -6628,12 +10871,12 @@ namespace validation_layer auto pfnDestroy = context.zeDdiTable.PhysicalMem.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zePhysicalMemDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zePhysicalMemDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hPhysicalMemory); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zePhysicalMemDestroyPrologue( hContext, hPhysicalMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemDestroy(result, hContext, hPhysicalMemory); } @@ -6644,17 +10887,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zePhysicalMemDestroyPrologue( hContext, hPhysicalMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemDestroy(result, hContext, hPhysicalMemory); } auto driver_result = pfnDestroy( hContext, hPhysicalMemory ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zePhysicalMemDestroyEpilogue( hContext, hPhysicalMemory ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zePhysicalMemDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zePhysicalMemDestroy(result, hContext, hPhysicalMemory); } - return logAndPropagateResult("zePhysicalMemDestroy", driver_result); + return logAndPropagateResult_zePhysicalMemDestroy(driver_result, hContext, hPhysicalMemory); } /////////////////////////////////////////////////////////////////////////////// @@ -6677,12 +10920,12 @@ namespace validation_layer auto pfnMap = context.zeDdiTable.VirtualMem.pfnMap; if( nullptr == pfnMap ) - return logAndPropagateResult("zeVirtualMemMap", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemMap(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, size, hPhysicalMemory, offset, access); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemMapPrologue( hContext, ptr, size, hPhysicalMemory, offset, access ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemMap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemMap(result, hContext, ptr, size, hPhysicalMemory, offset, access); } @@ -6693,17 +10936,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemMapPrologue( hContext, ptr, size, hPhysicalMemory, offset, access ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemMap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemMap(result, hContext, ptr, size, hPhysicalMemory, offset, access); } auto driver_result = pfnMap( hContext, ptr, size, hPhysicalMemory, offset, access ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemMapEpilogue( hContext, ptr, size, hPhysicalMemory, offset, access ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemMap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemMap(result, hContext, ptr, size, hPhysicalMemory, offset, access); } - return logAndPropagateResult("zeVirtualMemMap", driver_result); + return logAndPropagateResult_zeVirtualMemMap(driver_result, hContext, ptr, size, hPhysicalMemory, offset, access); } /////////////////////////////////////////////////////////////////////////////// @@ -6720,12 +10963,12 @@ namespace validation_layer auto pfnUnmap = context.zeDdiTable.VirtualMem.pfnUnmap; if( nullptr == pfnUnmap ) - return logAndPropagateResult("zeVirtualMemUnmap", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemUnmap(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemUnmapPrologue( hContext, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemUnmap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemUnmap(result, hContext, ptr, size); } @@ -6736,17 +10979,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemUnmapPrologue( hContext, ptr, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemUnmap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemUnmap(result, hContext, ptr, size); } auto driver_result = pfnUnmap( hContext, ptr, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemUnmapEpilogue( hContext, ptr, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemUnmap", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemUnmap(result, hContext, ptr, size); } - return logAndPropagateResult("zeVirtualMemUnmap", driver_result); + return logAndPropagateResult_zeVirtualMemUnmap(driver_result, hContext, ptr, size); } /////////////////////////////////////////////////////////////////////////////// @@ -6765,12 +11008,12 @@ namespace validation_layer auto pfnSetAccessAttribute = context.zeDdiTable.VirtualMem.pfnSetAccessAttribute; if( nullptr == pfnSetAccessAttribute ) - return logAndPropagateResult("zeVirtualMemSetAccessAttribute", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemSetAccessAttribute(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, size, access); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemSetAccessAttributePrologue( hContext, ptr, size, access ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemSetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemSetAccessAttribute(result, hContext, ptr, size, access); } @@ -6781,17 +11024,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemSetAccessAttributePrologue( hContext, ptr, size, access ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemSetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemSetAccessAttribute(result, hContext, ptr, size, access); } auto driver_result = pfnSetAccessAttribute( hContext, ptr, size, access ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemSetAccessAttributeEpilogue( hContext, ptr, size, access ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemSetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemSetAccessAttribute(result, hContext, ptr, size, access); } - return logAndPropagateResult("zeVirtualMemSetAccessAttribute", driver_result); + return logAndPropagateResult_zeVirtualMemSetAccessAttribute(driver_result, hContext, ptr, size, access); } /////////////////////////////////////////////////////////////////////////////// @@ -6811,12 +11054,12 @@ namespace validation_layer auto pfnGetAccessAttribute = context.zeDdiTable.VirtualMem.pfnGetAccessAttribute; if( nullptr == pfnGetAccessAttribute ) - return logAndPropagateResult("zeVirtualMemGetAccessAttribute", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeVirtualMemGetAccessAttribute(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, ptr, size, access, outSize); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemGetAccessAttributePrologue( hContext, ptr, size, access, outSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemGetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemGetAccessAttribute(result, hContext, ptr, size, access, outSize); } @@ -6827,17 +11070,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeVirtualMemGetAccessAttributePrologue( hContext, ptr, size, access, outSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemGetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemGetAccessAttribute(result, hContext, ptr, size, access, outSize); } auto driver_result = pfnGetAccessAttribute( hContext, ptr, size, access, outSize ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeVirtualMemGetAccessAttributeEpilogue( hContext, ptr, size, access, outSize ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeVirtualMemGetAccessAttribute", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeVirtualMemGetAccessAttribute(result, hContext, ptr, size, access, outSize); } - return logAndPropagateResult("zeVirtualMemGetAccessAttribute", driver_result); + return logAndPropagateResult_zeVirtualMemGetAccessAttribute(driver_result, hContext, ptr, size, access, outSize); } /////////////////////////////////////////////////////////////////////////////// @@ -6855,12 +11098,12 @@ namespace validation_layer auto pfnSetGlobalOffsetExp = context.zeDdiTable.KernelExp.pfnSetGlobalOffsetExp; if( nullptr == pfnSetGlobalOffsetExp ) - return logAndPropagateResult("zeKernelSetGlobalOffsetExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSetGlobalOffsetExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, offsetX, offsetY, offsetZ); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetGlobalOffsetExpPrologue( hKernel, offsetX, offsetY, offsetZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGlobalOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGlobalOffsetExp(result, hKernel, offsetX, offsetY, offsetZ); } @@ -6871,17 +11114,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSetGlobalOffsetExpPrologue( hKernel, offsetX, offsetY, offsetZ ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGlobalOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGlobalOffsetExp(result, hKernel, offsetX, offsetY, offsetZ); } auto driver_result = pfnSetGlobalOffsetExp( hKernel, offsetX, offsetY, offsetZ ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSetGlobalOffsetExpEpilogue( hKernel, offsetX, offsetY, offsetZ ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSetGlobalOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSetGlobalOffsetExp(result, hKernel, offsetX, offsetY, offsetZ); } - return logAndPropagateResult("zeKernelSetGlobalOffsetExp", driver_result); + return logAndPropagateResult_zeKernelSetGlobalOffsetExp(driver_result, hKernel, offsetX, offsetY, offsetZ); } /////////////////////////////////////////////////////////////////////////////// @@ -6898,12 +11141,12 @@ namespace validation_layer auto pfnGetBinaryExp = context.zeDdiTable.KernelExp.pfnGetBinaryExp; if( nullptr == pfnGetBinaryExp ) - return logAndPropagateResult("zeKernelGetBinaryExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetBinaryExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pSize, pKernelBinary); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetBinaryExpPrologue( hKernel, pSize, pKernelBinary ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetBinaryExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetBinaryExp(result, hKernel, pSize, pKernelBinary); } @@ -6914,21 +11157,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetBinaryExpPrologue( hKernel, pSize, pKernelBinary ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetBinaryExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetBinaryExp(result, hKernel, pSize, pKernelBinary); } auto driver_result = pfnGetBinaryExp( hKernel, pSize, pKernelBinary ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetBinaryExpEpilogue( hKernel, pSize, pKernelBinary ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetBinaryExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetBinaryExp(result, hKernel, pSize, pKernelBinary); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeKernelGetBinaryExp", driver_result); + return logAndPropagateResult_zeKernelGetBinaryExp(driver_result, hKernel, pSize, pKernelBinary); } /////////////////////////////////////////////////////////////////////////////// @@ -6945,12 +11188,12 @@ namespace validation_layer auto pfnImportExternalSemaphoreExt = context.zeDdiTable.Device.pfnImportExternalSemaphoreExt; if( nullptr == pfnImportExternalSemaphoreExt ) - return logAndPropagateResult("zeDeviceImportExternalSemaphoreExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceImportExternalSemaphoreExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, desc, phSemaphore); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceImportExternalSemaphoreExtPrologue( hDevice, desc, phSemaphore ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceImportExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceImportExternalSemaphoreExt(result, hDevice, desc, phSemaphore); } @@ -6961,17 +11204,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceImportExternalSemaphoreExtPrologue( hDevice, desc, phSemaphore ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceImportExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceImportExternalSemaphoreExt(result, hDevice, desc, phSemaphore); } auto driver_result = pfnImportExternalSemaphoreExt( hDevice, desc, phSemaphore ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceImportExternalSemaphoreExtEpilogue( hDevice, desc, phSemaphore ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceImportExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceImportExternalSemaphoreExt(result, hDevice, desc, phSemaphore); } - return logAndPropagateResult("zeDeviceImportExternalSemaphoreExt", driver_result); + return logAndPropagateResult_zeDeviceImportExternalSemaphoreExt(driver_result, hDevice, desc, phSemaphore); } /////////////////////////////////////////////////////////////////////////////// @@ -6986,12 +11229,12 @@ namespace validation_layer auto pfnReleaseExternalSemaphoreExt = context.zeDdiTable.Device.pfnReleaseExternalSemaphoreExt; if( nullptr == pfnReleaseExternalSemaphoreExt ) - return logAndPropagateResult("zeDeviceReleaseExternalSemaphoreExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hSemaphore); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceReleaseExternalSemaphoreExtPrologue( hSemaphore ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReleaseExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt(result, hSemaphore); } @@ -7002,17 +11245,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceReleaseExternalSemaphoreExtPrologue( hSemaphore ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReleaseExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt(result, hSemaphore); } auto driver_result = pfnReleaseExternalSemaphoreExt( hSemaphore ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceReleaseExternalSemaphoreExtEpilogue( hSemaphore ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReleaseExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt(result, hSemaphore); } - return logAndPropagateResult("zeDeviceReleaseExternalSemaphoreExt", driver_result); + return logAndPropagateResult_zeDeviceReleaseExternalSemaphoreExt(driver_result, hSemaphore); } /////////////////////////////////////////////////////////////////////////////// @@ -7036,12 +11279,12 @@ namespace validation_layer auto pfnAppendSignalExternalSemaphoreExt = context.zeDdiTable.CommandList.pfnAppendSignalExternalSemaphoreExt; if( nullptr == pfnAppendSignalExternalSemaphoreExt ) - return logAndPropagateResult("zeCommandListAppendSignalExternalSemaphoreExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendSignalExternalSemaphoreExtPrologue( hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -7052,17 +11295,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendSignalExternalSemaphoreExtPrologue( hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendSignalExternalSemaphoreExt( hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendSignalExternalSemaphoreExtEpilogue( hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendSignalExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendSignalExternalSemaphoreExt", driver_result); + return logAndPropagateResult_zeCommandListAppendSignalExternalSemaphoreExt(driver_result, hCommandList, numSemaphores, phSemaphores, signalParams, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -7086,12 +11329,12 @@ namespace validation_layer auto pfnAppendWaitExternalSemaphoreExt = context.zeDdiTable.CommandList.pfnAppendWaitExternalSemaphoreExt; if( nullptr == pfnAppendWaitExternalSemaphoreExt ) - return logAndPropagateResult("zeCommandListAppendWaitExternalSemaphoreExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWaitExternalSemaphoreExtPrologue( hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -7102,17 +11345,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendWaitExternalSemaphoreExtPrologue( hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendWaitExternalSemaphoreExt( hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendWaitExternalSemaphoreExtEpilogue( hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendWaitExternalSemaphoreExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt(result, hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendWaitExternalSemaphoreExt", driver_result); + return logAndPropagateResult_zeCommandListAppendWaitExternalSemaphoreExt(driver_result, hCommandList, numSemaphores, phSemaphores, waitParams, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -7129,12 +11372,12 @@ namespace validation_layer auto pfnCreateExt = context.zeDdiTable.RTASBuilder.pfnCreateExt; if( nullptr == pfnCreateExt ) - return logAndPropagateResult("zeRTASBuilderCreateExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderCreateExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pDescriptor, phBuilder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCreateExtPrologue( hDriver, pDescriptor, phBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExt(result, hDriver, pDescriptor, phBuilder); } @@ -7145,14 +11388,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderCreateExtPrologue( hDriver, pDescriptor, phBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExt(result, hDriver, pDescriptor, phBuilder); } auto driver_result = pfnCreateExt( hDriver, pDescriptor, phBuilder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCreateExtEpilogue( hDriver, pDescriptor, phBuilder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExt(result, hDriver, pDescriptor, phBuilder); } @@ -7164,7 +11407,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeRTASBuilderCreateExt", driver_result); + return logAndPropagateResult_zeRTASBuilderCreateExt(driver_result, hDriver, pDescriptor, phBuilder); } /////////////////////////////////////////////////////////////////////////////// @@ -7181,12 +11424,12 @@ namespace validation_layer auto pfnGetBuildPropertiesExt = context.zeDdiTable.RTASBuilder.pfnGetBuildPropertiesExt; if( nullptr == pfnGetBuildPropertiesExt ) - return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder, pBuildOpDescriptor, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderGetBuildPropertiesExtPrologue( hBuilder, pBuildOpDescriptor, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt(result, hBuilder, pBuildOpDescriptor, pProperties); } @@ -7197,17 +11440,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderGetBuildPropertiesExtPrologue( hBuilder, pBuildOpDescriptor, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt(result, hBuilder, pBuildOpDescriptor, pProperties); } auto driver_result = pfnGetBuildPropertiesExt( hBuilder, pBuildOpDescriptor, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderGetBuildPropertiesExtEpilogue( hBuilder, pBuildOpDescriptor, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt(result, hBuilder, pBuildOpDescriptor, pProperties); } - return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExt", driver_result); + return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExt(driver_result, hBuilder, pBuildOpDescriptor, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -7224,12 +11467,12 @@ namespace validation_layer auto pfnRTASFormatCompatibilityCheckExt = context.zeDdiTable.Driver.pfnRTASFormatCompatibilityCheckExt; if( nullptr == pfnRTASFormatCompatibilityCheckExt ) - return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, rtasFormatA, rtasFormatB); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverRTASFormatCompatibilityCheckExtPrologue( hDriver, rtasFormatA, rtasFormatB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt(result, hDriver, rtasFormatA, rtasFormatB); } @@ -7240,17 +11483,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverRTASFormatCompatibilityCheckExtPrologue( hDriver, rtasFormatA, rtasFormatB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt(result, hDriver, rtasFormatA, rtasFormatB); } auto driver_result = pfnRTASFormatCompatibilityCheckExt( hDriver, rtasFormatA, rtasFormatB ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverRTASFormatCompatibilityCheckExtEpilogue( hDriver, rtasFormatA, rtasFormatB ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt(result, hDriver, rtasFormatA, rtasFormatB); } - return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExt", driver_result); + return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExt(driver_result, hDriver, rtasFormatA, rtasFormatB); } /////////////////////////////////////////////////////////////////////////////// @@ -7277,12 +11520,12 @@ namespace validation_layer auto pfnBuildExt = context.zeDdiTable.RTASBuilder.pfnBuildExt; if( nullptr == pfnBuildExt ) - return logAndPropagateResult("zeRTASBuilderBuildExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderBuildExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderBuildExtPrologue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExt(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } @@ -7293,17 +11536,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderBuildExtPrologue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExt(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } auto driver_result = pfnBuildExt( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderBuildExtEpilogue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExt(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } - return logAndPropagateResult("zeRTASBuilderBuildExt", driver_result); + return logAndPropagateResult_zeRTASBuilderBuildExt(driver_result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } /////////////////////////////////////////////////////////////////////////////// @@ -7328,12 +11571,12 @@ namespace validation_layer auto pfnCommandListAppendCopyExt = context.zeDdiTable.RTASBuilder.pfnCommandListAppendCopyExt; if( nullptr == pfnCommandListAppendCopyExt ) - return logAndPropagateResult("zeRTASBuilderCommandListAppendCopyExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCommandListAppendCopyExtPrologue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCommandListAppendCopyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -7344,17 +11587,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderCommandListAppendCopyExtPrologue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCommandListAppendCopyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnCommandListAppendCopyExt( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCommandListAppendCopyExtEpilogue( hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCommandListAppendCopyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt(result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeRTASBuilderCommandListAppendCopyExt", driver_result); + return logAndPropagateResult_zeRTASBuilderCommandListAppendCopyExt(driver_result, hCommandList, dstptr, srcptr, size, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -7369,12 +11612,12 @@ namespace validation_layer auto pfnDestroyExt = context.zeDdiTable.RTASBuilder.pfnDestroyExt; if( nullptr == pfnDestroyExt ) - return logAndPropagateResult("zeRTASBuilderDestroyExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderDestroyExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderDestroyExtPrologue( hBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExt(result, hBuilder); } @@ -7385,17 +11628,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderDestroyExtPrologue( hBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExt(result, hBuilder); } auto driver_result = pfnDestroyExt( hBuilder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderDestroyExtEpilogue( hBuilder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExt(result, hBuilder); } - return logAndPropagateResult("zeRTASBuilderDestroyExt", driver_result); + return logAndPropagateResult_zeRTASBuilderDestroyExt(driver_result, hBuilder); } /////////////////////////////////////////////////////////////////////////////// @@ -7411,12 +11654,12 @@ namespace validation_layer auto pfnCreateExt = context.zeDdiTable.RTASParallelOperation.pfnCreateExt; if( nullptr == pfnCreateExt ) - return logAndPropagateResult("zeRTASParallelOperationCreateExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationCreateExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, phParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationCreateExtPrologue( hDriver, phParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExt(result, hDriver, phParallelOperation); } @@ -7427,14 +11670,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationCreateExtPrologue( hDriver, phParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExt(result, hDriver, phParallelOperation); } auto driver_result = pfnCreateExt( hDriver, phParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationCreateExtEpilogue( hDriver, phParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExt(result, hDriver, phParallelOperation); } @@ -7446,7 +11689,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeRTASParallelOperationCreateExt", driver_result); + return logAndPropagateResult_zeRTASParallelOperationCreateExt(driver_result, hDriver, phParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -7462,12 +11705,12 @@ namespace validation_layer auto pfnGetPropertiesExt = context.zeDdiTable.RTASParallelOperation.pfnGetPropertiesExt; if( nullptr == pfnGetPropertiesExt ) - return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationGetPropertiesExtPrologue( hParallelOperation, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt(result, hParallelOperation, pProperties); } @@ -7478,17 +11721,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationGetPropertiesExtPrologue( hParallelOperation, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt(result, hParallelOperation, pProperties); } auto driver_result = pfnGetPropertiesExt( hParallelOperation, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationGetPropertiesExtEpilogue( hParallelOperation, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt(result, hParallelOperation, pProperties); } - return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExt", driver_result); + return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExt(driver_result, hParallelOperation, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -7503,12 +11746,12 @@ namespace validation_layer auto pfnJoinExt = context.zeDdiTable.RTASParallelOperation.pfnJoinExt; if( nullptr == pfnJoinExt ) - return logAndPropagateResult("zeRTASParallelOperationJoinExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationJoinExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationJoinExtPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExt(result, hParallelOperation); } @@ -7519,17 +11762,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationJoinExtPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExt(result, hParallelOperation); } auto driver_result = pfnJoinExt( hParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationJoinExtEpilogue( hParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExt(result, hParallelOperation); } - return logAndPropagateResult("zeRTASParallelOperationJoinExt", driver_result); + return logAndPropagateResult_zeRTASParallelOperationJoinExt(driver_result, hParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -7544,12 +11787,12 @@ namespace validation_layer auto pfnDestroyExt = context.zeDdiTable.RTASParallelOperation.pfnDestroyExt; if( nullptr == pfnDestroyExt ) - return logAndPropagateResult("zeRTASParallelOperationDestroyExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationDestroyExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationDestroyExtPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExt(result, hParallelOperation); } @@ -7560,17 +11803,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationDestroyExtPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExt(result, hParallelOperation); } auto driver_result = pfnDestroyExt( hParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationDestroyExtEpilogue( hParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExt(result, hParallelOperation); } - return logAndPropagateResult("zeRTASParallelOperationDestroyExt", driver_result); + return logAndPropagateResult_zeRTASParallelOperationDestroyExt(driver_result, hParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -7594,12 +11837,12 @@ namespace validation_layer auto pfnGetVectorWidthPropertiesExt = context.zeDdiTable.Device.pfnGetVectorWidthPropertiesExt; if( nullptr == pfnGetVectorWidthPropertiesExt ) - return logAndPropagateResult("zeDeviceGetVectorWidthPropertiesExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pVectorWidthProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetVectorWidthPropertiesExtPrologue( hDevice, pCount, pVectorWidthProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetVectorWidthPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt(result, hDevice, pCount, pVectorWidthProperties); } @@ -7610,17 +11853,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetVectorWidthPropertiesExtPrologue( hDevice, pCount, pVectorWidthProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetVectorWidthPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt(result, hDevice, pCount, pVectorWidthProperties); } auto driver_result = pfnGetVectorWidthPropertiesExt( hDevice, pCount, pVectorWidthProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetVectorWidthPropertiesExtEpilogue( hDevice, pCount, pVectorWidthProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetVectorWidthPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt(result, hDevice, pCount, pVectorWidthProperties); } - return logAndPropagateResult("zeDeviceGetVectorWidthPropertiesExt", driver_result); + return logAndPropagateResult_zeDeviceGetVectorWidthPropertiesExt(driver_result, hDevice, pCount, pVectorWidthProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -7645,12 +11888,12 @@ namespace validation_layer auto pfnGetAllocationPropertiesExp = context.zeDdiTable.KernelExp.pfnGetAllocationPropertiesExp; if( nullptr == pfnGetAllocationPropertiesExp ) - return logAndPropagateResult("zeKernelGetAllocationPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelGetAllocationPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pCount, pAllocationProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetAllocationPropertiesExpPrologue( hKernel, pCount, pAllocationProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetAllocationPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetAllocationPropertiesExp(result, hKernel, pCount, pAllocationProperties); } @@ -7661,21 +11904,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelGetAllocationPropertiesExpPrologue( hKernel, pCount, pAllocationProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetAllocationPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetAllocationPropertiesExp(result, hKernel, pCount, pAllocationProperties); } auto driver_result = pfnGetAllocationPropertiesExp( hKernel, pCount, pAllocationProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelGetAllocationPropertiesExpEpilogue( hKernel, pCount, pAllocationProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelGetAllocationPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelGetAllocationPropertiesExp(result, hKernel, pCount, pAllocationProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeKernelGetAllocationPropertiesExp", driver_result); + return logAndPropagateResult_zeKernelGetAllocationPropertiesExp(driver_result, hKernel, pCount, pAllocationProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -7695,12 +11938,12 @@ namespace validation_layer auto pfnReserveCacheExt = context.zeDdiTable.Device.pfnReserveCacheExt; if( nullptr == pfnReserveCacheExt ) - return logAndPropagateResult("zeDeviceReserveCacheExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceReserveCacheExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, cacheLevel, cacheReservationSize); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceReserveCacheExtPrologue( hDevice, cacheLevel, cacheReservationSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReserveCacheExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReserveCacheExt(result, hDevice, cacheLevel, cacheReservationSize); } @@ -7711,17 +11954,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceReserveCacheExtPrologue( hDevice, cacheLevel, cacheReservationSize ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReserveCacheExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReserveCacheExt(result, hDevice, cacheLevel, cacheReservationSize); } auto driver_result = pfnReserveCacheExt( hDevice, cacheLevel, cacheReservationSize ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceReserveCacheExtEpilogue( hDevice, cacheLevel, cacheReservationSize ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceReserveCacheExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceReserveCacheExt(result, hDevice, cacheLevel, cacheReservationSize); } - return logAndPropagateResult("zeDeviceReserveCacheExt", driver_result); + return logAndPropagateResult_zeDeviceReserveCacheExt(driver_result, hDevice, cacheLevel, cacheReservationSize); } /////////////////////////////////////////////////////////////////////////////// @@ -7739,12 +11982,12 @@ namespace validation_layer auto pfnSetCacheAdviceExt = context.zeDdiTable.Device.pfnSetCacheAdviceExt; if( nullptr == pfnSetCacheAdviceExt ) - return logAndPropagateResult("zeDeviceSetCacheAdviceExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceSetCacheAdviceExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, ptr, regionSize, cacheRegion); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceSetCacheAdviceExtPrologue( hDevice, ptr, regionSize, cacheRegion ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSetCacheAdviceExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSetCacheAdviceExt(result, hDevice, ptr, regionSize, cacheRegion); } @@ -7755,17 +11998,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceSetCacheAdviceExtPrologue( hDevice, ptr, regionSize, cacheRegion ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSetCacheAdviceExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSetCacheAdviceExt(result, hDevice, ptr, regionSize, cacheRegion); } auto driver_result = pfnSetCacheAdviceExt( hDevice, ptr, regionSize, cacheRegion ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceSetCacheAdviceExtEpilogue( hDevice, ptr, regionSize, cacheRegion ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceSetCacheAdviceExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceSetCacheAdviceExt(result, hDevice, ptr, regionSize, cacheRegion); } - return logAndPropagateResult("zeDeviceSetCacheAdviceExt", driver_result); + return logAndPropagateResult_zeDeviceSetCacheAdviceExt(driver_result, hDevice, ptr, regionSize, cacheRegion); } /////////////////////////////////////////////////////////////////////////////// @@ -7789,12 +12032,12 @@ namespace validation_layer auto pfnQueryTimestampsExp = context.zeDdiTable.EventExp.pfnQueryTimestampsExp; if( nullptr == pfnQueryTimestampsExp ) - return logAndPropagateResult("zeEventQueryTimestampsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventQueryTimestampsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, hDevice, pCount, pTimestamps); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryTimestampsExpPrologue( hEvent, hDevice, pCount, pTimestamps ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryTimestampsExp(result, hEvent, hDevice, pCount, pTimestamps); } @@ -7805,17 +12048,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventQueryTimestampsExpPrologue( hEvent, hDevice, pCount, pTimestamps ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryTimestampsExp(result, hEvent, hDevice, pCount, pTimestamps); } auto driver_result = pfnQueryTimestampsExp( hEvent, hDevice, pCount, pTimestamps ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryTimestampsExpEpilogue( hEvent, hDevice, pCount, pTimestamps ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryTimestampsExp(result, hEvent, hDevice, pCount, pTimestamps); } - return logAndPropagateResult("zeEventQueryTimestampsExp", driver_result); + return logAndPropagateResult_zeEventQueryTimestampsExp(driver_result, hEvent, hDevice, pCount, pTimestamps); } /////////////////////////////////////////////////////////////////////////////// @@ -7831,12 +12074,12 @@ namespace validation_layer auto pfnGetMemoryPropertiesExp = context.zeDdiTable.ImageExp.pfnGetMemoryPropertiesExp; if( nullptr == pfnGetMemoryPropertiesExp ) - return logAndPropagateResult("zeImageGetMemoryPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageGetMemoryPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hImage, pMemoryProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetMemoryPropertiesExpPrologue( hImage, pMemoryProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetMemoryPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetMemoryPropertiesExp(result, hImage, pMemoryProperties); } @@ -7847,21 +12090,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageGetMemoryPropertiesExpPrologue( hImage, pMemoryProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetMemoryPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetMemoryPropertiesExp(result, hImage, pMemoryProperties); } auto driver_result = pfnGetMemoryPropertiesExp( hImage, pMemoryProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetMemoryPropertiesExpEpilogue( hImage, pMemoryProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetMemoryPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetMemoryPropertiesExp(result, hImage, pMemoryProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeImageGetMemoryPropertiesExp", driver_result); + return logAndPropagateResult_zeImageGetMemoryPropertiesExp(driver_result, hImage, pMemoryProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -7880,12 +12123,12 @@ namespace validation_layer auto pfnViewCreateExt = context.zeDdiTable.Image.pfnViewCreateExt; if( nullptr == pfnViewCreateExt ) - return logAndPropagateResult("zeImageViewCreateExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageViewCreateExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, hImage, phImageView); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageViewCreateExtPrologue( hContext, hDevice, desc, hImage, phImageView ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExt(result, hContext, hDevice, desc, hImage, phImageView); } @@ -7896,14 +12139,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageViewCreateExtPrologue( hContext, hDevice, desc, hImage, phImageView ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExt(result, hContext, hDevice, desc, hImage, phImageView); } auto driver_result = pfnViewCreateExt( hContext, hDevice, desc, hImage, phImageView ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageViewCreateExtEpilogue( hContext, hDevice, desc, hImage, phImageView ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExt(result, hContext, hDevice, desc, hImage, phImageView); } @@ -7915,7 +12158,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeImageViewCreateExt", driver_result); + return logAndPropagateResult_zeImageViewCreateExt(driver_result, hContext, hDevice, desc, hImage, phImageView); } /////////////////////////////////////////////////////////////////////////////// @@ -7934,12 +12177,12 @@ namespace validation_layer auto pfnViewCreateExp = context.zeDdiTable.ImageExp.pfnViewCreateExp; if( nullptr == pfnViewCreateExp ) - return logAndPropagateResult("zeImageViewCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageViewCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, desc, hImage, phImageView); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageViewCreateExpPrologue( hContext, hDevice, desc, hImage, phImageView ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExp(result, hContext, hDevice, desc, hImage, phImageView); } @@ -7950,14 +12193,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageViewCreateExpPrologue( hContext, hDevice, desc, hImage, phImageView ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExp(result, hContext, hDevice, desc, hImage, phImageView); } auto driver_result = pfnViewCreateExp( hContext, hDevice, desc, hImage, phImageView ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageViewCreateExpEpilogue( hContext, hDevice, desc, hImage, phImageView ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageViewCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageViewCreateExp(result, hContext, hDevice, desc, hImage, phImageView); } @@ -7969,7 +12212,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeImageViewCreateExp", driver_result); + return logAndPropagateResult_zeImageViewCreateExp(driver_result, hContext, hDevice, desc, hImage, phImageView); } /////////////////////////////////////////////////////////////////////////////// @@ -7985,12 +12228,12 @@ namespace validation_layer auto pfnSchedulingHintExp = context.zeDdiTable.KernelExp.pfnSchedulingHintExp; if( nullptr == pfnSchedulingHintExp ) - return logAndPropagateResult("zeKernelSchedulingHintExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeKernelSchedulingHintExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pHint); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSchedulingHintExpPrologue( hKernel, pHint ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSchedulingHintExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSchedulingHintExp(result, hKernel, pHint); } @@ -8001,17 +12244,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeKernelSchedulingHintExpPrologue( hKernel, pHint ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSchedulingHintExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSchedulingHintExp(result, hKernel, pHint); } auto driver_result = pfnSchedulingHintExp( hKernel, pHint ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeKernelSchedulingHintExpEpilogue( hKernel, pHint ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeKernelSchedulingHintExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeKernelSchedulingHintExp(result, hKernel, pHint); } - return logAndPropagateResult("zeKernelSchedulingHintExp", driver_result); + return logAndPropagateResult_zeKernelSchedulingHintExp(driver_result, hKernel, pHint); } /////////////////////////////////////////////////////////////////////////////// @@ -8027,12 +12270,12 @@ namespace validation_layer auto pfnPciGetPropertiesExt = context.zeDdiTable.Device.pfnPciGetPropertiesExt; if( nullptr == pfnPciGetPropertiesExt ) - return logAndPropagateResult("zeDevicePciGetPropertiesExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDevicePciGetPropertiesExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pPciProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDevicePciGetPropertiesExtPrologue( hDevice, pPciProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDevicePciGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDevicePciGetPropertiesExt(result, hDevice, pPciProperties); } @@ -8043,17 +12286,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDevicePciGetPropertiesExtPrologue( hDevice, pPciProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDevicePciGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDevicePciGetPropertiesExt(result, hDevice, pPciProperties); } auto driver_result = pfnPciGetPropertiesExt( hDevice, pPciProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDevicePciGetPropertiesExtEpilogue( hDevice, pPciProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDevicePciGetPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDevicePciGetPropertiesExt(result, hDevice, pPciProperties); } - return logAndPropagateResult("zeDevicePciGetPropertiesExt", driver_result); + return logAndPropagateResult_zeDevicePciGetPropertiesExt(driver_result, hDevice, pPciProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -8080,12 +12323,12 @@ namespace validation_layer auto pfnAppendImageCopyToMemoryExt = context.zeDdiTable.CommandList.pfnAppendImageCopyToMemoryExt; if( nullptr == pfnAppendImageCopyToMemoryExt ) - return logAndPropagateResult("zeCommandListAppendImageCopyToMemoryExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyToMemoryExtPrologue( hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt(result, hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -8096,17 +12339,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyToMemoryExtPrologue( hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt(result, hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopyToMemoryExt( hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyToMemoryExtEpilogue( hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyToMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt(result, hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopyToMemoryExt", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopyToMemoryExt(driver_result, hCommandList, dstptr, hSrcImage, pSrcRegion, destRowPitch, destSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -8133,12 +12376,12 @@ namespace validation_layer auto pfnAppendImageCopyFromMemoryExt = context.zeDdiTable.CommandList.pfnAppendImageCopyFromMemoryExt; if( nullptr == pfnAppendImageCopyFromMemoryExt ) - return logAndPropagateResult("zeCommandListAppendImageCopyFromMemoryExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyFromMemoryExtPrologue( hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt(result, hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -8149,17 +12392,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListAppendImageCopyFromMemoryExtPrologue( hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt(result, hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendImageCopyFromMemoryExt( hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListAppendImageCopyFromMemoryExtEpilogue( hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListAppendImageCopyFromMemoryExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt(result, hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListAppendImageCopyFromMemoryExt", driver_result); + return logAndPropagateResult_zeCommandListAppendImageCopyFromMemoryExt(driver_result, hCommandList, hDstImage, srcptr, pDstRegion, srcRowPitch, srcSlicePitch, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -8176,12 +12419,12 @@ namespace validation_layer auto pfnGetAllocPropertiesExt = context.zeDdiTable.Image.pfnGetAllocPropertiesExt; if( nullptr == pfnGetAllocPropertiesExt ) - return logAndPropagateResult("zeImageGetAllocPropertiesExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageGetAllocPropertiesExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hImage, pImageAllocProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetAllocPropertiesExtPrologue( hContext, hImage, pImageAllocProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetAllocPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetAllocPropertiesExt(result, hContext, hImage, pImageAllocProperties); } @@ -8192,17 +12435,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageGetAllocPropertiesExtPrologue( hContext, hImage, pImageAllocProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetAllocPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetAllocPropertiesExt(result, hContext, hImage, pImageAllocProperties); } auto driver_result = pfnGetAllocPropertiesExt( hContext, hImage, pImageAllocProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetAllocPropertiesExtEpilogue( hContext, hImage, pImageAllocProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetAllocPropertiesExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetAllocPropertiesExt(result, hContext, hImage, pImageAllocProperties); } - return logAndPropagateResult("zeImageGetAllocPropertiesExt", driver_result); + return logAndPropagateResult_zeImageGetAllocPropertiesExt(driver_result, hContext, hImage, pImageAllocProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -8222,12 +12465,12 @@ namespace validation_layer auto pfnInspectLinkageExt = context.zeDdiTable.Module.pfnInspectLinkageExt; if( nullptr == pfnInspectLinkageExt ) - return logAndPropagateResult("zeModuleInspectLinkageExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeModuleInspectLinkageExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, pInspectDesc, numModules, phModules, phLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleInspectLinkageExtPrologue( pInspectDesc, numModules, phModules, phLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleInspectLinkageExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleInspectLinkageExt(result, pInspectDesc, numModules, phModules, phLog); } @@ -8238,17 +12481,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeModuleInspectLinkageExtPrologue( pInspectDesc, numModules, phModules, phLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleInspectLinkageExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleInspectLinkageExt(result, pInspectDesc, numModules, phModules, phLog); } auto driver_result = pfnInspectLinkageExt( pInspectDesc, numModules, phModules, phLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeModuleInspectLinkageExtEpilogue( pInspectDesc, numModules, phModules, phLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeModuleInspectLinkageExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeModuleInspectLinkageExt(result, pInspectDesc, numModules, phModules, phLog); } - return logAndPropagateResult("zeModuleInspectLinkageExt", driver_result); + return logAndPropagateResult_zeModuleInspectLinkageExt(driver_result, pInspectDesc, numModules, phModules, phLog); } /////////////////////////////////////////////////////////////////////////////// @@ -8265,12 +12508,12 @@ namespace validation_layer auto pfnFreeExt = context.zeDdiTable.Mem.pfnFreeExt; if( nullptr == pfnFreeExt ) - return logAndPropagateResult("zeMemFreeExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemFreeExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, pMemFreeDesc, ptr); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemFreeExtPrologue( hContext, pMemFreeDesc, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFreeExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFreeExt(result, hContext, pMemFreeDesc, ptr); } @@ -8281,17 +12524,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemFreeExtPrologue( hContext, pMemFreeDesc, ptr ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFreeExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFreeExt(result, hContext, pMemFreeDesc, ptr); } auto driver_result = pfnFreeExt( hContext, pMemFreeDesc, ptr ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemFreeExtEpilogue( hContext, pMemFreeDesc, ptr ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemFreeExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemFreeExt(result, hContext, pMemFreeDesc, ptr); } - return logAndPropagateResult("zeMemFreeExt", driver_result); + return logAndPropagateResult_zeMemFreeExt(driver_result, hContext, pMemFreeDesc, ptr); } /////////////////////////////////////////////////////////////////////////////// @@ -8315,12 +12558,12 @@ namespace validation_layer auto pfnGetExp = context.zeDdiTable.FabricVertexExp.pfnGetExp; if( nullptr == pfnGetExp ) - return logAndPropagateResult("zeFabricVertexGetExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricVertexGetExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pCount, phVertices); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetExpPrologue( hDriver, pCount, phVertices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetExp(result, hDriver, pCount, phVertices); } @@ -8331,14 +12574,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricVertexGetExpPrologue( hDriver, pCount, phVertices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetExp(result, hDriver, pCount, phVertices); } auto driver_result = pfnGetExp( hDriver, pCount, phVertices ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetExpEpilogue( hDriver, pCount, phVertices ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetExp(result, hDriver, pCount, phVertices); } @@ -8351,7 +12594,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeFabricVertexGetExp", driver_result); + return logAndPropagateResult_zeFabricVertexGetExp(driver_result, hDriver, pCount, phVertices); } /////////////////////////////////////////////////////////////////////////////// @@ -8375,12 +12618,12 @@ namespace validation_layer auto pfnGetSubVerticesExp = context.zeDdiTable.FabricVertexExp.pfnGetSubVerticesExp; if( nullptr == pfnGetSubVerticesExp ) - return logAndPropagateResult("zeFabricVertexGetSubVerticesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricVertexGetSubVerticesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVertex, pCount, phSubvertices); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetSubVerticesExpPrologue( hVertex, pCount, phSubvertices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetSubVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetSubVerticesExp(result, hVertex, pCount, phSubvertices); } @@ -8391,14 +12634,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricVertexGetSubVerticesExpPrologue( hVertex, pCount, phSubvertices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetSubVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetSubVerticesExp(result, hVertex, pCount, phSubvertices); } auto driver_result = pfnGetSubVerticesExp( hVertex, pCount, phSubvertices ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetSubVerticesExpEpilogue( hVertex, pCount, phSubvertices ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetSubVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetSubVerticesExp(result, hVertex, pCount, phSubvertices); } @@ -8411,7 +12654,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeFabricVertexGetSubVerticesExp", driver_result); + return logAndPropagateResult_zeFabricVertexGetSubVerticesExp(driver_result, hVertex, pCount, phSubvertices); } /////////////////////////////////////////////////////////////////////////////// @@ -8427,12 +12670,12 @@ namespace validation_layer auto pfnGetPropertiesExp = context.zeDdiTable.FabricVertexExp.pfnGetPropertiesExp; if( nullptr == pfnGetPropertiesExp ) - return logAndPropagateResult("zeFabricVertexGetPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricVertexGetPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVertex, pVertexProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetPropertiesExpPrologue( hVertex, pVertexProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetPropertiesExp(result, hVertex, pVertexProperties); } @@ -8443,21 +12686,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricVertexGetPropertiesExpPrologue( hVertex, pVertexProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetPropertiesExp(result, hVertex, pVertexProperties); } auto driver_result = pfnGetPropertiesExp( hVertex, pVertexProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetPropertiesExpEpilogue( hVertex, pVertexProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetPropertiesExp(result, hVertex, pVertexProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeFabricVertexGetPropertiesExp", driver_result); + return logAndPropagateResult_zeFabricVertexGetPropertiesExp(driver_result, hVertex, pVertexProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -8473,12 +12716,12 @@ namespace validation_layer auto pfnGetDeviceExp = context.zeDdiTable.FabricVertexExp.pfnGetDeviceExp; if( nullptr == pfnGetDeviceExp ) - return logAndPropagateResult("zeFabricVertexGetDeviceExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricVertexGetDeviceExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVertex, phDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetDeviceExpPrologue( hVertex, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetDeviceExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetDeviceExp(result, hVertex, phDevice); } @@ -8489,14 +12732,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricVertexGetDeviceExpPrologue( hVertex, phDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetDeviceExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetDeviceExp(result, hVertex, phDevice); } auto driver_result = pfnGetDeviceExp( hVertex, phDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricVertexGetDeviceExpEpilogue( hVertex, phDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricVertexGetDeviceExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricVertexGetDeviceExp(result, hVertex, phDevice); } @@ -8508,7 +12751,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeFabricVertexGetDeviceExp", driver_result); + return logAndPropagateResult_zeFabricVertexGetDeviceExp(driver_result, hVertex, phDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -8524,12 +12767,12 @@ namespace validation_layer auto pfnGetFabricVertexExp = context.zeDdiTable.DeviceExp.pfnGetFabricVertexExp; if( nullptr == pfnGetFabricVertexExp ) - return logAndPropagateResult("zeDeviceGetFabricVertexExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDeviceGetFabricVertexExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, phVertex); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetFabricVertexExpPrologue( hDevice, phVertex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetFabricVertexExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetFabricVertexExp(result, hDevice, phVertex); } @@ -8540,14 +12783,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDeviceGetFabricVertexExpPrologue( hDevice, phVertex ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetFabricVertexExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetFabricVertexExp(result, hDevice, phVertex); } auto driver_result = pfnGetFabricVertexExp( hDevice, phVertex ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDeviceGetFabricVertexExpEpilogue( hDevice, phVertex ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDeviceGetFabricVertexExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDeviceGetFabricVertexExp(result, hDevice, phVertex); } @@ -8559,7 +12802,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeDeviceGetFabricVertexExp", driver_result); + return logAndPropagateResult_zeDeviceGetFabricVertexExp(driver_result, hDevice, phVertex); } /////////////////////////////////////////////////////////////////////////////// @@ -8584,12 +12827,12 @@ namespace validation_layer auto pfnGetExp = context.zeDdiTable.FabricEdgeExp.pfnGetExp; if( nullptr == pfnGetExp ) - return logAndPropagateResult("zeFabricEdgeGetExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricEdgeGetExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVertexA, hVertexB, pCount, phEdges); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetExpPrologue( hVertexA, hVertexB, pCount, phEdges ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetExp(result, hVertexA, hVertexB, pCount, phEdges); } @@ -8600,14 +12843,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricEdgeGetExpPrologue( hVertexA, hVertexB, pCount, phEdges ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetExp(result, hVertexA, hVertexB, pCount, phEdges); } auto driver_result = pfnGetExp( hVertexA, hVertexB, pCount, phEdges ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetExpEpilogue( hVertexA, hVertexB, pCount, phEdges ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetExp(result, hVertexA, hVertexB, pCount, phEdges); } @@ -8620,7 +12863,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zeFabricEdgeGetExp", driver_result); + return logAndPropagateResult_zeFabricEdgeGetExp(driver_result, hVertexA, hVertexB, pCount, phEdges); } /////////////////////////////////////////////////////////////////////////////// @@ -8637,12 +12880,12 @@ namespace validation_layer auto pfnGetVerticesExp = context.zeDdiTable.FabricEdgeExp.pfnGetVerticesExp; if( nullptr == pfnGetVerticesExp ) - return logAndPropagateResult("zeFabricEdgeGetVerticesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricEdgeGetVerticesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEdge, phVertexA, phVertexB); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetVerticesExpPrologue( hEdge, phVertexA, phVertexB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetVerticesExp(result, hEdge, phVertexA, phVertexB); } @@ -8653,14 +12896,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricEdgeGetVerticesExpPrologue( hEdge, phVertexA, phVertexB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetVerticesExp(result, hEdge, phVertexA, phVertexB); } auto driver_result = pfnGetVerticesExp( hEdge, phVertexA, phVertexB ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetVerticesExpEpilogue( hEdge, phVertexA, phVertexB ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetVerticesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetVerticesExp(result, hEdge, phVertexA, phVertexB); } @@ -8677,7 +12920,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeFabricEdgeGetVerticesExp", driver_result); + return logAndPropagateResult_zeFabricEdgeGetVerticesExp(driver_result, hEdge, phVertexA, phVertexB); } /////////////////////////////////////////////////////////////////////////////// @@ -8693,12 +12936,12 @@ namespace validation_layer auto pfnGetPropertiesExp = context.zeDdiTable.FabricEdgeExp.pfnGetPropertiesExp; if( nullptr == pfnGetPropertiesExp ) - return logAndPropagateResult("zeFabricEdgeGetPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeFabricEdgeGetPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEdge, pEdgeProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetPropertiesExpPrologue( hEdge, pEdgeProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetPropertiesExp(result, hEdge, pEdgeProperties); } @@ -8709,21 +12952,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeFabricEdgeGetPropertiesExpPrologue( hEdge, pEdgeProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetPropertiesExp(result, hEdge, pEdgeProperties); } auto driver_result = pfnGetPropertiesExp( hEdge, pEdgeProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeFabricEdgeGetPropertiesExpEpilogue( hEdge, pEdgeProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeFabricEdgeGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeFabricEdgeGetPropertiesExp(result, hEdge, pEdgeProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeFabricEdgeGetPropertiesExp", driver_result); + return logAndPropagateResult_zeFabricEdgeGetPropertiesExp(driver_result, hEdge, pEdgeProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -8754,12 +12997,12 @@ namespace validation_layer auto pfnQueryKernelTimestampsExt = context.zeDdiTable.Event.pfnQueryKernelTimestampsExt; if( nullptr == pfnQueryKernelTimestampsExt ) - return logAndPropagateResult("zeEventQueryKernelTimestampsExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeEventQueryKernelTimestampsExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEvent, hDevice, pCount, pResults); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryKernelTimestampsExtPrologue( hEvent, hDevice, pCount, pResults ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestampsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestampsExt(result, hEvent, hDevice, pCount, pResults); } @@ -8770,17 +13013,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeEventQueryKernelTimestampsExtPrologue( hEvent, hDevice, pCount, pResults ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestampsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestampsExt(result, hEvent, hDevice, pCount, pResults); } auto driver_result = pfnQueryKernelTimestampsExt( hEvent, hDevice, pCount, pResults ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeEventQueryKernelTimestampsExtEpilogue( hEvent, hDevice, pCount, pResults ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeEventQueryKernelTimestampsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeEventQueryKernelTimestampsExt(result, hEvent, hDevice, pCount, pResults); } - return logAndPropagateResult("zeEventQueryKernelTimestampsExt", driver_result); + return logAndPropagateResult_zeEventQueryKernelTimestampsExt(driver_result, hEvent, hDevice, pCount, pResults); } /////////////////////////////////////////////////////////////////////////////// @@ -8797,12 +13040,12 @@ namespace validation_layer auto pfnCreateExp = context.zeDdiTable.RTASBuilderExp.pfnCreateExp; if( nullptr == pfnCreateExp ) - return logAndPropagateResult("zeRTASBuilderCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pDescriptor, phBuilder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCreateExpPrologue( hDriver, pDescriptor, phBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExp(result, hDriver, pDescriptor, phBuilder); } @@ -8813,14 +13056,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderCreateExpPrologue( hDriver, pDescriptor, phBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExp(result, hDriver, pDescriptor, phBuilder); } auto driver_result = pfnCreateExp( hDriver, pDescriptor, phBuilder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderCreateExpEpilogue( hDriver, pDescriptor, phBuilder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderCreateExp(result, hDriver, pDescriptor, phBuilder); } @@ -8832,7 +13075,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeRTASBuilderCreateExp", driver_result); + return logAndPropagateResult_zeRTASBuilderCreateExp(driver_result, hDriver, pDescriptor, phBuilder); } /////////////////////////////////////////////////////////////////////////////// @@ -8849,12 +13092,12 @@ namespace validation_layer auto pfnGetBuildPropertiesExp = context.zeDdiTable.RTASBuilderExp.pfnGetBuildPropertiesExp; if( nullptr == pfnGetBuildPropertiesExp ) - return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder, pBuildOpDescriptor, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderGetBuildPropertiesExpPrologue( hBuilder, pBuildOpDescriptor, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp(result, hBuilder, pBuildOpDescriptor, pProperties); } @@ -8865,21 +13108,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderGetBuildPropertiesExpPrologue( hBuilder, pBuildOpDescriptor, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp(result, hBuilder, pBuildOpDescriptor, pProperties); } auto driver_result = pfnGetBuildPropertiesExp( hBuilder, pBuildOpDescriptor, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderGetBuildPropertiesExpEpilogue( hBuilder, pBuildOpDescriptor, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp(result, hBuilder, pBuildOpDescriptor, pProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeRTASBuilderGetBuildPropertiesExp", driver_result); + return logAndPropagateResult_zeRTASBuilderGetBuildPropertiesExp(driver_result, hBuilder, pBuildOpDescriptor, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -8896,12 +13139,12 @@ namespace validation_layer auto pfnRTASFormatCompatibilityCheckExp = context.zeDdiTable.DriverExp.pfnRTASFormatCompatibilityCheckExp; if( nullptr == pfnRTASFormatCompatibilityCheckExp ) - return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, rtasFormatA, rtasFormatB); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverRTASFormatCompatibilityCheckExpPrologue( hDriver, rtasFormatA, rtasFormatB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp(result, hDriver, rtasFormatA, rtasFormatB); } @@ -8912,17 +13155,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeDriverRTASFormatCompatibilityCheckExpPrologue( hDriver, rtasFormatA, rtasFormatB ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp(result, hDriver, rtasFormatA, rtasFormatB); } auto driver_result = pfnRTASFormatCompatibilityCheckExp( hDriver, rtasFormatA, rtasFormatB ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeDriverRTASFormatCompatibilityCheckExpEpilogue( hDriver, rtasFormatA, rtasFormatB ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp(result, hDriver, rtasFormatA, rtasFormatB); } - return logAndPropagateResult("zeDriverRTASFormatCompatibilityCheckExp", driver_result); + return logAndPropagateResult_zeDriverRTASFormatCompatibilityCheckExp(driver_result, hDriver, rtasFormatA, rtasFormatB); } /////////////////////////////////////////////////////////////////////////////// @@ -8949,12 +13192,12 @@ namespace validation_layer auto pfnBuildExp = context.zeDdiTable.RTASBuilderExp.pfnBuildExp; if( nullptr == pfnBuildExp ) - return logAndPropagateResult("zeRTASBuilderBuildExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderBuildExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderBuildExpPrologue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExp(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } @@ -8965,17 +13208,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderBuildExpPrologue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExp(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } auto driver_result = pfnBuildExp( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderBuildExpEpilogue( hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderBuildExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderBuildExp(result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } - return logAndPropagateResult("zeRTASBuilderBuildExp", driver_result); + return logAndPropagateResult_zeRTASBuilderBuildExp(driver_result, hBuilder, pBuildOpDescriptor, pScratchBuffer, scratchBufferSizeBytes, pRtasBuffer, rtasBufferSizeBytes, hParallelOperation, pBuildUserPtr, pBounds, pRtasBufferSizeBytes); } /////////////////////////////////////////////////////////////////////////////// @@ -8990,12 +13233,12 @@ namespace validation_layer auto pfnDestroyExp = context.zeDdiTable.RTASBuilderExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zeRTASBuilderDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASBuilderDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hBuilder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderDestroyExpPrologue( hBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExp(result, hBuilder); } @@ -9006,17 +13249,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASBuilderDestroyExpPrologue( hBuilder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExp(result, hBuilder); } auto driver_result = pfnDestroyExp( hBuilder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASBuilderDestroyExpEpilogue( hBuilder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASBuilderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASBuilderDestroyExp(result, hBuilder); } - return logAndPropagateResult("zeRTASBuilderDestroyExp", driver_result); + return logAndPropagateResult_zeRTASBuilderDestroyExp(driver_result, hBuilder); } /////////////////////////////////////////////////////////////////////////////// @@ -9032,12 +13275,12 @@ namespace validation_layer auto pfnCreateExp = context.zeDdiTable.RTASParallelOperationExp.pfnCreateExp; if( nullptr == pfnCreateExp ) - return logAndPropagateResult("zeRTASParallelOperationCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, phParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationCreateExpPrologue( hDriver, phParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExp(result, hDriver, phParallelOperation); } @@ -9048,14 +13291,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationCreateExpPrologue( hDriver, phParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExp(result, hDriver, phParallelOperation); } auto driver_result = pfnCreateExp( hDriver, phParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationCreateExpEpilogue( hDriver, phParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationCreateExp(result, hDriver, phParallelOperation); } @@ -9067,7 +13310,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeRTASParallelOperationCreateExp", driver_result); + return logAndPropagateResult_zeRTASParallelOperationCreateExp(driver_result, hDriver, phParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -9083,12 +13326,12 @@ namespace validation_layer auto pfnGetPropertiesExp = context.zeDdiTable.RTASParallelOperationExp.pfnGetPropertiesExp; if( nullptr == pfnGetPropertiesExp ) - return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationGetPropertiesExpPrologue( hParallelOperation, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp(result, hParallelOperation, pProperties); } @@ -9099,21 +13342,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationGetPropertiesExpPrologue( hParallelOperation, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp(result, hParallelOperation, pProperties); } auto driver_result = pfnGetPropertiesExp( hParallelOperation, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationGetPropertiesExpEpilogue( hParallelOperation, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp(result, hParallelOperation, pProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeRTASParallelOperationGetPropertiesExp", driver_result); + return logAndPropagateResult_zeRTASParallelOperationGetPropertiesExp(driver_result, hParallelOperation, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -9128,12 +13371,12 @@ namespace validation_layer auto pfnJoinExp = context.zeDdiTable.RTASParallelOperationExp.pfnJoinExp; if( nullptr == pfnJoinExp ) - return logAndPropagateResult("zeRTASParallelOperationJoinExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationJoinExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationJoinExpPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExp(result, hParallelOperation); } @@ -9144,17 +13387,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationJoinExpPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExp(result, hParallelOperation); } auto driver_result = pfnJoinExp( hParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationJoinExpEpilogue( hParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationJoinExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationJoinExp(result, hParallelOperation); } - return logAndPropagateResult("zeRTASParallelOperationJoinExp", driver_result); + return logAndPropagateResult_zeRTASParallelOperationJoinExp(driver_result, hParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -9169,12 +13412,12 @@ namespace validation_layer auto pfnDestroyExp = context.zeDdiTable.RTASParallelOperationExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zeRTASParallelOperationDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeRTASParallelOperationDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hParallelOperation); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationDestroyExpPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExp(result, hParallelOperation); } @@ -9185,17 +13428,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeRTASParallelOperationDestroyExpPrologue( hParallelOperation ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExp(result, hParallelOperation); } auto driver_result = pfnDestroyExp( hParallelOperation ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeRTASParallelOperationDestroyExpEpilogue( hParallelOperation ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeRTASParallelOperationDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeRTASParallelOperationDestroyExp(result, hParallelOperation); } - return logAndPropagateResult("zeRTASParallelOperationDestroyExp", driver_result); + return logAndPropagateResult_zeRTASParallelOperationDestroyExp(driver_result, hParallelOperation); } /////////////////////////////////////////////////////////////////////////////// @@ -9215,12 +13458,12 @@ namespace validation_layer auto pfnGetPitchFor2dImage = context.zeDdiTable.Mem.pfnGetPitchFor2dImage; if( nullptr == pfnGetPitchFor2dImage ) - return logAndPropagateResult("zeMemGetPitchFor2dImage", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeMemGetPitchFor2dImage(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetPitchFor2dImagePrologue( hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetPitchFor2dImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetPitchFor2dImage(result, hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch); } @@ -9231,17 +13474,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeMemGetPitchFor2dImagePrologue( hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetPitchFor2dImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetPitchFor2dImage(result, hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch); } auto driver_result = pfnGetPitchFor2dImage( hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeMemGetPitchFor2dImageEpilogue( hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeMemGetPitchFor2dImage", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeMemGetPitchFor2dImage(result, hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch); } - return logAndPropagateResult("zeMemGetPitchFor2dImage", driver_result); + return logAndPropagateResult_zeMemGetPitchFor2dImage(driver_result, hContext, hDevice, imageWidth, imageHeight, elementSizeInBytes, rowPitch); } /////////////////////////////////////////////////////////////////////////////// @@ -9257,12 +13500,12 @@ namespace validation_layer auto pfnGetDeviceOffsetExp = context.zeDdiTable.ImageExp.pfnGetDeviceOffsetExp; if( nullptr == pfnGetDeviceOffsetExp ) - return logAndPropagateResult("zeImageGetDeviceOffsetExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeImageGetDeviceOffsetExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hImage, pDeviceOffset); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetDeviceOffsetExpPrologue( hImage, pDeviceOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetDeviceOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetDeviceOffsetExp(result, hImage, pDeviceOffset); } @@ -9273,21 +13516,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeImageGetDeviceOffsetExpPrologue( hImage, pDeviceOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetDeviceOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetDeviceOffsetExp(result, hImage, pDeviceOffset); } auto driver_result = pfnGetDeviceOffsetExp( hImage, pDeviceOffset ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeImageGetDeviceOffsetExpEpilogue( hImage, pDeviceOffset ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeImageGetDeviceOffsetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeImageGetDeviceOffsetExp(result, hImage, pDeviceOffset); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeImageGetDeviceOffsetExp", driver_result); + return logAndPropagateResult_zeImageGetDeviceOffsetExp(driver_result, hImage, pDeviceOffset); } /////////////////////////////////////////////////////////////////////////////// @@ -9303,12 +13546,12 @@ namespace validation_layer auto pfnCreateCloneExp = context.zeDdiTable.CommandListExp.pfnCreateCloneExp; if( nullptr == pfnCreateCloneExp ) - return logAndPropagateResult("zeCommandListCreateCloneExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListCreateCloneExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, phClonedCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreateCloneExpPrologue( hCommandList, phClonedCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateCloneExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateCloneExp(result, hCommandList, phClonedCommandList); } @@ -9319,14 +13562,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListCreateCloneExpPrologue( hCommandList, phClonedCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateCloneExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateCloneExp(result, hCommandList, phClonedCommandList); } auto driver_result = pfnCreateCloneExp( hCommandList, phClonedCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListCreateCloneExpEpilogue( hCommandList, phClonedCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListCreateCloneExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListCreateCloneExp(result, hCommandList, phClonedCommandList); } @@ -9338,7 +13581,7 @@ namespace validation_layer } } - return logAndPropagateResult("zeCommandListCreateCloneExp", driver_result); + return logAndPropagateResult_zeCommandListCreateCloneExp(driver_result, hCommandList, phClonedCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -9364,12 +13607,12 @@ namespace validation_layer auto pfnImmediateAppendCommandListsExp = context.zeDdiTable.CommandListExp.pfnImmediateAppendCommandListsExp; if( nullptr == pfnImmediateAppendCommandListsExp ) - return logAndPropagateResult("zeCommandListImmediateAppendCommandListsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListImmediateAppendCommandListsExpPrologue( hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateAppendCommandListsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp(result, hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -9380,17 +13623,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListImmediateAppendCommandListsExpPrologue( hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateAppendCommandListsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp(result, hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnImmediateAppendCommandListsExp( hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListImmediateAppendCommandListsExpEpilogue( hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListImmediateAppendCommandListsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp(result, hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListImmediateAppendCommandListsExp", driver_result); + return logAndPropagateResult_zeCommandListImmediateAppendCommandListsExp(driver_result, hCommandListImmediate, numCommandLists, phCommandLists, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -9407,12 +13650,12 @@ namespace validation_layer auto pfnGetNextCommandIdExp = context.zeDdiTable.CommandListExp.pfnGetNextCommandIdExp; if( nullptr == pfnGetNextCommandIdExp ) - return logAndPropagateResult("zeCommandListGetNextCommandIdExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListGetNextCommandIdExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, desc, pCommandId); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetNextCommandIdExpPrologue( hCommandList, desc, pCommandId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdExp(result, hCommandList, desc, pCommandId); } @@ -9423,21 +13666,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListGetNextCommandIdExpPrologue( hCommandList, desc, pCommandId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdExp(result, hCommandList, desc, pCommandId); } auto driver_result = pfnGetNextCommandIdExp( hCommandList, desc, pCommandId ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetNextCommandIdExpEpilogue( hCommandList, desc, pCommandId ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdExp(result, hCommandList, desc, pCommandId); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeCommandListGetNextCommandIdExp", driver_result); + return logAndPropagateResult_zeCommandListGetNextCommandIdExp(driver_result, hCommandList, desc, pCommandId); } /////////////////////////////////////////////////////////////////////////////// @@ -9458,12 +13701,12 @@ namespace validation_layer auto pfnGetNextCommandIdWithKernelsExp = context.zeDdiTable.CommandListExp.pfnGetNextCommandIdWithKernelsExp; if( nullptr == pfnGetNextCommandIdWithKernelsExp ) - return logAndPropagateResult("zeCommandListGetNextCommandIdWithKernelsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, desc, numKernels, phKernels, pCommandId); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetNextCommandIdWithKernelsExpPrologue( hCommandList, desc, numKernels, phKernels, pCommandId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdWithKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp(result, hCommandList, desc, numKernels, phKernels, pCommandId); } @@ -9474,21 +13717,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListGetNextCommandIdWithKernelsExpPrologue( hCommandList, desc, numKernels, phKernels, pCommandId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdWithKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp(result, hCommandList, desc, numKernels, phKernels, pCommandId); } auto driver_result = pfnGetNextCommandIdWithKernelsExp( hCommandList, desc, numKernels, phKernels, pCommandId ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListGetNextCommandIdWithKernelsExpEpilogue( hCommandList, desc, numKernels, phKernels, pCommandId ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListGetNextCommandIdWithKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp(result, hCommandList, desc, numKernels, phKernels, pCommandId); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zeCommandListGetNextCommandIdWithKernelsExp", driver_result); + return logAndPropagateResult_zeCommandListGetNextCommandIdWithKernelsExp(driver_result, hCommandList, desc, numKernels, phKernels, pCommandId); } /////////////////////////////////////////////////////////////////////////////// @@ -9505,12 +13748,12 @@ namespace validation_layer auto pfnUpdateMutableCommandsExp = context.zeDdiTable.CommandListExp.pfnUpdateMutableCommandsExp; if( nullptr == pfnUpdateMutableCommandsExp ) - return logAndPropagateResult("zeCommandListUpdateMutableCommandsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListUpdateMutableCommandsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, desc); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandsExpPrologue( hCommandList, desc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandsExp(result, hCommandList, desc); } @@ -9521,17 +13764,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListUpdateMutableCommandsExpPrologue( hCommandList, desc ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandsExp(result, hCommandList, desc); } auto driver_result = pfnUpdateMutableCommandsExp( hCommandList, desc ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandsExpEpilogue( hCommandList, desc ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandsExp(result, hCommandList, desc); } - return logAndPropagateResult("zeCommandListUpdateMutableCommandsExp", driver_result); + return logAndPropagateResult_zeCommandListUpdateMutableCommandsExp(driver_result, hCommandList, desc); } /////////////////////////////////////////////////////////////////////////////// @@ -9548,12 +13791,12 @@ namespace validation_layer auto pfnUpdateMutableCommandSignalEventExp = context.zeDdiTable.CommandListExp.pfnUpdateMutableCommandSignalEventExp; if( nullptr == pfnUpdateMutableCommandSignalEventExp ) - return logAndPropagateResult("zeCommandListUpdateMutableCommandSignalEventExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, commandId, hSignalEvent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandSignalEventExpPrologue( hCommandList, commandId, hSignalEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandSignalEventExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp(result, hCommandList, commandId, hSignalEvent); } @@ -9564,17 +13807,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListUpdateMutableCommandSignalEventExpPrologue( hCommandList, commandId, hSignalEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandSignalEventExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp(result, hCommandList, commandId, hSignalEvent); } auto driver_result = pfnUpdateMutableCommandSignalEventExp( hCommandList, commandId, hSignalEvent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandSignalEventExpEpilogue( hCommandList, commandId, hSignalEvent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandSignalEventExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp(result, hCommandList, commandId, hSignalEvent); } - return logAndPropagateResult("zeCommandListUpdateMutableCommandSignalEventExp", driver_result); + return logAndPropagateResult_zeCommandListUpdateMutableCommandSignalEventExp(driver_result, hCommandList, commandId, hSignalEvent); } /////////////////////////////////////////////////////////////////////////////// @@ -9593,12 +13836,12 @@ namespace validation_layer auto pfnUpdateMutableCommandWaitEventsExp = context.zeDdiTable.CommandListExp.pfnUpdateMutableCommandWaitEventsExp; if( nullptr == pfnUpdateMutableCommandWaitEventsExp ) - return logAndPropagateResult("zeCommandListUpdateMutableCommandWaitEventsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, commandId, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandWaitEventsExpPrologue( hCommandList, commandId, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandWaitEventsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp(result, hCommandList, commandId, numWaitEvents, phWaitEvents); } @@ -9609,17 +13852,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListUpdateMutableCommandWaitEventsExpPrologue( hCommandList, commandId, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandWaitEventsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp(result, hCommandList, commandId, numWaitEvents, phWaitEvents); } auto driver_result = pfnUpdateMutableCommandWaitEventsExp( hCommandList, commandId, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandWaitEventsExpEpilogue( hCommandList, commandId, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandWaitEventsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp(result, hCommandList, commandId, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zeCommandListUpdateMutableCommandWaitEventsExp", driver_result); + return logAndPropagateResult_zeCommandListUpdateMutableCommandWaitEventsExp(driver_result, hCommandList, commandId, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -9638,12 +13881,12 @@ namespace validation_layer auto pfnUpdateMutableCommandKernelsExp = context.zeDdiTable.CommandListExp.pfnUpdateMutableCommandKernelsExp; if( nullptr == pfnUpdateMutableCommandKernelsExp ) - return logAndPropagateResult("zeCommandListUpdateMutableCommandKernelsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, numKernels, pCommandId, phKernels); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandKernelsExpPrologue( hCommandList, numKernels, pCommandId, phKernels ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp(result, hCommandList, numKernels, pCommandId, phKernels); } @@ -9654,17 +13897,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zeHandleLifetime.zeCommandListUpdateMutableCommandKernelsExpPrologue( hCommandList, numKernels, pCommandId, phKernels ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp(result, hCommandList, numKernels, pCommandId, phKernels); } auto driver_result = pfnUpdateMutableCommandKernelsExp( hCommandList, numKernels, pCommandId, phKernels ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zeCommandListUpdateMutableCommandKernelsExpEpilogue( hCommandList, numKernels, pCommandId, phKernels ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zeCommandListUpdateMutableCommandKernelsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp(result, hCommandList, numKernels, pCommandId, phKernels); } - return logAndPropagateResult("zeCommandListUpdateMutableCommandKernelsExp", driver_result); + return logAndPropagateResult_zeCommandListUpdateMutableCommandKernelsExp(driver_result, hCommandList, numKernels, pCommandId, phKernels); } /////////////////////////////////////////////////////////////////////////////// @@ -9686,7 +13929,7 @@ namespace validation_layer auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zexCounterBasedEventCreate2Prologue( hContext, hDevice, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } if(context.enableThreadingValidation){ @@ -9695,7 +13938,7 @@ namespace validation_layer if(context.enableHandleLifetime){ auto result = context.handleLifetime->zeHandleLifetime.zexCounterBasedEventCreate2Prologue( hContext, hDevice, desc, phEvent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } // This is an experimental function that must be accessed through the extension mechanism @@ -9737,7 +13980,7 @@ namespace validation_layer for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zeValidation->zexCounterBasedEventCreate2Epilogue( hContext, hDevice, desc, phEvent, driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zexCounterBasedEventCreate2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zexCounterBasedEventCreate2(result, hContext, hDevice, desc, phEvent); } if(driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime){ @@ -9746,7 +13989,7 @@ namespace validation_layer // Note: counter-based events may not have a traditional event pool dependency } } - return logAndPropagateResult("zexCounterBasedEventCreate2", driver_result); + return logAndPropagateResult_zexCounterBasedEventCreate2(driver_result, hContext, hDevice, desc, phEvent); } } // namespace validation_layer diff --git a/source/layers/validation/ze_validation_layer.h b/source/layers/validation/ze_validation_layer.h index deb2033d..7cf9c037 100644 --- a/source/layers/validation/ze_validation_layer.h +++ b/source/layers/validation/ze_validation_layer.h @@ -20,6 +20,10 @@ #include "zes_entry_points.h" #include "zer_entry_points.h" #include "logging.h" +#include "ze_to_string.h" +#include "zes_to_string.h" +#include "zet_to_string.h" +#include "zer_to_string.h" #include #include diff --git a/source/layers/validation/zer_valddi.cpp b/source/layers/validation/zer_valddi.cpp index 3bbbea18..a87efc9d 100644 --- a/source/layers/validation/zer_valddi.cpp +++ b/source/layers/validation/zer_valddi.cpp @@ -10,13 +10,63 @@ * */ #include "ze_validation_layer.h" +#include + +// Define a macro for marking potentially unused functions +#if defined(_MSC_VER) + // MSVC doesn't support __attribute__((unused)), just omit the marking + #define VALIDATION_MAYBE_UNUSED +#elif defined(__GNUC__) || defined(__clang__) + // GCC and Clang support __attribute__((unused)) + #define VALIDATION_MAYBE_UNUSED __attribute__((unused)) +#else + #define VALIDATION_MAYBE_UNUSED +#endif namespace validation_layer { - static ze_result_t logAndPropagateResult(const char* fname, ze_result_t result) { - if (result != ZE_RESULT_SUCCESS) { - context.logger->log_trace("Error (" + loader::to_string(result) + ") in " + std::string(fname)); - } + // Generate specific logAndPropagateResult functions for each API function + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zerGetLastErrorDescription( + ze_result_t result, + const char** ppString ///< [in,out] pointer to a null-terminated array of characters describing + ///< cause of error. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zerGetLastErrorDescription("; + oss << "ppString=" << loader::to_string(ppString); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zerTranslateDeviceHandleToIdentifier( + ze_result_t result, + ze_device_handle_t hDevice ///< [in] handle of the device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zerTranslateDeviceHandleToIdentifier("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zerTranslateIdentifierToDeviceHandle( + ze_result_t result, + uint32_t identifier ///< [in] integer identifier of the device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zerTranslateIdentifierToDeviceHandle("; + oss << "identifier=" << loader::to_string(identifier); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zerGetDefaultContext( + ze_result_t result) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + context.logger->log_trace(status + " (" + loader::to_string(result) + ") in zerGetDefaultContext()"); return result; } @@ -33,12 +83,12 @@ namespace validation_layer auto pfnGetLastErrorDescription = context.zerDdiTable.Global.pfnGetLastErrorDescription; if( nullptr == pfnGetLastErrorDescription ) - return logAndPropagateResult("zerGetLastErrorDescription", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zerGetLastErrorDescription(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, ppString); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zerValidation->zerGetLastErrorDescriptionPrologue( ppString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zerGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zerGetLastErrorDescription(result, ppString); } @@ -49,17 +99,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zerHandleLifetime.zerGetLastErrorDescriptionPrologue( ppString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zerGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zerGetLastErrorDescription(result, ppString); } auto driver_result = pfnGetLastErrorDescription( ppString ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zerValidation->zerGetLastErrorDescriptionEpilogue( ppString ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zerGetLastErrorDescription", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zerGetLastErrorDescription(result, ppString); } - return logAndPropagateResult("zerGetLastErrorDescription", driver_result); + return logAndPropagateResult_zerGetLastErrorDescription(driver_result, ppString); } /////////////////////////////////////////////////////////////////////////////// diff --git a/source/layers/validation/zes_valddi.cpp b/source/layers/validation/zes_valddi.cpp index 7f4cf359..5f06ead3 100644 --- a/source/layers/validation/zes_valddi.cpp +++ b/source/layers/validation/zes_valddi.cpp @@ -10,13 +10,2866 @@ * */ #include "ze_validation_layer.h" +#include + +// Define a macro for marking potentially unused functions +#if defined(_MSC_VER) + // MSVC doesn't support __attribute__((unused)), just omit the marking + #define VALIDATION_MAYBE_UNUSED +#elif defined(__GNUC__) || defined(__clang__) + // GCC and Clang support __attribute__((unused)) + #define VALIDATION_MAYBE_UNUSED __attribute__((unused)) +#else + #define VALIDATION_MAYBE_UNUSED +#endif namespace validation_layer { - static ze_result_t logAndPropagateResult(const char* fname, ze_result_t result) { - if (result != ZE_RESULT_SUCCESS) { - context.logger->log_trace("Error (" + loader::to_string(result) + ") in " + std::string(fname)); - } + // Generate specific logAndPropagateResult functions for each API function + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesInit( + ze_result_t result, + zes_init_flags_t flags ///< [in] initialization flags. + ///< currently unused, must be 0 (default). +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesInit("; + oss << "flags=" << loader::to_string(flags); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverGet( + ze_result_t result, + uint32_t* pCount, ///< [in,out] pointer to the number of sysman driver instances. + ///< if count is zero, then the loader shall update the value with the + ///< total number of sysman drivers available. + ///< if count is greater than the number of sysman drivers available, then + ///< the loader shall update the value with the correct number of sysman + ///< drivers available. + zes_driver_handle_t* phDrivers ///< [in,out][optional][range(0, *pCount)] array of sysman driver instance handles. + ///< if count is less than the number of sysman drivers available, then the + ///< loader shall only retrieve that number of sysman drivers. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverGet("; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDrivers=" << loader::to_string(phDrivers); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverGetExtensionProperties( + ze_result_t result, + zes_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint32_t* pCount, ///< [in,out] pointer to the number of extension properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of extension properties available. + ///< if count is greater than the number of extension properties available, + ///< then the driver shall update the value with the correct number of + ///< extension properties available. + zes_driver_extension_properties_t* pExtensionProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< extension properties. + ///< if count is less than the number of extension properties available, + ///< then driver shall only retrieve that number of extension properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverGetExtensionProperties("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pExtensionProperties=" << loader::to_string(pExtensionProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverGetExtensionFunctionAddress( + ze_result_t result, + zes_driver_handle_t hDriver, ///< [in] handle of the driver instance + const char* name, ///< [in] extension function name + void** ppFunctionAddress ///< [out] pointer to function pointer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverGetExtensionFunctionAddress("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "name=" << loader::to_string(name); + oss << ", "; + oss << "ppFunctionAddress=" << loader::to_string(ppFunctionAddress); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGet( + ze_result_t result, + zes_driver_handle_t hDriver, ///< [in] handle of the sysman driver instance + uint32_t* pCount, ///< [in,out] pointer to the number of sysman devices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of sysman devices available. + ///< if count is greater than the number of sysman devices available, then + ///< the driver shall update the value with the correct number of sysman + ///< devices available. + zes_device_handle_t* phDevices ///< [in,out][optional][range(0, *pCount)] array of handle of sysman devices. + ///< if count is less than the number of sysman devices available, then + ///< driver shall only retrieve that number of sysman devices. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGet("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetProperties( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_device_properties_t* pProperties ///< [in,out] Structure that will contain information about the device. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_device_state_t* pState ///< [in,out] Structure that will contain information about the device. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceReset( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle for the device + ze_bool_t force ///< [in] If set to true, all applications that are currently using the + ///< device will be forcibly killed. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceReset("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "force=" << loader::to_string(force); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceResetExt( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle for the device + zes_reset_properties_t* pProperties ///< [in] Device reset properties to apply +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceResetExt("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceProcessesGetState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle for the device + uint32_t* pCount, ///< [in,out] pointer to the number of processes. + ///< if count is zero, then the driver shall update the value with the + ///< total number of processes currently attached to the device. + ///< if count is greater than the number of processes currently attached to + ///< the device, then the driver shall update the value with the correct + ///< number of processes. + zes_process_state_t* pProcesses ///< [in,out][optional][range(0, *pCount)] array of process information. + ///< if count is less than the number of processes currently attached to + ///< the device, then the driver shall only retrieve information about that + ///< number of processes. In this case, the return code will ::ZE_RESULT_ERROR_INVALID_SIZE. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceProcessesGetState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pProcesses=" << loader::to_string(pProcesses); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDevicePciGetProperties( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_pci_properties_t* pProperties ///< [in,out] Will contain the PCI properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDevicePciGetProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDevicePciGetState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_pci_state_t* pState ///< [in,out] Will contain the PCI properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDevicePciGetState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDevicePciGetBars( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of PCI bars. + ///< if count is zero, then the driver shall update the value with the + ///< total number of PCI bars that are setup. + ///< if count is greater than the number of PCI bars that are setup, then + ///< the driver shall update the value with the correct number of PCI bars. + zes_pci_bar_properties_t* pProperties ///< [in,out][optional][range(0, *pCount)] array of information about setup + ///< PCI bars. + ///< if count is less than the number of PCI bars that are setup, then the + ///< driver shall only retrieve information about that number of PCI bars. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDevicePciGetBars("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDevicePciGetStats( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_pci_stats_t* pStats ///< [in,out] Will contain a snapshot of the latest stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDevicePciGetStats("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pStats=" << loader::to_string(pStats); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceSetOverclockWaiver( + ze_result_t result, + zes_device_handle_t hDevice ///< [in] Sysman handle of the device. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceSetOverclockWaiver("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetOverclockDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pOverclockDomains ///< [in,out] Returns the overclock domains that are supported (a bit for + ///< each of enum ::zes_overclock_domain_t). If no bits are set, the device + ///< doesn't support overclocking. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetOverclockDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pOverclockDomains=" << loader::to_string(pOverclockDomains); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetOverclockControls( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_overclock_domain_t domainType, ///< [in] Domain type. + uint32_t* pAvailableControls ///< [in,out] Returns the overclock controls that are supported for the + ///< specified overclock domain (a bit for each of enum + ///< ::zes_overclock_control_t). +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetOverclockControls("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "domainType=" << loader::to_string(domainType); + oss << ", "; + oss << "pAvailableControls=" << loader::to_string(pAvailableControls); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceResetOverclockSettings( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + ze_bool_t onShippedState ///< [in] True will reset to shipped state; false will reset to + ///< manufacturing state +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceResetOverclockSettings("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "onShippedState=" << loader::to_string(onShippedState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceReadOverclockState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_overclock_mode_t* pOverclockMode, ///< [out] One of overclock mode. + ze_bool_t* pWaiverSetting, ///< [out] Waiver setting: 0 = Waiver not set, 1 = waiver has been set. + ze_bool_t* pOverclockState, ///< [out] Current settings 0 =manufacturing state, 1= shipped state).. + zes_pending_action_t* pPendingAction, ///< [out] This enum is returned when the driver attempts to set an + ///< overclock control or reset overclock settings. + ze_bool_t* pPendingReset ///< [out] Pending reset 0 =manufacturing state, 1= shipped state).. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceReadOverclockState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pOverclockMode=" << loader::to_string(pOverclockMode); + oss << ", "; + oss << "pWaiverSetting=" << loader::to_string(pWaiverSetting); + oss << ", "; + oss << "pOverclockState=" << loader::to_string(pOverclockState); + oss << ", "; + oss << "pPendingAction=" << loader::to_string(pPendingAction); + oss << ", "; + oss << "pPendingReset=" << loader::to_string(pPendingReset); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumOverclockDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_overclock_handle_t* phDomainHandle ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumOverclockDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDomainHandle=" << loader::to_string(phDomainHandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetDomainProperties( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_overclock_properties_t* pDomainProperties ///< [in,out] The overclock properties for the specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetDomainProperties("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "pDomainProperties=" << loader::to_string(pDomainProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetDomainVFProperties( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_vf_property_t* pVFProperties ///< [in,out] The VF min,max,step for a specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetDomainVFProperties("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "pVFProperties=" << loader::to_string(pVFProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetDomainControlProperties( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_overclock_control_t DomainControl, ///< [in] Handle for the component. + zes_control_property_t* pControlProperties ///< [in,out] overclock control values. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetDomainControlProperties("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "DomainControl=" << loader::to_string(DomainControl); + oss << ", "; + oss << "pControlProperties=" << loader::to_string(pControlProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetControlCurrentValue( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component. + zes_overclock_control_t DomainControl, ///< [in] Overclock Control. + double* pValue ///< [in,out] Getting overclock control value for the specified control. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetControlCurrentValue("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "DomainControl=" << loader::to_string(DomainControl); + oss << ", "; + oss << "pValue=" << loader::to_string(pValue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetControlPendingValue( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_overclock_control_t DomainControl, ///< [in] Overclock Control. + double* pValue ///< [out] Returns the pending value for a given control. The units and + ///< format of the value depend on the control type. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetControlPendingValue("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "DomainControl=" << loader::to_string(DomainControl); + oss << ", "; + oss << "pValue=" << loader::to_string(pValue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockSetControlUserValue( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_overclock_control_t DomainControl, ///< [in] Domain Control. + double pValue, ///< [in] The new value of the control. The units and format of the value + ///< depend on the control type. + zes_pending_action_t* pPendingAction ///< [out] Pending overclock setting. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockSetControlUserValue("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "DomainControl=" << loader::to_string(DomainControl); + oss << ", "; + oss << "pValue=" << loader::to_string(pValue); + oss << ", "; + oss << "pPendingAction=" << loader::to_string(pPendingAction); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetControlState( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_overclock_control_t DomainControl, ///< [in] Domain Control. + zes_control_state_t* pControlState, ///< [out] Current overclock control state. + zes_pending_action_t* pPendingAction ///< [out] Pending overclock setting. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetControlState("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "DomainControl=" << loader::to_string(DomainControl); + oss << ", "; + oss << "pControlState=" << loader::to_string(pControlState); + oss << ", "; + oss << "pPendingAction=" << loader::to_string(pPendingAction); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockGetVFPointValues( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_vf_type_t VFType, ///< [in] Voltage or Freqency point to read. + zes_vf_array_type_t VFArrayType, ///< [in] User,Default or Live VF array to read from + uint32_t PointIndex, ///< [in] Point index - number between (0, max_num_points - 1). + uint32_t* PointValue ///< [out] Returns the frequency in 1kHz units or voltage in millivolt + ///< units from the custom V-F curve at the specified zero-based index +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockGetVFPointValues("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "VFType=" << loader::to_string(VFType); + oss << ", "; + oss << "VFArrayType=" << loader::to_string(VFArrayType); + oss << ", "; + oss << "PointIndex=" << loader::to_string(PointIndex); + oss << ", "; + oss << "PointValue=" << loader::to_string(PointValue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesOverclockSetVFPointValues( + ze_result_t result, + zes_overclock_handle_t hDomainHandle, ///< [in] Handle for the component domain. + zes_vf_type_t VFType, ///< [in] Voltage or Freqency point to read. + uint32_t PointIndex, ///< [in] Point index - number between (0, max_num_points - 1). + uint32_t PointValue ///< [in] Writes frequency in 1kHz units or voltage in millivolt units to + ///< custom V-F curve at the specified zero-based index +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesOverclockSetVFPointValues("; + oss << "hDomainHandle=" << loader::to_string(hDomainHandle); + oss << ", "; + oss << "VFType=" << loader::to_string(VFType); + oss << ", "; + oss << "PointIndex=" << loader::to_string(PointIndex); + oss << ", "; + oss << "PointValue=" << loader::to_string(PointValue); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_diag_handle_t* phDiagnostics ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumDiagnosticTestSuites("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phDiagnostics=" << loader::to_string(phDiagnostics); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDiagnosticsGetProperties( + ze_result_t result, + zes_diag_handle_t hDiagnostics, ///< [in] Handle for the component. + zes_diag_properties_t* pProperties ///< [in,out] Structure describing the properties of a diagnostics test + ///< suite +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDiagnosticsGetProperties("; + oss << "hDiagnostics=" << loader::to_string(hDiagnostics); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDiagnosticsGetTests( + ze_result_t result, + zes_diag_handle_t hDiagnostics, ///< [in] Handle for the component. + uint32_t* pCount, ///< [in,out] pointer to the number of tests. + ///< if count is zero, then the driver shall update the value with the + ///< total number of tests that are available. + ///< if count is greater than the number of tests that are available, then + ///< the driver shall update the value with the correct number of tests. + zes_diag_test_t* pTests ///< [in,out][optional][range(0, *pCount)] array of information about + ///< individual tests sorted by increasing value of the `index` member of ::zes_diag_test_t. + ///< if count is less than the number of tests that are available, then the + ///< driver shall only retrieve that number of tests. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDiagnosticsGetTests("; + oss << "hDiagnostics=" << loader::to_string(hDiagnostics); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pTests=" << loader::to_string(pTests); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDiagnosticsRunTests( + ze_result_t result, + zes_diag_handle_t hDiagnostics, ///< [in] Handle for the component. + uint32_t startIndex, ///< [in] The index of the first test to run. Set to + ///< ::ZES_DIAG_FIRST_TEST_INDEX to start from the beginning. + uint32_t endIndex, ///< [in] The index of the last test to run. Set to + ///< ::ZES_DIAG_LAST_TEST_INDEX to complete all tests after the start test. + zes_diag_result_t* pResult ///< [in,out] The result of the diagnostics +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDiagnosticsRunTests("; + oss << "hDiagnostics=" << loader::to_string(hDiagnostics); + oss << ", "; + oss << "startIndex=" << loader::to_string(startIndex); + oss << ", "; + oss << "endIndex=" << loader::to_string(endIndex); + oss << ", "; + oss << "pResult=" << loader::to_string(pResult); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEccAvailable( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Handle for the component. + ze_bool_t* pAvailable ///< [out] ECC functionality is available (true)/unavailable (false). +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEccAvailable("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pAvailable=" << loader::to_string(pAvailable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEccConfigurable( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Handle for the component. + ze_bool_t* pConfigurable ///< [out] ECC can be enabled/disabled (true)/enabled/disabled (false). +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEccConfigurable("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pConfigurable=" << loader::to_string(pConfigurable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetEccState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Handle for the component. + zes_device_ecc_properties_t* pState ///< [out] ECC state, pending state, and pending action for state change. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetEccState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceSetEccState( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Handle for the component. + const zes_device_ecc_desc_t* newState, ///< [in] Pointer to desired ECC state. + zes_device_ecc_properties_t* pState ///< [out] ECC state, pending state, and pending action for state change. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceSetEccState("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "newState=" << loader::to_string(newState); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumEngineGroups( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_engine_handle_t* phEngine ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumEngineGroups("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phEngine=" << loader::to_string(phEngine); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesEngineGetProperties( + ze_result_t result, + zes_engine_handle_t hEngine, ///< [in] Handle for the component. + zes_engine_properties_t* pProperties ///< [in,out] The properties for the specified engine group. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesEngineGetProperties("; + oss << "hEngine=" << loader::to_string(hEngine); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesEngineGetActivity( + ze_result_t result, + zes_engine_handle_t hEngine, ///< [in] Handle for the component. + zes_engine_stats_t* pStats ///< [in,out] Will contain a snapshot of the engine group activity + ///< counters. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesEngineGetActivity("; + oss << "hEngine=" << loader::to_string(hEngine); + oss << ", "; + oss << "pStats=" << loader::to_string(pStats); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEventRegister( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] The device handle. + zes_event_type_flags_t events ///< [in] List of events to listen to. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEventRegister("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "events=" << loader::to_string(events); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverEventListen( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint32_t timeout, ///< [in] if non-zero, then indicates the maximum time (in milliseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then will check status and return immediately; + ///< if `UINT32_MAX`, then function will not return until events arrive. + uint32_t count, ///< [in] Number of device handles in phDevices. + zes_device_handle_t* phDevices, ///< [in][range(0, count)] Device handles to listen to for events. Only + ///< devices from the provided driver handle can be specified in this list. + uint32_t* pNumDeviceEvents, ///< [in,out] Will contain the actual number of devices in phDevices that + ///< generated events. If non-zero, check pEvents to determine the devices + ///< and events that were received. + zes_event_type_flags_t* pEvents ///< [in,out] An array that will continue the list of events for each + ///< device listened in phDevices. + ///< This array must be at least as big as count. + ///< For every device handle in phDevices, this will provide the events + ///< that occurred for that device at the same position in this array. If + ///< no event was received for a given device, the corresponding array + ///< entry will be zero. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverEventListen("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ", "; + oss << "count=" << loader::to_string(count); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ", "; + oss << "pNumDeviceEvents=" << loader::to_string(pNumDeviceEvents); + oss << ", "; + oss << "pEvents=" << loader::to_string(pEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverEventListenEx( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + uint64_t timeout, ///< [in] if non-zero, then indicates the maximum time (in milliseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then will check status and return immediately; + ///< if `UINT64_MAX`, then function will not return until events arrive. + uint32_t count, ///< [in] Number of device handles in phDevices. + zes_device_handle_t* phDevices, ///< [in][range(0, count)] Device handles to listen to for events. Only + ///< devices from the provided driver handle can be specified in this list. + uint32_t* pNumDeviceEvents, ///< [in,out] Will contain the actual number of devices in phDevices that + ///< generated events. If non-zero, check pEvents to determine the devices + ///< and events that were received. + zes_event_type_flags_t* pEvents ///< [in,out] An array that will continue the list of events for each + ///< device listened in phDevices. + ///< This array must be at least as big as count. + ///< For every device handle in phDevices, this will provide the events + ///< that occurred for that device at the same position in this array. If + ///< no event was received for a given device, the corresponding array + ///< entry will be zero. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverEventListenEx("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ", "; + oss << "count=" << loader::to_string(count); + oss << ", "; + oss << "phDevices=" << loader::to_string(phDevices); + oss << ", "; + oss << "pNumDeviceEvents=" << loader::to_string(pNumDeviceEvents); + oss << ", "; + oss << "pEvents=" << loader::to_string(pEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumFabricPorts( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_fabric_port_handle_t* phPort ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumFabricPorts("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phPort=" << loader::to_string(phPort); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetProperties( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_port_properties_t* pProperties ///< [in,out] Will contain properties of the Fabric Port. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetProperties("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetLinkType( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_link_type_t* pLinkType ///< [in,out] Will contain details about the link attached to the Fabric + ///< port. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetLinkType("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pLinkType=" << loader::to_string(pLinkType); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetConfig( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_port_config_t* pConfig ///< [in,out] Will contain configuration of the Fabric Port. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetConfig("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortSetConfig( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + const zes_fabric_port_config_t* pConfig ///< [in] Contains new configuration of the Fabric Port. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortSetConfig("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetState( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_port_state_t* pState ///< [in,out] Will contain the current state of the Fabric Port +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetState("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetThroughput( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_port_throughput_t* pThroughput ///< [in,out] Will contain the Fabric port throughput counters. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetThroughput("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pThroughput=" << loader::to_string(pThroughput); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetFabricErrorCounters( + ze_result_t result, + zes_fabric_port_handle_t hPort, ///< [in] Handle for the component. + zes_fabric_port_error_counters_t* pErrors ///< [in,out] Will contain the Fabric port Error counters. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetFabricErrorCounters("; + oss << "hPort=" << loader::to_string(hPort); + oss << ", "; + oss << "pErrors=" << loader::to_string(pErrors); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFabricPortGetMultiPortThroughput( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t numPorts, ///< [in] Number of ports enumerated in function ::zesDeviceEnumFabricPorts + zes_fabric_port_handle_t* phPort, ///< [in][range(0, numPorts)] array of fabric port handles provided by user + ///< to gather throughput values. + zes_fabric_port_throughput_t** pThroughput ///< [out][range(0, numPorts)] array of fabric port throughput counters + ///< from multiple ports of type ::zes_fabric_port_throughput_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFabricPortGetMultiPortThroughput("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "numPorts=" << loader::to_string(numPorts); + oss << ", "; + oss << "phPort=" << loader::to_string(phPort); + oss << ", "; + oss << "pThroughput=" << loader::to_string(pThroughput); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumFans( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_fan_handle_t* phFan ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumFans("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phFan=" << loader::to_string(phFan); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanGetProperties( + ze_result_t result, + zes_fan_handle_t hFan, ///< [in] Handle for the component. + zes_fan_properties_t* pProperties ///< [in,out] Will contain the properties of the fan. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanGetProperties("; + oss << "hFan=" << loader::to_string(hFan); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanGetConfig( + ze_result_t result, + zes_fan_handle_t hFan, ///< [in] Handle for the component. + zes_fan_config_t* pConfig ///< [in,out] Will contain the current configuration of the fan. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanGetConfig("; + oss << "hFan=" << loader::to_string(hFan); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanSetDefaultMode( + ze_result_t result, + zes_fan_handle_t hFan ///< [in] Handle for the component. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanSetDefaultMode("; + oss << "hFan=" << loader::to_string(hFan); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanSetFixedSpeedMode( + ze_result_t result, + zes_fan_handle_t hFan, ///< [in] Handle for the component. + const zes_fan_speed_t* speed ///< [in] The fixed fan speed setting +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanSetFixedSpeedMode("; + oss << "hFan=" << loader::to_string(hFan); + oss << ", "; + oss << "speed=" << loader::to_string(speed); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanSetSpeedTableMode( + ze_result_t result, + zes_fan_handle_t hFan, ///< [in] Handle for the component. + const zes_fan_speed_table_t* speedTable ///< [in] A table containing temperature/speed pairs. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanSetSpeedTableMode("; + oss << "hFan=" << loader::to_string(hFan); + oss << ", "; + oss << "speedTable=" << loader::to_string(speedTable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFanGetState( + ze_result_t result, + zes_fan_handle_t hFan, ///< [in] Handle for the component. + zes_fan_speed_units_t units, ///< [in] The units in which the fan speed should be returned. + int32_t* pSpeed ///< [in,out] Will contain the current speed of the fan in the units + ///< requested. A value of -1 indicates that the fan speed cannot be + ///< measured. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFanGetState("; + oss << "hFan=" << loader::to_string(hFan); + oss << ", "; + oss << "units=" << loader::to_string(units); + oss << ", "; + oss << "pSpeed=" << loader::to_string(pSpeed); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumFirmwares( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_firmware_handle_t* phFirmware ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumFirmwares("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phFirmware=" << loader::to_string(phFirmware); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareGetProperties( + ze_result_t result, + zes_firmware_handle_t hFirmware, ///< [in] Handle for the component. + zes_firmware_properties_t* pProperties ///< [in,out] Pointer to an array that will hold the properties of the + ///< firmware +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareGetProperties("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareFlash( + ze_result_t result, + zes_firmware_handle_t hFirmware, ///< [in] Handle for the component. + void* pImage, ///< [in] Image of the new firmware to flash. + uint32_t size ///< [in] Size of the flash image. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareFlash("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ", "; + oss << "pImage=" << loader::to_string(pImage); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareGetFlashProgress( + ze_result_t result, + zes_firmware_handle_t hFirmware, ///< [in] Handle for the component. + uint32_t* pCompletionPercent ///< [in,out] Pointer to the Completion Percentage of Firmware Update +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareGetFlashProgress("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ", "; + oss << "pCompletionPercent=" << loader::to_string(pCompletionPercent); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareGetConsoleLogs( + ze_result_t result, + zes_firmware_handle_t hFirmware, ///< [in] Handle for the component. + size_t* pSize, ///< [in,out] size of firmware log + char* pFirmwareLog ///< [in,out][optional] pointer to null-terminated string of the log. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareGetConsoleLogs("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pFirmwareLog=" << loader::to_string(pFirmwareLog); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumFrequencyDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_freq_handle_t* phFrequency ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumFrequencyDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phFrequency=" << loader::to_string(phFrequency); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyGetProperties( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_freq_properties_t* pProperties ///< [in,out] The frequency properties for the specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyGetProperties("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyGetAvailableClocks( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of frequencies. + ///< if count is zero, then the driver shall update the value with the + ///< total number of frequencies that are available. + ///< if count is greater than the number of frequencies that are available, + ///< then the driver shall update the value with the correct number of frequencies. + double* phFrequency ///< [in,out][optional][range(0, *pCount)] array of frequencies in units of + ///< MHz and sorted from slowest to fastest. + ///< if count is less than the number of frequencies that are available, + ///< then the driver shall only retrieve that number of frequencies. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyGetAvailableClocks("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phFrequency=" << loader::to_string(phFrequency); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyGetRange( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_freq_range_t* pLimits ///< [in,out] The range between which the hardware can operate for the + ///< specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyGetRange("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pLimits=" << loader::to_string(pLimits); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencySetRange( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + const zes_freq_range_t* pLimits ///< [in] The limits between which the hardware can operate for the + ///< specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencySetRange("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pLimits=" << loader::to_string(pLimits); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyGetState( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_freq_state_t* pState ///< [in,out] Frequency state for the specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyGetState("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyGetThrottleTime( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_freq_throttle_time_t* pThrottleTime ///< [in,out] Will contain a snapshot of the throttle time counters for the + ///< specified domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyGetThrottleTime("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pThrottleTime=" << loader::to_string(pThrottleTime); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetCapabilities( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_oc_capabilities_t* pOcCapabilities ///< [in,out] Pointer to the capabilities structure. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetCapabilities("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pOcCapabilities=" << loader::to_string(pOcCapabilities); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetFrequencyTarget( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double* pCurrentOcFrequency ///< [out] Overclocking Frequency in MHz, if extended moded is supported, + ///< will returned in 1 Mhz granularity, else, in multiples of 50 Mhz. This + ///< cannot be greater than the `maxOcFrequency` member of + ///< ::zes_oc_capabilities_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetFrequencyTarget("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pCurrentOcFrequency=" << loader::to_string(pCurrentOcFrequency); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcSetFrequencyTarget( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double CurrentOcFrequency ///< [in] Overclocking Frequency in MHz, if extended moded is supported, it + ///< could be set in 1 Mhz granularity, else, in multiples of 50 Mhz. This + ///< cannot be greater than the `maxOcFrequency` member of + ///< ::zes_oc_capabilities_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcSetFrequencyTarget("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "CurrentOcFrequency=" << loader::to_string(CurrentOcFrequency); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetVoltageTarget( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double* pCurrentVoltageTarget, ///< [out] Overclock voltage in Volts. This cannot be greater than the + ///< `maxOcVoltage` member of ::zes_oc_capabilities_t. + double* pCurrentVoltageOffset ///< [out] This voltage offset is applied to all points on the + ///< voltage/frequency curve, including the new overclock voltageTarget. + ///< Valid range is between the `minOcVoltageOffset` and + ///< `maxOcVoltageOffset` members of ::zes_oc_capabilities_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetVoltageTarget("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pCurrentVoltageTarget=" << loader::to_string(pCurrentVoltageTarget); + oss << ", "; + oss << "pCurrentVoltageOffset=" << loader::to_string(pCurrentVoltageOffset); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcSetVoltageTarget( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double CurrentVoltageTarget, ///< [in] Overclock voltage in Volts. This cannot be greater than the + ///< `maxOcVoltage` member of ::zes_oc_capabilities_t. + double CurrentVoltageOffset ///< [in] This voltage offset is applied to all points on the + ///< voltage/frequency curve, include the new overclock voltageTarget. + ///< Valid range is between the `minOcVoltageOffset` and + ///< `maxOcVoltageOffset` members of ::zes_oc_capabilities_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcSetVoltageTarget("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "CurrentVoltageTarget=" << loader::to_string(CurrentVoltageTarget); + oss << ", "; + oss << "CurrentVoltageOffset=" << loader::to_string(CurrentVoltageOffset); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcSetMode( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_oc_mode_t CurrentOcMode ///< [in] Current Overclocking Mode ::zes_oc_mode_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcSetMode("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "CurrentOcMode=" << loader::to_string(CurrentOcMode); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetMode( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + zes_oc_mode_t* pCurrentOcMode ///< [out] Current Overclocking Mode ::zes_oc_mode_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetMode("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pCurrentOcMode=" << loader::to_string(pCurrentOcMode); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetIccMax( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double* pOcIccMax ///< [in,out] Will contain the maximum current limit in Amperes on + ///< successful return. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetIccMax("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pOcIccMax=" << loader::to_string(pOcIccMax); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcSetIccMax( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double ocIccMax ///< [in] The new maximum current limit in Amperes. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcSetIccMax("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "ocIccMax=" << loader::to_string(ocIccMax); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcGetTjMax( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double* pOcTjMax ///< [in,out] Will contain the maximum temperature limit in degrees Celsius + ///< on successful return. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcGetTjMax("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "pOcTjMax=" << loader::to_string(pOcTjMax); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFrequencyOcSetTjMax( + ze_result_t result, + zes_freq_handle_t hFrequency, ///< [in] Handle for the component. + double ocTjMax ///< [in] The new maximum temperature limit in degrees Celsius. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFrequencyOcSetTjMax("; + oss << "hFrequency=" << loader::to_string(hFrequency); + oss << ", "; + oss << "ocTjMax=" << loader::to_string(ocTjMax); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumLeds( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_led_handle_t* phLed ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumLeds("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phLed=" << loader::to_string(phLed); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesLedGetProperties( + ze_result_t result, + zes_led_handle_t hLed, ///< [in] Handle for the component. + zes_led_properties_t* pProperties ///< [in,out] Will contain the properties of the LED. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesLedGetProperties("; + oss << "hLed=" << loader::to_string(hLed); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesLedGetState( + ze_result_t result, + zes_led_handle_t hLed, ///< [in] Handle for the component. + zes_led_state_t* pState ///< [in,out] Will contain the current state of the LED. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesLedGetState("; + oss << "hLed=" << loader::to_string(hLed); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesLedSetState( + ze_result_t result, + zes_led_handle_t hLed, ///< [in] Handle for the component. + ze_bool_t enable ///< [in] Set to TRUE to turn the LED on, FALSE to turn off. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesLedSetState("; + oss << "hLed=" << loader::to_string(hLed); + oss << ", "; + oss << "enable=" << loader::to_string(enable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesLedSetColor( + ze_result_t result, + zes_led_handle_t hLed, ///< [in] Handle for the component. + const zes_led_color_t* pColor ///< [in] New color of the LED. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesLedSetColor("; + oss << "hLed=" << loader::to_string(hLed); + oss << ", "; + oss << "pColor=" << loader::to_string(pColor); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumMemoryModules( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_mem_handle_t* phMemory ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumMemoryModules("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phMemory=" << loader::to_string(phMemory); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesMemoryGetProperties( + ze_result_t result, + zes_mem_handle_t hMemory, ///< [in] Handle for the component. + zes_mem_properties_t* pProperties ///< [in,out] Will contain memory properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesMemoryGetProperties("; + oss << "hMemory=" << loader::to_string(hMemory); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesMemoryGetState( + ze_result_t result, + zes_mem_handle_t hMemory, ///< [in] Handle for the component. + zes_mem_state_t* pState ///< [in,out] Will contain the current health and allocated memory. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesMemoryGetState("; + oss << "hMemory=" << loader::to_string(hMemory); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesMemoryGetBandwidth( + ze_result_t result, + zes_mem_handle_t hMemory, ///< [in] Handle for the component. + zes_mem_bandwidth_t* pBandwidth ///< [in,out] Will contain the total number of bytes read from and written + ///< to memory, as well as the current maximum bandwidth. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesMemoryGetBandwidth("; + oss << "hMemory=" << loader::to_string(hMemory); + oss << ", "; + oss << "pBandwidth=" << loader::to_string(pBandwidth); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_perf_handle_t* phPerf ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumPerformanceFactorDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phPerf=" << loader::to_string(phPerf); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPerformanceFactorGetProperties( + ze_result_t result, + zes_perf_handle_t hPerf, ///< [in] Handle for the Performance Factor domain. + zes_perf_properties_t* pProperties ///< [in,out] Will contain information about the specified Performance + ///< Factor domain. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPerformanceFactorGetProperties("; + oss << "hPerf=" << loader::to_string(hPerf); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPerformanceFactorGetConfig( + ze_result_t result, + zes_perf_handle_t hPerf, ///< [in] Handle for the Performance Factor domain. + double* pFactor ///< [in,out] Will contain the actual Performance Factor being used by the + ///< hardware (may not be the same as the requested Performance Factor). +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPerformanceFactorGetConfig("; + oss << "hPerf=" << loader::to_string(hPerf); + oss << ", "; + oss << "pFactor=" << loader::to_string(pFactor); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPerformanceFactorSetConfig( + ze_result_t result, + zes_perf_handle_t hPerf, ///< [in] Handle for the Performance Factor domain. + double factor ///< [in] The new Performance Factor. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPerformanceFactorSetConfig("; + oss << "hPerf=" << loader::to_string(hPerf); + oss << ", "; + oss << "factor=" << loader::to_string(factor); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumPowerDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_pwr_handle_t* phPower ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumPowerDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phPower=" << loader::to_string(phPower); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetCardPowerDomain( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + zes_pwr_handle_t* phPower ///< [in,out] power domain handle for the entire PCIe card. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetCardPowerDomain("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "phPower=" << loader::to_string(phPower); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerGetProperties( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + zes_power_properties_t* pProperties ///< [in,out] Structure that will contain property data. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerGetProperties("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerGetEnergyCounter( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + zes_power_energy_counter_t* pEnergy ///< [in,out] Will contain the latest snapshot of the energy counter and + ///< timestamp when the last counter value was measured. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerGetEnergyCounter("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pEnergy=" << loader::to_string(pEnergy); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerGetLimits( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + zes_power_sustained_limit_t* pSustained, ///< [in,out][optional] The sustained power limit. If this is null, the + ///< current sustained power limits will not be returned. + zes_power_burst_limit_t* pBurst, ///< [in,out][optional] The burst power limit. If this is null, the current + ///< peak power limits will not be returned. + zes_power_peak_limit_t* pPeak ///< [in,out][optional] The peak power limit. If this is null, the peak + ///< power limits will not be returned. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerGetLimits("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pSustained=" << loader::to_string(pSustained); + oss << ", "; + oss << "pBurst=" << loader::to_string(pBurst); + oss << ", "; + oss << "pPeak=" << loader::to_string(pPeak); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerSetLimits( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + const zes_power_sustained_limit_t* pSustained, ///< [in][optional] The sustained power limit. If this is null, no changes + ///< will be made to the sustained power limits. + const zes_power_burst_limit_t* pBurst, ///< [in][optional] The burst power limit. If this is null, no changes will + ///< be made to the burst power limits. + const zes_power_peak_limit_t* pPeak ///< [in][optional] The peak power limit. If this is null, no changes will + ///< be made to the peak power limits. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerSetLimits("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pSustained=" << loader::to_string(pSustained); + oss << ", "; + oss << "pBurst=" << loader::to_string(pBurst); + oss << ", "; + oss << "pPeak=" << loader::to_string(pPeak); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerGetEnergyThreshold( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + zes_energy_threshold_t* pThreshold ///< [in,out] Returns information about the energy threshold setting - + ///< enabled/energy threshold/process ID. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerGetEnergyThreshold("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pThreshold=" << loader::to_string(pThreshold); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerSetEnergyThreshold( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + double threshold ///< [in] The energy threshold to be set in joules. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerSetEnergyThreshold("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "threshold=" << loader::to_string(threshold); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumPsus( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_psu_handle_t* phPsu ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumPsus("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phPsu=" << loader::to_string(phPsu); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPsuGetProperties( + ze_result_t result, + zes_psu_handle_t hPsu, ///< [in] Handle for the component. + zes_psu_properties_t* pProperties ///< [in,out] Will contain the properties of the power supply. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPsuGetProperties("; + oss << "hPsu=" << loader::to_string(hPsu); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPsuGetState( + ze_result_t result, + zes_psu_handle_t hPsu, ///< [in] Handle for the component. + zes_psu_state_t* pState ///< [in,out] Will contain the current state of the power supply. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPsuGetState("; + oss << "hPsu=" << loader::to_string(hPsu); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumRasErrorSets( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_ras_handle_t* phRas ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumRasErrorSets("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phRas=" << loader::to_string(phRas); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasGetProperties( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + zes_ras_properties_t* pProperties ///< [in,out] Structure describing RAS properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasGetProperties("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasGetConfig( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + zes_ras_config_t* pConfig ///< [in,out] Will be populed with the current RAS configuration - + ///< thresholds used to trigger events +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasGetConfig("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasSetConfig( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + const zes_ras_config_t* pConfig ///< [in] Change the RAS configuration - thresholds used to trigger events +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasSetConfig("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasGetState( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + ze_bool_t clear, ///< [in] Set to 1 to clear the counters of this type + zes_ras_state_t* pState ///< [in,out] Breakdown of where errors have occurred +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasGetState("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "clear=" << loader::to_string(clear); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumSchedulers( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_sched_handle_t* phScheduler ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumSchedulers("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phScheduler=" << loader::to_string(phScheduler); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerGetProperties( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Handle for the component. + zes_sched_properties_t* pProperties ///< [in,out] Structure that will contain property data. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerGetProperties("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerGetCurrentMode( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + zes_sched_mode_t* pMode ///< [in,out] Will contain the current scheduler mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerGetCurrentMode("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pMode=" << loader::to_string(pMode); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerGetTimeoutModeProperties( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + ze_bool_t getDefaults, ///< [in] If TRUE, the driver will return the system default properties for + ///< this mode, otherwise it will return the current properties. + zes_sched_timeout_properties_t* pConfig ///< [in,out] Will contain the current parameters for this mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerGetTimeoutModeProperties("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "getDefaults=" << loader::to_string(getDefaults); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerGetTimesliceModeProperties( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + ze_bool_t getDefaults, ///< [in] If TRUE, the driver will return the system default properties for + ///< this mode, otherwise it will return the current properties. + zes_sched_timeslice_properties_t* pConfig ///< [in,out] Will contain the current parameters for this mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerGetTimesliceModeProperties("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "getDefaults=" << loader::to_string(getDefaults); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerSetTimeoutMode( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + zes_sched_timeout_properties_t* pProperties, ///< [in] The properties to use when configurating this mode. + ze_bool_t* pNeedReload ///< [in,out] Will be set to TRUE if a device driver reload is needed to + ///< apply the new scheduler mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerSetTimeoutMode("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ", "; + oss << "pNeedReload=" << loader::to_string(pNeedReload); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerSetTimesliceMode( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + zes_sched_timeslice_properties_t* pProperties, ///< [in] The properties to use when configurating this mode. + ze_bool_t* pNeedReload ///< [in,out] Will be set to TRUE if a device driver reload is needed to + ///< apply the new scheduler mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerSetTimesliceMode("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ", "; + oss << "pNeedReload=" << loader::to_string(pNeedReload); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerSetExclusiveMode( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + ze_bool_t* pNeedReload ///< [in,out] Will be set to TRUE if a device driver reload is needed to + ///< apply the new scheduler mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerSetExclusiveMode("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pNeedReload=" << loader::to_string(pNeedReload); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode( + ze_result_t result, + zes_sched_handle_t hScheduler, ///< [in] Sysman handle for the component. + ze_bool_t* pNeedReload ///< [in,out] Will be set to TRUE if a device driver reload is needed to + ///< apply the new scheduler mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesSchedulerSetComputeUnitDebugMode("; + oss << "hScheduler=" << loader::to_string(hScheduler); + oss << ", "; + oss << "pNeedReload=" << loader::to_string(pNeedReload); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumStandbyDomains( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_standby_handle_t* phStandby ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumStandbyDomains("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phStandby=" << loader::to_string(phStandby); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesStandbyGetProperties( + ze_result_t result, + zes_standby_handle_t hStandby, ///< [in] Handle for the component. + zes_standby_properties_t* pProperties ///< [in,out] Will contain the standby hardware properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesStandbyGetProperties("; + oss << "hStandby=" << loader::to_string(hStandby); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesStandbyGetMode( + ze_result_t result, + zes_standby_handle_t hStandby, ///< [in] Handle for the component. + zes_standby_promo_mode_t* pMode ///< [in,out] Will contain the current standby mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesStandbyGetMode("; + oss << "hStandby=" << loader::to_string(hStandby); + oss << ", "; + oss << "pMode=" << loader::to_string(pMode); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesStandbySetMode( + ze_result_t result, + zes_standby_handle_t hStandby, ///< [in] Handle for the component. + zes_standby_promo_mode_t mode ///< [in] New standby mode. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesStandbySetMode("; + oss << "hStandby=" << loader::to_string(hStandby); + oss << ", "; + oss << "mode=" << loader::to_string(mode); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumTemperatureSensors( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_temp_handle_t* phTemperature ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumTemperatureSensors("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phTemperature=" << loader::to_string(phTemperature); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesTemperatureGetProperties( + ze_result_t result, + zes_temp_handle_t hTemperature, ///< [in] Handle for the component. + zes_temp_properties_t* pProperties ///< [in,out] Will contain the temperature sensor properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesTemperatureGetProperties("; + oss << "hTemperature=" << loader::to_string(hTemperature); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesTemperatureGetConfig( + ze_result_t result, + zes_temp_handle_t hTemperature, ///< [in] Handle for the component. + zes_temp_config_t* pConfig ///< [in,out] Returns current configuration. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesTemperatureGetConfig("; + oss << "hTemperature=" << loader::to_string(hTemperature); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesTemperatureSetConfig( + ze_result_t result, + zes_temp_handle_t hTemperature, ///< [in] Handle for the component. + const zes_temp_config_t* pConfig ///< [in] New configuration. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesTemperatureSetConfig("; + oss << "hTemperature=" << loader::to_string(hTemperature); + oss << ", "; + oss << "pConfig=" << loader::to_string(pConfig); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesTemperatureGetState( + ze_result_t result, + zes_temp_handle_t hTemperature, ///< [in] Handle for the component. + double* pTemperature ///< [in,out] Will contain the temperature read from the specified sensor + ///< in degrees Celsius. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesTemperatureGetState("; + oss << "hTemperature=" << loader::to_string(hTemperature); + oss << ", "; + oss << "pTemperature=" << loader::to_string(pTemperature); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerGetLimitsExt( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Power domain handle instance. + uint32_t* pCount, ///< [in,out] Pointer to the number of power limit descriptors. If count is + ///< zero, then the driver shall update the value with the total number of + ///< components of this type that are available. If count is greater than + ///< the number of components of this type that are available, then the + ///< driver shall update the value with the correct number of components. + zes_power_limit_ext_desc_t* pSustained ///< [in,out][optional][range(0, *pCount)] Array of query results for power + ///< limit descriptors. If count is less than the number of components of + ///< this type that are available, then the driver shall only retrieve that + ///< number of components. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerGetLimitsExt("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pSustained=" << loader::to_string(pSustained); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesPowerSetLimitsExt( + ze_result_t result, + zes_pwr_handle_t hPower, ///< [in] Handle for the component. + uint32_t* pCount, ///< [in] Pointer to the number of power limit descriptors. + zes_power_limit_ext_desc_t* pSustained ///< [in][optional][range(0, *pCount)] Array of power limit descriptors. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesPowerSetLimitsExt("; + oss << "hPower=" << loader::to_string(hPower); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pSustained=" << loader::to_string(pSustained); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesEngineGetActivityExt( + ze_result_t result, + zes_engine_handle_t hEngine, ///< [in] Handle for the component. + uint32_t* pCount, ///< [in,out] Pointer to the number of VF engine stats descriptors. + ///< - if count is zero, the driver shall update the value with the total + ///< number of engine stats available. + ///< - if count is greater than the total number of engine stats + ///< available, the driver shall update the value with the correct number + ///< of engine stats available. + ///< - The count returned is the sum of number of VF instances currently + ///< available and the PF instance. + zes_engine_stats_t* pStats ///< [in,out][optional][range(0, *pCount)] array of engine group activity counters. + ///< - if count is less than the total number of engine stats available, + ///< then driver shall only retrieve that number of stats. + ///< - the implementation shall populate the vector with engine stat for + ///< PF at index 0 of the vector followed by user provided pCount-1 number + ///< of VF engine stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesEngineGetActivityExt("; + oss << "hEngine=" << loader::to_string(hEngine); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pStats=" << loader::to_string(pStats); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasGetStateExp( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + uint32_t* pCount, ///< [in,out] pointer to the number of RAS state structures that can be retrieved. + ///< if count is zero, then the driver shall update the value with the + ///< total number of error categories for which state can be retrieved. + ///< if count is greater than the number of RAS states available, then the + ///< driver shall update the value with the correct number of RAS states available. + zes_ras_state_exp_t* pState ///< [in,out][optional][range(0, *pCount)] array of query results for RAS + ///< error states for different categories. + ///< if count is less than the number of RAS states available, then driver + ///< shall only retrieve that number of RAS states. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasGetStateExp("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pState=" << loader::to_string(pState); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesRasClearStateExp( + ze_result_t result, + zes_ras_handle_t hRas, ///< [in] Handle for the component. + zes_ras_error_category_exp_t category ///< [in] category for which error counter is to be cleared. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesRasClearStateExp("; + oss << "hRas=" << loader::to_string(hRas); + oss << ", "; + oss << "category=" << loader::to_string(category); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareGetSecurityVersionExp( + ze_result_t result, + zes_firmware_handle_t hFirmware, ///< [in] Handle for the component. + char* pVersion ///< [in,out] NULL terminated string value. The string "unknown" will be + ///< returned if this property cannot be determined. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareGetSecurityVersionExp("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ", "; + oss << "pVersion=" << loader::to_string(pVersion); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesFirmwareSetSecurityVersionExp( + ze_result_t result, + zes_firmware_handle_t hFirmware ///< [in] Handle for the component. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesFirmwareSetSecurityVersionExp("; + oss << "hFirmware=" << loader::to_string(hFirmware); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of sub devices. + ///< if count is zero, then the driver shall update the value with the + ///< total number of sub devices currently attached to the device. + ///< if count is greater than the number of sub devices currently attached + ///< to the device, then the driver shall update the value with the correct + ///< number of sub devices. + zes_subdevice_exp_properties_t* pSubdeviceProps ///< [in,out][optional][range(0, *pCount)] array of sub device property structures. + ///< if count is less than the number of sysman sub devices available, then + ///< the driver shall only retrieve that number of sub device property structures. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceGetSubDevicePropertiesExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pSubdeviceProps=" << loader::to_string(pSubdeviceProps); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDriverGetDeviceByUuidExp( + ze_result_t result, + zes_driver_handle_t hDriver, ///< [in] handle of the sysman driver instance + zes_uuid_t uuid, ///< [in] universal unique identifier. + zes_device_handle_t* phDevice, ///< [out] Sysman handle of the device. + ze_bool_t* onSubdevice, ///< [out] True if the UUID belongs to the sub-device; false means that + ///< UUID belongs to the root device. + uint32_t* subdeviceId ///< [out] If onSubdevice is true, this gives the ID of the sub-device +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDriverGetDeviceByUuidExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "uuid=" << loader::to_string(uuid); + oss << ", "; + oss << "phDevice=" << loader::to_string(phDevice); + oss << ", "; + oss << "onSubdevice=" << loader::to_string(onSubdevice); + oss << ", "; + oss << "subdeviceId=" << loader::to_string(subdeviceId); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumActiveVFExp( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_vf_handle_t* phVFhandle ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumActiveVFExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phVFhandle=" << loader::to_string(phVFhandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFPropertiesExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the VF component. + zes_vf_exp_properties_t* pProperties ///< [in,out] Will contain VF properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFPropertiesExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + uint32_t* pCount, ///< [in,out] Pointer to the number of VF memory stats descriptors. + ///< - if count is zero, the driver shall update the value with the total + ///< number of memory stats available. + ///< - if count is greater than the total number of memory stats + ///< available, the driver shall update the value with the correct number + ///< of memory stats available. + ///< - The count returned is the sum of number of VF instances currently + ///< available and the PF instance. + zes_vf_util_mem_exp_t* pMemUtil ///< [in,out][optional][range(0, *pCount)] array of memory group activity counters. + ///< - if count is less than the total number of memory stats available, + ///< then driver shall only retrieve that number of stats. + ///< - the implementation shall populate the vector pCount-1 number of VF + ///< memory stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFMemoryUtilizationExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pMemUtil=" << loader::to_string(pMemUtil); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + uint32_t* pCount, ///< [in,out] Pointer to the number of VF engine stats descriptors. + ///< - if count is zero, the driver shall update the value with the total + ///< number of engine stats available. + ///< - if count is greater than the total number of engine stats + ///< available, the driver shall update the value with the correct number + ///< of engine stats available. + ///< - The count returned is the sum of number of VF instances currently + ///< available and the PF instance. + zes_vf_util_engine_exp_t* pEngineUtil ///< [in,out][optional][range(0, *pCount)] array of engine group activity counters. + ///< - if count is less than the total number of engine stats available, + ///< then driver shall only retrieve that number of stats. + ///< - the implementation shall populate the vector pCount-1 number of VF + ///< engine stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFEngineUtilizationExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pEngineUtil=" << loader::to_string(pEngineUtil); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + zes_vf_info_util_exp_flags_t flags, ///< [in] utilization flags to enable or disable. May be 0 or a valid + ///< combination of ::zes_vf_info_util_exp_flag_t. + ze_bool_t enable ///< [in] Enable utilization telemetry. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementSetVFTelemetryModeExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "flags=" << loader::to_string(flags); + oss << ", "; + oss << "enable=" << loader::to_string(enable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + zes_vf_info_util_exp_flags_t flag, ///< [in] utilization flags to set sampling interval. May be 0 or a valid + ///< combination of ::zes_vf_info_util_exp_flag_t. + uint64_t samplingInterval ///< [in] Sampling interval value. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementSetVFTelemetrySamplingIntervalExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "flag=" << loader::to_string(flag); + oss << ", "; + oss << "samplingInterval=" << loader::to_string(samplingInterval); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesDeviceEnumEnabledVFExp( + ze_result_t result, + zes_device_handle_t hDevice, ///< [in] Sysman handle of the device. + uint32_t* pCount, ///< [in,out] pointer to the number of components of this type. + ///< if count is zero, then the driver shall update the value with the + ///< total number of components of this type that are available. + ///< if count is greater than the number of components of this type that + ///< are available, then the driver shall update the value with the correct + ///< number of components. + zes_vf_handle_t* phVFhandle ///< [in,out][optional][range(0, *pCount)] array of handle of components of + ///< this type. + ///< if count is less than the number of components of this type that are + ///< available, then the driver shall only retrieve that number of + ///< component handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesDeviceEnumEnabledVFExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phVFhandle=" << loader::to_string(phVFhandle); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the VF component. + zes_vf_exp_capabilities_t* pCapability ///< [in,out] Will contain VF capability. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFCapabilitiesExp("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCapability=" << loader::to_string(pCapability); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + uint32_t* pCount, ///< [in,out] Pointer to the number of VF memory stats descriptors. + ///< - if count is zero, the driver shall update the value with the total + ///< number of memory stats available. + ///< - if count is greater than the total number of memory stats + ///< available, the driver shall update the value with the correct number + ///< of memory stats available. + zes_vf_util_mem_exp2_t* pMemUtil ///< [in,out][optional][range(0, *pCount)] array of memory group activity counters. + ///< - if count is less than the total number of memory stats available, + ///< then driver shall only retrieve that number of stats. + ///< - the implementation shall populate the vector pCount-1 number of VF + ///< memory stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFMemoryUtilizationExp2("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pMemUtil=" << loader::to_string(pMemUtil); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the component. + uint32_t* pCount, ///< [in,out] Pointer to the number of VF engine stats descriptors. + ///< - if count is zero, the driver shall update the value with the total + ///< number of engine stats available. + ///< - if count is greater than the total number of engine stats + ///< available, the driver shall update the value with the correct number + ///< of engine stats available. + zes_vf_util_engine_exp2_t* pEngineUtil ///< [in,out][optional][range(0, *pCount)] array of engine group activity counters. + ///< - if count is less than the total number of engine stats available, + ///< then driver shall only retrieve that number of stats. + ///< - the implementation shall populate the vector pCount-1 number of VF + ///< engine stats. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFEngineUtilizationExp2("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pEngineUtil=" << loader::to_string(pEngineUtil); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2( + ze_result_t result, + zes_vf_handle_t hVFhandle, ///< [in] Sysman handle for the VF component. + zes_vf_exp2_capabilities_t* pCapability ///< [in,out] Will contain VF capability. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zesVFManagementGetVFCapabilitiesExp2("; + oss << "hVFhandle=" << loader::to_string(hVFhandle); + oss << ", "; + oss << "pCapability=" << loader::to_string(pCapability); + oss << ")"; + context.logger->log_trace(oss.str()); return result; } @@ -33,12 +2886,12 @@ namespace validation_layer auto pfnInit = context.zesDdiTable.Global.pfnInit; if( nullptr == pfnInit ) - return logAndPropagateResult("zesInit", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesInit(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, flags); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesInitPrologue( flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesInit(result, flags); } @@ -49,17 +2902,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesInitPrologue( flags ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesInit(result, flags); } auto driver_result = pfnInit( flags ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesInitEpilogue( flags ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesInit", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesInit(result, flags); } - return logAndPropagateResult("zesInit", driver_result); + return logAndPropagateResult_zesInit(driver_result, flags); } /////////////////////////////////////////////////////////////////////////////// @@ -82,12 +2935,12 @@ namespace validation_layer auto pfnGet = context.zesDdiTable.Driver.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zesDriverGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, pCount, phDrivers); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetPrologue( pCount, phDrivers ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGet(result, pCount, phDrivers); } @@ -98,14 +2951,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverGetPrologue( pCount, phDrivers ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGet(result, pCount, phDrivers); } auto driver_result = pfnGet( pCount, phDrivers ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetEpilogue( pCount, phDrivers ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGet(result, pCount, phDrivers); } @@ -118,7 +2971,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zesDriverGet", driver_result); + return logAndPropagateResult_zesDriverGet(driver_result, pCount, phDrivers); } /////////////////////////////////////////////////////////////////////////////// @@ -143,12 +2996,12 @@ namespace validation_layer auto pfnGetExtensionProperties = context.zesDdiTable.Driver.pfnGetExtensionProperties; if( nullptr == pfnGetExtensionProperties ) - return logAndPropagateResult("zesDriverGetExtensionProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverGetExtensionProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pCount, pExtensionProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetExtensionPropertiesPrologue( hDriver, pCount, pExtensionProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } @@ -159,17 +3012,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverGetExtensionPropertiesPrologue( hDriver, pCount, pExtensionProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } auto driver_result = pfnGetExtensionProperties( hDriver, pCount, pExtensionProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetExtensionPropertiesEpilogue( hDriver, pCount, pExtensionProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionProperties(result, hDriver, pCount, pExtensionProperties); } - return logAndPropagateResult("zesDriverGetExtensionProperties", driver_result); + return logAndPropagateResult_zesDriverGetExtensionProperties(driver_result, hDriver, pCount, pExtensionProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -186,12 +3039,12 @@ namespace validation_layer auto pfnGetExtensionFunctionAddress = context.zesDdiTable.Driver.pfnGetExtensionFunctionAddress; if( nullptr == pfnGetExtensionFunctionAddress ) - return logAndPropagateResult("zesDriverGetExtensionFunctionAddress", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverGetExtensionFunctionAddress(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, name, ppFunctionAddress); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetExtensionFunctionAddressPrologue( hDriver, name, ppFunctionAddress ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } @@ -202,17 +3055,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverGetExtensionFunctionAddressPrologue( hDriver, name, ppFunctionAddress ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } auto driver_result = pfnGetExtensionFunctionAddress( hDriver, name, ppFunctionAddress ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetExtensionFunctionAddressEpilogue( hDriver, name, ppFunctionAddress ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetExtensionFunctionAddress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetExtensionFunctionAddress(result, hDriver, name, ppFunctionAddress); } - return logAndPropagateResult("zesDriverGetExtensionFunctionAddress", driver_result); + return logAndPropagateResult_zesDriverGetExtensionFunctionAddress(driver_result, hDriver, name, ppFunctionAddress); } /////////////////////////////////////////////////////////////////////////////// @@ -236,12 +3089,12 @@ namespace validation_layer auto pfnGet = context.zesDdiTable.Device.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zesDeviceGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, pCount, phDevices); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetPrologue( hDriver, pCount, phDevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGet(result, hDriver, pCount, phDevices); } @@ -252,14 +3105,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetPrologue( hDriver, pCount, phDevices ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGet(result, hDriver, pCount, phDevices); } auto driver_result = pfnGet( hDriver, pCount, phDevices ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetEpilogue( hDriver, pCount, phDevices ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGet(result, hDriver, pCount, phDevices); } @@ -272,7 +3125,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zesDeviceGet", driver_result); + return logAndPropagateResult_zesDeviceGet(driver_result, hDriver, pCount, phDevices); } /////////////////////////////////////////////////////////////////////////////// @@ -288,12 +3141,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Device.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesDeviceGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetPropertiesPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetProperties(result, hDevice, pProperties); } @@ -304,17 +3157,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetPropertiesPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetProperties(result, hDevice, pProperties); } auto driver_result = pfnGetProperties( hDevice, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetPropertiesEpilogue( hDevice, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetProperties(result, hDevice, pProperties); } - return logAndPropagateResult("zesDeviceGetProperties", driver_result); + return logAndPropagateResult_zesDeviceGetProperties(driver_result, hDevice, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -330,12 +3183,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Device.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesDeviceGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetState(result, hDevice, pState); } @@ -346,17 +3199,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetState(result, hDevice, pState); } auto driver_result = pfnGetState( hDevice, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetStateEpilogue( hDevice, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetState(result, hDevice, pState); } - return logAndPropagateResult("zesDeviceGetState", driver_result); + return logAndPropagateResult_zesDeviceGetState(driver_result, hDevice, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -373,12 +3226,12 @@ namespace validation_layer auto pfnReset = context.zesDdiTable.Device.pfnReset; if( nullptr == pfnReset ) - return logAndPropagateResult("zesDeviceReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, force); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetPrologue( hDevice, force ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReset(result, hDevice, force); } @@ -389,17 +3242,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceResetPrologue( hDevice, force ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReset(result, hDevice, force); } auto driver_result = pfnReset( hDevice, force ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetEpilogue( hDevice, force ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReset(result, hDevice, force); } - return logAndPropagateResult("zesDeviceReset", driver_result); + return logAndPropagateResult_zesDeviceReset(driver_result, hDevice, force); } /////////////////////////////////////////////////////////////////////////////// @@ -415,12 +3268,12 @@ namespace validation_layer auto pfnResetExt = context.zesDdiTable.Device.pfnResetExt; if( nullptr == pfnResetExt ) - return logAndPropagateResult("zesDeviceResetExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceResetExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetExtPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetExt(result, hDevice, pProperties); } @@ -431,17 +3284,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceResetExtPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetExt(result, hDevice, pProperties); } auto driver_result = pfnResetExt( hDevice, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetExtEpilogue( hDevice, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetExt(result, hDevice, pProperties); } - return logAndPropagateResult("zesDeviceResetExt", driver_result); + return logAndPropagateResult_zesDeviceResetExt(driver_result, hDevice, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -466,12 +3319,12 @@ namespace validation_layer auto pfnProcessesGetState = context.zesDdiTable.Device.pfnProcessesGetState; if( nullptr == pfnProcessesGetState ) - return logAndPropagateResult("zesDeviceProcessesGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceProcessesGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pProcesses); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceProcessesGetStatePrologue( hDevice, pCount, pProcesses ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceProcessesGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceProcessesGetState(result, hDevice, pCount, pProcesses); } @@ -482,17 +3335,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceProcessesGetStatePrologue( hDevice, pCount, pProcesses ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceProcessesGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceProcessesGetState(result, hDevice, pCount, pProcesses); } auto driver_result = pfnProcessesGetState( hDevice, pCount, pProcesses ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceProcessesGetStateEpilogue( hDevice, pCount, pProcesses ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceProcessesGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceProcessesGetState(result, hDevice, pCount, pProcesses); } - return logAndPropagateResult("zesDeviceProcessesGetState", driver_result); + return logAndPropagateResult_zesDeviceProcessesGetState(driver_result, hDevice, pCount, pProcesses); } /////////////////////////////////////////////////////////////////////////////// @@ -508,12 +3361,12 @@ namespace validation_layer auto pfnPciGetProperties = context.zesDdiTable.Device.pfnPciGetProperties; if( nullptr == pfnPciGetProperties ) - return logAndPropagateResult("zesDevicePciGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDevicePciGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetPropertiesPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetProperties(result, hDevice, pProperties); } @@ -524,17 +3377,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDevicePciGetPropertiesPrologue( hDevice, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetProperties(result, hDevice, pProperties); } auto driver_result = pfnPciGetProperties( hDevice, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetPropertiesEpilogue( hDevice, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetProperties(result, hDevice, pProperties); } - return logAndPropagateResult("zesDevicePciGetProperties", driver_result); + return logAndPropagateResult_zesDevicePciGetProperties(driver_result, hDevice, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -550,12 +3403,12 @@ namespace validation_layer auto pfnPciGetState = context.zesDdiTable.Device.pfnPciGetState; if( nullptr == pfnPciGetState ) - return logAndPropagateResult("zesDevicePciGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDevicePciGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetState(result, hDevice, pState); } @@ -566,17 +3419,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDevicePciGetStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetState(result, hDevice, pState); } auto driver_result = pfnPciGetState( hDevice, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetStateEpilogue( hDevice, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetState(result, hDevice, pState); } - return logAndPropagateResult("zesDevicePciGetState", driver_result); + return logAndPropagateResult_zesDevicePciGetState(driver_result, hDevice, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -600,12 +3453,12 @@ namespace validation_layer auto pfnPciGetBars = context.zesDdiTable.Device.pfnPciGetBars; if( nullptr == pfnPciGetBars ) - return logAndPropagateResult("zesDevicePciGetBars", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDevicePciGetBars(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetBarsPrologue( hDevice, pCount, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetBars", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetBars(result, hDevice, pCount, pProperties); } @@ -616,17 +3469,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDevicePciGetBarsPrologue( hDevice, pCount, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetBars", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetBars(result, hDevice, pCount, pProperties); } auto driver_result = pfnPciGetBars( hDevice, pCount, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetBarsEpilogue( hDevice, pCount, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetBars", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetBars(result, hDevice, pCount, pProperties); } - return logAndPropagateResult("zesDevicePciGetBars", driver_result); + return logAndPropagateResult_zesDevicePciGetBars(driver_result, hDevice, pCount, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -642,12 +3495,12 @@ namespace validation_layer auto pfnPciGetStats = context.zesDdiTable.Device.pfnPciGetStats; if( nullptr == pfnPciGetStats ) - return logAndPropagateResult("zesDevicePciGetStats", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDevicePciGetStats(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pStats); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetStatsPrologue( hDevice, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetStats", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetStats(result, hDevice, pStats); } @@ -658,17 +3511,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDevicePciGetStatsPrologue( hDevice, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetStats", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetStats(result, hDevice, pStats); } auto driver_result = pfnPciGetStats( hDevice, pStats ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDevicePciGetStatsEpilogue( hDevice, pStats ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDevicePciGetStats", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDevicePciGetStats(result, hDevice, pStats); } - return logAndPropagateResult("zesDevicePciGetStats", driver_result); + return logAndPropagateResult_zesDevicePciGetStats(driver_result, hDevice, pStats); } /////////////////////////////////////////////////////////////////////////////// @@ -683,12 +3536,12 @@ namespace validation_layer auto pfnSetOverclockWaiver = context.zesDdiTable.Device.pfnSetOverclockWaiver; if( nullptr == pfnSetOverclockWaiver ) - return logAndPropagateResult("zesDeviceSetOverclockWaiver", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceSetOverclockWaiver(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceSetOverclockWaiverPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetOverclockWaiver", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetOverclockWaiver(result, hDevice); } @@ -699,17 +3552,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceSetOverclockWaiverPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetOverclockWaiver", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetOverclockWaiver(result, hDevice); } auto driver_result = pfnSetOverclockWaiver( hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceSetOverclockWaiverEpilogue( hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetOverclockWaiver", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetOverclockWaiver(result, hDevice); } - return logAndPropagateResult("zesDeviceSetOverclockWaiver", driver_result); + return logAndPropagateResult_zesDeviceSetOverclockWaiver(driver_result, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -727,12 +3580,12 @@ namespace validation_layer auto pfnGetOverclockDomains = context.zesDdiTable.Device.pfnGetOverclockDomains; if( nullptr == pfnGetOverclockDomains ) - return logAndPropagateResult("zesDeviceGetOverclockDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetOverclockDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pOverclockDomains); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetOverclockDomainsPrologue( hDevice, pOverclockDomains ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockDomains(result, hDevice, pOverclockDomains); } @@ -743,17 +3596,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetOverclockDomainsPrologue( hDevice, pOverclockDomains ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockDomains(result, hDevice, pOverclockDomains); } auto driver_result = pfnGetOverclockDomains( hDevice, pOverclockDomains ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetOverclockDomainsEpilogue( hDevice, pOverclockDomains ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockDomains(result, hDevice, pOverclockDomains); } - return logAndPropagateResult("zesDeviceGetOverclockDomains", driver_result); + return logAndPropagateResult_zesDeviceGetOverclockDomains(driver_result, hDevice, pOverclockDomains); } /////////////////////////////////////////////////////////////////////////////// @@ -772,12 +3625,12 @@ namespace validation_layer auto pfnGetOverclockControls = context.zesDdiTable.Device.pfnGetOverclockControls; if( nullptr == pfnGetOverclockControls ) - return logAndPropagateResult("zesDeviceGetOverclockControls", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetOverclockControls(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, domainType, pAvailableControls); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetOverclockControlsPrologue( hDevice, domainType, pAvailableControls ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockControls", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockControls(result, hDevice, domainType, pAvailableControls); } @@ -788,17 +3641,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetOverclockControlsPrologue( hDevice, domainType, pAvailableControls ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockControls", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockControls(result, hDevice, domainType, pAvailableControls); } auto driver_result = pfnGetOverclockControls( hDevice, domainType, pAvailableControls ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetOverclockControlsEpilogue( hDevice, domainType, pAvailableControls ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetOverclockControls", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetOverclockControls(result, hDevice, domainType, pAvailableControls); } - return logAndPropagateResult("zesDeviceGetOverclockControls", driver_result); + return logAndPropagateResult_zesDeviceGetOverclockControls(driver_result, hDevice, domainType, pAvailableControls); } /////////////////////////////////////////////////////////////////////////////// @@ -815,12 +3668,12 @@ namespace validation_layer auto pfnResetOverclockSettings = context.zesDdiTable.Device.pfnResetOverclockSettings; if( nullptr == pfnResetOverclockSettings ) - return logAndPropagateResult("zesDeviceResetOverclockSettings", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceResetOverclockSettings(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, onShippedState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetOverclockSettingsPrologue( hDevice, onShippedState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetOverclockSettings", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetOverclockSettings(result, hDevice, onShippedState); } @@ -831,17 +3684,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceResetOverclockSettingsPrologue( hDevice, onShippedState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetOverclockSettings", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetOverclockSettings(result, hDevice, onShippedState); } auto driver_result = pfnResetOverclockSettings( hDevice, onShippedState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceResetOverclockSettingsEpilogue( hDevice, onShippedState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceResetOverclockSettings", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceResetOverclockSettings(result, hDevice, onShippedState); } - return logAndPropagateResult("zesDeviceResetOverclockSettings", driver_result); + return logAndPropagateResult_zesDeviceResetOverclockSettings(driver_result, hDevice, onShippedState); } /////////////////////////////////////////////////////////////////////////////// @@ -862,12 +3715,12 @@ namespace validation_layer auto pfnReadOverclockState = context.zesDdiTable.Device.pfnReadOverclockState; if( nullptr == pfnReadOverclockState ) - return logAndPropagateResult("zesDeviceReadOverclockState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceReadOverclockState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceReadOverclockStatePrologue( hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReadOverclockState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReadOverclockState(result, hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset); } @@ -878,17 +3731,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceReadOverclockStatePrologue( hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReadOverclockState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReadOverclockState(result, hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset); } auto driver_result = pfnReadOverclockState( hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceReadOverclockStateEpilogue( hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceReadOverclockState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceReadOverclockState(result, hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset); } - return logAndPropagateResult("zesDeviceReadOverclockState", driver_result); + return logAndPropagateResult_zesDeviceReadOverclockState(driver_result, hDevice, pOverclockMode, pWaiverSetting, pOverclockState, pPendingAction, pPendingReset); } /////////////////////////////////////////////////////////////////////////////// @@ -914,12 +3767,12 @@ namespace validation_layer auto pfnEnumOverclockDomains = context.zesDdiTable.Device.pfnEnumOverclockDomains; if( nullptr == pfnEnumOverclockDomains ) - return logAndPropagateResult("zesDeviceEnumOverclockDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumOverclockDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phDomainHandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumOverclockDomainsPrologue( hDevice, pCount, phDomainHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumOverclockDomains(result, hDevice, pCount, phDomainHandle); } @@ -930,17 +3783,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumOverclockDomainsPrologue( hDevice, pCount, phDomainHandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumOverclockDomains(result, hDevice, pCount, phDomainHandle); } auto driver_result = pfnEnumOverclockDomains( hDevice, pCount, phDomainHandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumOverclockDomainsEpilogue( hDevice, pCount, phDomainHandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumOverclockDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumOverclockDomains(result, hDevice, pCount, phDomainHandle); } - return logAndPropagateResult("zesDeviceEnumOverclockDomains", driver_result); + return logAndPropagateResult_zesDeviceEnumOverclockDomains(driver_result, hDevice, pCount, phDomainHandle); } /////////////////////////////////////////////////////////////////////////////// @@ -956,12 +3809,12 @@ namespace validation_layer auto pfnGetDomainProperties = context.zesDdiTable.Overclock.pfnGetDomainProperties; if( nullptr == pfnGetDomainProperties ) - return logAndPropagateResult("zesOverclockGetDomainProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetDomainProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, pDomainProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainPropertiesPrologue( hDomainHandle, pDomainProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainProperties(result, hDomainHandle, pDomainProperties); } @@ -972,17 +3825,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetDomainPropertiesPrologue( hDomainHandle, pDomainProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainProperties(result, hDomainHandle, pDomainProperties); } auto driver_result = pfnGetDomainProperties( hDomainHandle, pDomainProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainPropertiesEpilogue( hDomainHandle, pDomainProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainProperties(result, hDomainHandle, pDomainProperties); } - return logAndPropagateResult("zesOverclockGetDomainProperties", driver_result); + return logAndPropagateResult_zesOverclockGetDomainProperties(driver_result, hDomainHandle, pDomainProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -998,12 +3851,12 @@ namespace validation_layer auto pfnGetDomainVFProperties = context.zesDdiTable.Overclock.pfnGetDomainVFProperties; if( nullptr == pfnGetDomainVFProperties ) - return logAndPropagateResult("zesOverclockGetDomainVFProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetDomainVFProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, pVFProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainVFPropertiesPrologue( hDomainHandle, pVFProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainVFProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainVFProperties(result, hDomainHandle, pVFProperties); } @@ -1014,17 +3867,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetDomainVFPropertiesPrologue( hDomainHandle, pVFProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainVFProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainVFProperties(result, hDomainHandle, pVFProperties); } auto driver_result = pfnGetDomainVFProperties( hDomainHandle, pVFProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainVFPropertiesEpilogue( hDomainHandle, pVFProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainVFProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainVFProperties(result, hDomainHandle, pVFProperties); } - return logAndPropagateResult("zesOverclockGetDomainVFProperties", driver_result); + return logAndPropagateResult_zesOverclockGetDomainVFProperties(driver_result, hDomainHandle, pVFProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1041,12 +3894,12 @@ namespace validation_layer auto pfnGetDomainControlProperties = context.zesDdiTable.Overclock.pfnGetDomainControlProperties; if( nullptr == pfnGetDomainControlProperties ) - return logAndPropagateResult("zesOverclockGetDomainControlProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetDomainControlProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, DomainControl, pControlProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainControlPropertiesPrologue( hDomainHandle, DomainControl, pControlProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainControlProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainControlProperties(result, hDomainHandle, DomainControl, pControlProperties); } @@ -1057,17 +3910,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetDomainControlPropertiesPrologue( hDomainHandle, DomainControl, pControlProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainControlProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainControlProperties(result, hDomainHandle, DomainControl, pControlProperties); } auto driver_result = pfnGetDomainControlProperties( hDomainHandle, DomainControl, pControlProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetDomainControlPropertiesEpilogue( hDomainHandle, DomainControl, pControlProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetDomainControlProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetDomainControlProperties(result, hDomainHandle, DomainControl, pControlProperties); } - return logAndPropagateResult("zesOverclockGetDomainControlProperties", driver_result); + return logAndPropagateResult_zesOverclockGetDomainControlProperties(driver_result, hDomainHandle, DomainControl, pControlProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1084,12 +3937,12 @@ namespace validation_layer auto pfnGetControlCurrentValue = context.zesDdiTable.Overclock.pfnGetControlCurrentValue; if( nullptr == pfnGetControlCurrentValue ) - return logAndPropagateResult("zesOverclockGetControlCurrentValue", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetControlCurrentValue(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, DomainControl, pValue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlCurrentValuePrologue( hDomainHandle, DomainControl, pValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlCurrentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlCurrentValue(result, hDomainHandle, DomainControl, pValue); } @@ -1100,17 +3953,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetControlCurrentValuePrologue( hDomainHandle, DomainControl, pValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlCurrentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlCurrentValue(result, hDomainHandle, DomainControl, pValue); } auto driver_result = pfnGetControlCurrentValue( hDomainHandle, DomainControl, pValue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlCurrentValueEpilogue( hDomainHandle, DomainControl, pValue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlCurrentValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlCurrentValue(result, hDomainHandle, DomainControl, pValue); } - return logAndPropagateResult("zesOverclockGetControlCurrentValue", driver_result); + return logAndPropagateResult_zesOverclockGetControlCurrentValue(driver_result, hDomainHandle, DomainControl, pValue); } /////////////////////////////////////////////////////////////////////////////// @@ -1128,12 +3981,12 @@ namespace validation_layer auto pfnGetControlPendingValue = context.zesDdiTable.Overclock.pfnGetControlPendingValue; if( nullptr == pfnGetControlPendingValue ) - return logAndPropagateResult("zesOverclockGetControlPendingValue", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetControlPendingValue(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, DomainControl, pValue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlPendingValuePrologue( hDomainHandle, DomainControl, pValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlPendingValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlPendingValue(result, hDomainHandle, DomainControl, pValue); } @@ -1144,17 +3997,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetControlPendingValuePrologue( hDomainHandle, DomainControl, pValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlPendingValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlPendingValue(result, hDomainHandle, DomainControl, pValue); } auto driver_result = pfnGetControlPendingValue( hDomainHandle, DomainControl, pValue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlPendingValueEpilogue( hDomainHandle, DomainControl, pValue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlPendingValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlPendingValue(result, hDomainHandle, DomainControl, pValue); } - return logAndPropagateResult("zesOverclockGetControlPendingValue", driver_result); + return logAndPropagateResult_zesOverclockGetControlPendingValue(driver_result, hDomainHandle, DomainControl, pValue); } /////////////////////////////////////////////////////////////////////////////// @@ -1173,12 +4026,12 @@ namespace validation_layer auto pfnSetControlUserValue = context.zesDdiTable.Overclock.pfnSetControlUserValue; if( nullptr == pfnSetControlUserValue ) - return logAndPropagateResult("zesOverclockSetControlUserValue", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockSetControlUserValue(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, DomainControl, pValue, pPendingAction); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockSetControlUserValuePrologue( hDomainHandle, DomainControl, pValue, pPendingAction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetControlUserValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetControlUserValue(result, hDomainHandle, DomainControl, pValue, pPendingAction); } @@ -1189,17 +4042,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockSetControlUserValuePrologue( hDomainHandle, DomainControl, pValue, pPendingAction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetControlUserValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetControlUserValue(result, hDomainHandle, DomainControl, pValue, pPendingAction); } auto driver_result = pfnSetControlUserValue( hDomainHandle, DomainControl, pValue, pPendingAction ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockSetControlUserValueEpilogue( hDomainHandle, DomainControl, pValue, pPendingAction ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetControlUserValue", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetControlUserValue(result, hDomainHandle, DomainControl, pValue, pPendingAction); } - return logAndPropagateResult("zesOverclockSetControlUserValue", driver_result); + return logAndPropagateResult_zesOverclockSetControlUserValue(driver_result, hDomainHandle, DomainControl, pValue, pPendingAction); } /////////////////////////////////////////////////////////////////////////////// @@ -1217,12 +4070,12 @@ namespace validation_layer auto pfnGetControlState = context.zesDdiTable.Overclock.pfnGetControlState; if( nullptr == pfnGetControlState ) - return logAndPropagateResult("zesOverclockGetControlState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetControlState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, DomainControl, pControlState, pPendingAction); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlStatePrologue( hDomainHandle, DomainControl, pControlState, pPendingAction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlState(result, hDomainHandle, DomainControl, pControlState, pPendingAction); } @@ -1233,17 +4086,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetControlStatePrologue( hDomainHandle, DomainControl, pControlState, pPendingAction ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlState(result, hDomainHandle, DomainControl, pControlState, pPendingAction); } auto driver_result = pfnGetControlState( hDomainHandle, DomainControl, pControlState, pPendingAction ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetControlStateEpilogue( hDomainHandle, DomainControl, pControlState, pPendingAction ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetControlState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetControlState(result, hDomainHandle, DomainControl, pControlState, pPendingAction); } - return logAndPropagateResult("zesOverclockGetControlState", driver_result); + return logAndPropagateResult_zesOverclockGetControlState(driver_result, hDomainHandle, DomainControl, pControlState, pPendingAction); } /////////////////////////////////////////////////////////////////////////////// @@ -1263,12 +4116,12 @@ namespace validation_layer auto pfnGetVFPointValues = context.zesDdiTable.Overclock.pfnGetVFPointValues; if( nullptr == pfnGetVFPointValues ) - return logAndPropagateResult("zesOverclockGetVFPointValues", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockGetVFPointValues(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, VFType, VFArrayType, PointIndex, PointValue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetVFPointValuesPrologue( hDomainHandle, VFType, VFArrayType, PointIndex, PointValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetVFPointValues(result, hDomainHandle, VFType, VFArrayType, PointIndex, PointValue); } @@ -1279,17 +4132,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockGetVFPointValuesPrologue( hDomainHandle, VFType, VFArrayType, PointIndex, PointValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetVFPointValues(result, hDomainHandle, VFType, VFArrayType, PointIndex, PointValue); } auto driver_result = pfnGetVFPointValues( hDomainHandle, VFType, VFArrayType, PointIndex, PointValue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockGetVFPointValuesEpilogue( hDomainHandle, VFType, VFArrayType, PointIndex, PointValue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockGetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockGetVFPointValues(result, hDomainHandle, VFType, VFArrayType, PointIndex, PointValue); } - return logAndPropagateResult("zesOverclockGetVFPointValues", driver_result); + return logAndPropagateResult_zesOverclockGetVFPointValues(driver_result, hDomainHandle, VFType, VFArrayType, PointIndex, PointValue); } /////////////////////////////////////////////////////////////////////////////// @@ -1308,12 +4161,12 @@ namespace validation_layer auto pfnSetVFPointValues = context.zesDdiTable.Overclock.pfnSetVFPointValues; if( nullptr == pfnSetVFPointValues ) - return logAndPropagateResult("zesOverclockSetVFPointValues", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesOverclockSetVFPointValues(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDomainHandle, VFType, PointIndex, PointValue); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockSetVFPointValuesPrologue( hDomainHandle, VFType, PointIndex, PointValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetVFPointValues(result, hDomainHandle, VFType, PointIndex, PointValue); } @@ -1324,17 +4177,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesOverclockSetVFPointValuesPrologue( hDomainHandle, VFType, PointIndex, PointValue ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetVFPointValues(result, hDomainHandle, VFType, PointIndex, PointValue); } auto driver_result = pfnSetVFPointValues( hDomainHandle, VFType, PointIndex, PointValue ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesOverclockSetVFPointValuesEpilogue( hDomainHandle, VFType, PointIndex, PointValue ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesOverclockSetVFPointValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesOverclockSetVFPointValues(result, hDomainHandle, VFType, PointIndex, PointValue); } - return logAndPropagateResult("zesOverclockSetVFPointValues", driver_result); + return logAndPropagateResult_zesOverclockSetVFPointValues(driver_result, hDomainHandle, VFType, PointIndex, PointValue); } /////////////////////////////////////////////////////////////////////////////// @@ -1360,12 +4213,12 @@ namespace validation_layer auto pfnEnumDiagnosticTestSuites = context.zesDdiTable.Device.pfnEnumDiagnosticTestSuites; if( nullptr == pfnEnumDiagnosticTestSuites ) - return logAndPropagateResult("zesDeviceEnumDiagnosticTestSuites", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phDiagnostics); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumDiagnosticTestSuitesPrologue( hDevice, pCount, phDiagnostics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumDiagnosticTestSuites", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites(result, hDevice, pCount, phDiagnostics); } @@ -1376,17 +4229,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumDiagnosticTestSuitesPrologue( hDevice, pCount, phDiagnostics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumDiagnosticTestSuites", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites(result, hDevice, pCount, phDiagnostics); } auto driver_result = pfnEnumDiagnosticTestSuites( hDevice, pCount, phDiagnostics ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumDiagnosticTestSuitesEpilogue( hDevice, pCount, phDiagnostics ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumDiagnosticTestSuites", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites(result, hDevice, pCount, phDiagnostics); } - return logAndPropagateResult("zesDeviceEnumDiagnosticTestSuites", driver_result); + return logAndPropagateResult_zesDeviceEnumDiagnosticTestSuites(driver_result, hDevice, pCount, phDiagnostics); } /////////////////////////////////////////////////////////////////////////////// @@ -1403,12 +4256,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Diagnostics.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesDiagnosticsGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDiagnosticsGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDiagnostics, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsGetPropertiesPrologue( hDiagnostics, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetProperties(result, hDiagnostics, pProperties); } @@ -1419,17 +4272,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDiagnosticsGetPropertiesPrologue( hDiagnostics, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetProperties(result, hDiagnostics, pProperties); } auto driver_result = pfnGetProperties( hDiagnostics, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsGetPropertiesEpilogue( hDiagnostics, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetProperties(result, hDiagnostics, pProperties); } - return logAndPropagateResult("zesDiagnosticsGetProperties", driver_result); + return logAndPropagateResult_zesDiagnosticsGetProperties(driver_result, hDiagnostics, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1453,12 +4306,12 @@ namespace validation_layer auto pfnGetTests = context.zesDdiTable.Diagnostics.pfnGetTests; if( nullptr == pfnGetTests ) - return logAndPropagateResult("zesDiagnosticsGetTests", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDiagnosticsGetTests(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDiagnostics, pCount, pTests); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsGetTestsPrologue( hDiagnostics, pCount, pTests ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetTests(result, hDiagnostics, pCount, pTests); } @@ -1469,17 +4322,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDiagnosticsGetTestsPrologue( hDiagnostics, pCount, pTests ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetTests(result, hDiagnostics, pCount, pTests); } auto driver_result = pfnGetTests( hDiagnostics, pCount, pTests ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsGetTestsEpilogue( hDiagnostics, pCount, pTests ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsGetTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsGetTests(result, hDiagnostics, pCount, pTests); } - return logAndPropagateResult("zesDiagnosticsGetTests", driver_result); + return logAndPropagateResult_zesDiagnosticsGetTests(driver_result, hDiagnostics, pCount, pTests); } /////////////////////////////////////////////////////////////////////////////// @@ -1499,12 +4352,12 @@ namespace validation_layer auto pfnRunTests = context.zesDdiTable.Diagnostics.pfnRunTests; if( nullptr == pfnRunTests ) - return logAndPropagateResult("zesDiagnosticsRunTests", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDiagnosticsRunTests(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDiagnostics, startIndex, endIndex, pResult); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsRunTestsPrologue( hDiagnostics, startIndex, endIndex, pResult ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsRunTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsRunTests(result, hDiagnostics, startIndex, endIndex, pResult); } @@ -1515,17 +4368,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDiagnosticsRunTestsPrologue( hDiagnostics, startIndex, endIndex, pResult ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsRunTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsRunTests(result, hDiagnostics, startIndex, endIndex, pResult); } auto driver_result = pfnRunTests( hDiagnostics, startIndex, endIndex, pResult ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDiagnosticsRunTestsEpilogue( hDiagnostics, startIndex, endIndex, pResult ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDiagnosticsRunTests", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDiagnosticsRunTests(result, hDiagnostics, startIndex, endIndex, pResult); } - return logAndPropagateResult("zesDiagnosticsRunTests", driver_result); + return logAndPropagateResult_zesDiagnosticsRunTests(driver_result, hDiagnostics, startIndex, endIndex, pResult); } /////////////////////////////////////////////////////////////////////////////// @@ -1541,12 +4394,12 @@ namespace validation_layer auto pfnEccAvailable = context.zesDdiTable.Device.pfnEccAvailable; if( nullptr == pfnEccAvailable ) - return logAndPropagateResult("zesDeviceEccAvailable", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEccAvailable(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pAvailable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEccAvailablePrologue( hDevice, pAvailable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccAvailable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccAvailable(result, hDevice, pAvailable); } @@ -1557,17 +4410,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEccAvailablePrologue( hDevice, pAvailable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccAvailable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccAvailable(result, hDevice, pAvailable); } auto driver_result = pfnEccAvailable( hDevice, pAvailable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEccAvailableEpilogue( hDevice, pAvailable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccAvailable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccAvailable(result, hDevice, pAvailable); } - return logAndPropagateResult("zesDeviceEccAvailable", driver_result); + return logAndPropagateResult_zesDeviceEccAvailable(driver_result, hDevice, pAvailable); } /////////////////////////////////////////////////////////////////////////////// @@ -1583,12 +4436,12 @@ namespace validation_layer auto pfnEccConfigurable = context.zesDdiTable.Device.pfnEccConfigurable; if( nullptr == pfnEccConfigurable ) - return logAndPropagateResult("zesDeviceEccConfigurable", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEccConfigurable(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pConfigurable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEccConfigurablePrologue( hDevice, pConfigurable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccConfigurable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccConfigurable(result, hDevice, pConfigurable); } @@ -1599,17 +4452,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEccConfigurablePrologue( hDevice, pConfigurable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccConfigurable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccConfigurable(result, hDevice, pConfigurable); } auto driver_result = pfnEccConfigurable( hDevice, pConfigurable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEccConfigurableEpilogue( hDevice, pConfigurable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEccConfigurable", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEccConfigurable(result, hDevice, pConfigurable); } - return logAndPropagateResult("zesDeviceEccConfigurable", driver_result); + return logAndPropagateResult_zesDeviceEccConfigurable(driver_result, hDevice, pConfigurable); } /////////////////////////////////////////////////////////////////////////////// @@ -1625,12 +4478,12 @@ namespace validation_layer auto pfnGetEccState = context.zesDdiTable.Device.pfnGetEccState; if( nullptr == pfnGetEccState ) - return logAndPropagateResult("zesDeviceGetEccState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetEccState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetEccStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetEccState(result, hDevice, pState); } @@ -1641,17 +4494,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetEccStatePrologue( hDevice, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetEccState(result, hDevice, pState); } auto driver_result = pfnGetEccState( hDevice, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetEccStateEpilogue( hDevice, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetEccState(result, hDevice, pState); } - return logAndPropagateResult("zesDeviceGetEccState", driver_result); + return logAndPropagateResult_zesDeviceGetEccState(driver_result, hDevice, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -1668,12 +4521,12 @@ namespace validation_layer auto pfnSetEccState = context.zesDdiTable.Device.pfnSetEccState; if( nullptr == pfnSetEccState ) - return logAndPropagateResult("zesDeviceSetEccState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceSetEccState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, newState, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceSetEccStatePrologue( hDevice, newState, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetEccState(result, hDevice, newState, pState); } @@ -1684,17 +4537,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceSetEccStatePrologue( hDevice, newState, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetEccState(result, hDevice, newState, pState); } auto driver_result = pfnSetEccState( hDevice, newState, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceSetEccStateEpilogue( hDevice, newState, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceSetEccState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceSetEccState(result, hDevice, newState, pState); } - return logAndPropagateResult("zesDeviceSetEccState", driver_result); + return logAndPropagateResult_zesDeviceSetEccState(driver_result, hDevice, newState, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -1720,12 +4573,12 @@ namespace validation_layer auto pfnEnumEngineGroups = context.zesDdiTable.Device.pfnEnumEngineGroups; if( nullptr == pfnEnumEngineGroups ) - return logAndPropagateResult("zesDeviceEnumEngineGroups", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumEngineGroups(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phEngine); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumEngineGroupsPrologue( hDevice, pCount, phEngine ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEngineGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEngineGroups(result, hDevice, pCount, phEngine); } @@ -1736,17 +4589,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumEngineGroupsPrologue( hDevice, pCount, phEngine ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEngineGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEngineGroups(result, hDevice, pCount, phEngine); } auto driver_result = pfnEnumEngineGroups( hDevice, pCount, phEngine ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumEngineGroupsEpilogue( hDevice, pCount, phEngine ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEngineGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEngineGroups(result, hDevice, pCount, phEngine); } - return logAndPropagateResult("zesDeviceEnumEngineGroups", driver_result); + return logAndPropagateResult_zesDeviceEnumEngineGroups(driver_result, hDevice, pCount, phEngine); } /////////////////////////////////////////////////////////////////////////////// @@ -1762,12 +4615,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Engine.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesEngineGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesEngineGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEngine, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetPropertiesPrologue( hEngine, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetProperties(result, hEngine, pProperties); } @@ -1778,17 +4631,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesEngineGetPropertiesPrologue( hEngine, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetProperties(result, hEngine, pProperties); } auto driver_result = pfnGetProperties( hEngine, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetPropertiesEpilogue( hEngine, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetProperties(result, hEngine, pProperties); } - return logAndPropagateResult("zesEngineGetProperties", driver_result); + return logAndPropagateResult_zesEngineGetProperties(driver_result, hEngine, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1805,12 +4658,12 @@ namespace validation_layer auto pfnGetActivity = context.zesDdiTable.Engine.pfnGetActivity; if( nullptr == pfnGetActivity ) - return logAndPropagateResult("zesEngineGetActivity", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesEngineGetActivity(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEngine, pStats); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetActivityPrologue( hEngine, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivity", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivity(result, hEngine, pStats); } @@ -1821,17 +4674,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesEngineGetActivityPrologue( hEngine, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivity", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivity(result, hEngine, pStats); } auto driver_result = pfnGetActivity( hEngine, pStats ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetActivityEpilogue( hEngine, pStats ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivity", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivity(result, hEngine, pStats); } - return logAndPropagateResult("zesEngineGetActivity", driver_result); + return logAndPropagateResult_zesEngineGetActivity(driver_result, hEngine, pStats); } /////////////////////////////////////////////////////////////////////////////// @@ -1847,12 +4700,12 @@ namespace validation_layer auto pfnEventRegister = context.zesDdiTable.Device.pfnEventRegister; if( nullptr == pfnEventRegister ) - return logAndPropagateResult("zesDeviceEventRegister", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEventRegister(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, events); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEventRegisterPrologue( hDevice, events ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEventRegister", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEventRegister(result, hDevice, events); } @@ -1863,17 +4716,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEventRegisterPrologue( hDevice, events ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEventRegister", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEventRegister(result, hDevice, events); } auto driver_result = pfnEventRegister( hDevice, events ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEventRegisterEpilogue( hDevice, events ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEventRegister", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEventRegister(result, hDevice, events); } - return logAndPropagateResult("zesDeviceEventRegister", driver_result); + return logAndPropagateResult_zesDeviceEventRegister(driver_result, hDevice, events); } /////////////////////////////////////////////////////////////////////////////// @@ -1905,12 +4758,12 @@ namespace validation_layer auto pfnEventListen = context.zesDdiTable.Driver.pfnEventListen; if( nullptr == pfnEventListen ) - return logAndPropagateResult("zesDriverEventListen", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverEventListen(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverEventListenPrologue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListen(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } @@ -1921,17 +4774,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverEventListenPrologue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListen(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } auto driver_result = pfnEventListen( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverEventListenEpilogue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListen(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } - return logAndPropagateResult("zesDriverEventListen", driver_result); + return logAndPropagateResult_zesDriverEventListen(driver_result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -1963,12 +4816,12 @@ namespace validation_layer auto pfnEventListenEx = context.zesDdiTable.Driver.pfnEventListenEx; if( nullptr == pfnEventListenEx ) - return logAndPropagateResult("zesDriverEventListenEx", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverEventListenEx(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverEventListenExPrologue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListenEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListenEx(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } @@ -1979,17 +4832,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverEventListenExPrologue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListenEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListenEx(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } auto driver_result = pfnEventListenEx( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverEventListenExEpilogue( hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverEventListenEx", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverEventListenEx(result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } - return logAndPropagateResult("zesDriverEventListenEx", driver_result); + return logAndPropagateResult_zesDriverEventListenEx(driver_result, hDriver, timeout, count, phDevices, pNumDeviceEvents, pEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -2015,12 +4868,12 @@ namespace validation_layer auto pfnEnumFabricPorts = context.zesDdiTable.Device.pfnEnumFabricPorts; if( nullptr == pfnEnumFabricPorts ) - return logAndPropagateResult("zesDeviceEnumFabricPorts", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumFabricPorts(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phPort); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFabricPortsPrologue( hDevice, pCount, phPort ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFabricPorts", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFabricPorts(result, hDevice, pCount, phPort); } @@ -2031,17 +4884,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumFabricPortsPrologue( hDevice, pCount, phPort ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFabricPorts", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFabricPorts(result, hDevice, pCount, phPort); } auto driver_result = pfnEnumFabricPorts( hDevice, pCount, phPort ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFabricPortsEpilogue( hDevice, pCount, phPort ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFabricPorts", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFabricPorts(result, hDevice, pCount, phPort); } - return logAndPropagateResult("zesDeviceEnumFabricPorts", driver_result); + return logAndPropagateResult_zesDeviceEnumFabricPorts(driver_result, hDevice, pCount, phPort); } /////////////////////////////////////////////////////////////////////////////// @@ -2057,12 +4910,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.FabricPort.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesFabricPortGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetPropertiesPrologue( hPort, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetProperties(result, hPort, pProperties); } @@ -2073,17 +4926,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetPropertiesPrologue( hPort, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetProperties(result, hPort, pProperties); } auto driver_result = pfnGetProperties( hPort, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetPropertiesEpilogue( hPort, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetProperties(result, hPort, pProperties); } - return logAndPropagateResult("zesFabricPortGetProperties", driver_result); + return logAndPropagateResult_zesFabricPortGetProperties(driver_result, hPort, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -2100,12 +4953,12 @@ namespace validation_layer auto pfnGetLinkType = context.zesDdiTable.FabricPort.pfnGetLinkType; if( nullptr == pfnGetLinkType ) - return logAndPropagateResult("zesFabricPortGetLinkType", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetLinkType(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pLinkType); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetLinkTypePrologue( hPort, pLinkType ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetLinkType", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetLinkType(result, hPort, pLinkType); } @@ -2116,17 +4969,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetLinkTypePrologue( hPort, pLinkType ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetLinkType", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetLinkType(result, hPort, pLinkType); } auto driver_result = pfnGetLinkType( hPort, pLinkType ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetLinkTypeEpilogue( hPort, pLinkType ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetLinkType", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetLinkType(result, hPort, pLinkType); } - return logAndPropagateResult("zesFabricPortGetLinkType", driver_result); + return logAndPropagateResult_zesFabricPortGetLinkType(driver_result, hPort, pLinkType); } /////////////////////////////////////////////////////////////////////////////// @@ -2142,12 +4995,12 @@ namespace validation_layer auto pfnGetConfig = context.zesDdiTable.FabricPort.pfnGetConfig; if( nullptr == pfnGetConfig ) - return logAndPropagateResult("zesFabricPortGetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetConfigPrologue( hPort, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetConfig(result, hPort, pConfig); } @@ -2158,17 +5011,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetConfigPrologue( hPort, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetConfig(result, hPort, pConfig); } auto driver_result = pfnGetConfig( hPort, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetConfigEpilogue( hPort, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetConfig(result, hPort, pConfig); } - return logAndPropagateResult("zesFabricPortGetConfig", driver_result); + return logAndPropagateResult_zesFabricPortGetConfig(driver_result, hPort, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -2184,12 +5037,12 @@ namespace validation_layer auto pfnSetConfig = context.zesDdiTable.FabricPort.pfnSetConfig; if( nullptr == pfnSetConfig ) - return logAndPropagateResult("zesFabricPortSetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortSetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortSetConfigPrologue( hPort, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortSetConfig(result, hPort, pConfig); } @@ -2200,17 +5053,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortSetConfigPrologue( hPort, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortSetConfig(result, hPort, pConfig); } auto driver_result = pfnSetConfig( hPort, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortSetConfigEpilogue( hPort, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortSetConfig(result, hPort, pConfig); } - return logAndPropagateResult("zesFabricPortSetConfig", driver_result); + return logAndPropagateResult_zesFabricPortSetConfig(driver_result, hPort, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -2226,12 +5079,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.FabricPort.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesFabricPortGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetStatePrologue( hPort, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetState(result, hPort, pState); } @@ -2242,17 +5095,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetStatePrologue( hPort, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetState(result, hPort, pState); } auto driver_result = pfnGetState( hPort, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetStateEpilogue( hPort, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetState(result, hPort, pState); } - return logAndPropagateResult("zesFabricPortGetState", driver_result); + return logAndPropagateResult_zesFabricPortGetState(driver_result, hPort, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -2268,12 +5121,12 @@ namespace validation_layer auto pfnGetThroughput = context.zesDdiTable.FabricPort.pfnGetThroughput; if( nullptr == pfnGetThroughput ) - return logAndPropagateResult("zesFabricPortGetThroughput", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetThroughput(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pThroughput); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetThroughputPrologue( hPort, pThroughput ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetThroughput(result, hPort, pThroughput); } @@ -2284,17 +5137,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetThroughputPrologue( hPort, pThroughput ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetThroughput(result, hPort, pThroughput); } auto driver_result = pfnGetThroughput( hPort, pThroughput ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetThroughputEpilogue( hPort, pThroughput ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetThroughput(result, hPort, pThroughput); } - return logAndPropagateResult("zesFabricPortGetThroughput", driver_result); + return logAndPropagateResult_zesFabricPortGetThroughput(driver_result, hPort, pThroughput); } /////////////////////////////////////////////////////////////////////////////// @@ -2310,12 +5163,12 @@ namespace validation_layer auto pfnGetFabricErrorCounters = context.zesDdiTable.FabricPort.pfnGetFabricErrorCounters; if( nullptr == pfnGetFabricErrorCounters ) - return logAndPropagateResult("zesFabricPortGetFabricErrorCounters", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetFabricErrorCounters(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPort, pErrors); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetFabricErrorCountersPrologue( hPort, pErrors ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetFabricErrorCounters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetFabricErrorCounters(result, hPort, pErrors); } @@ -2326,17 +5179,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetFabricErrorCountersPrologue( hPort, pErrors ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetFabricErrorCounters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetFabricErrorCounters(result, hPort, pErrors); } auto driver_result = pfnGetFabricErrorCounters( hPort, pErrors ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetFabricErrorCountersEpilogue( hPort, pErrors ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetFabricErrorCounters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetFabricErrorCounters(result, hPort, pErrors); } - return logAndPropagateResult("zesFabricPortGetFabricErrorCounters", driver_result); + return logAndPropagateResult_zesFabricPortGetFabricErrorCounters(driver_result, hPort, pErrors); } /////////////////////////////////////////////////////////////////////////////// @@ -2356,12 +5209,12 @@ namespace validation_layer auto pfnGetMultiPortThroughput = context.zesDdiTable.FabricPort.pfnGetMultiPortThroughput; if( nullptr == pfnGetMultiPortThroughput ) - return logAndPropagateResult("zesFabricPortGetMultiPortThroughput", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFabricPortGetMultiPortThroughput(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, numPorts, phPort, pThroughput); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetMultiPortThroughputPrologue( hDevice, numPorts, phPort, pThroughput ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetMultiPortThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetMultiPortThroughput(result, hDevice, numPorts, phPort, pThroughput); } @@ -2372,17 +5225,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFabricPortGetMultiPortThroughputPrologue( hDevice, numPorts, phPort, pThroughput ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetMultiPortThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetMultiPortThroughput(result, hDevice, numPorts, phPort, pThroughput); } auto driver_result = pfnGetMultiPortThroughput( hDevice, numPorts, phPort, pThroughput ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFabricPortGetMultiPortThroughputEpilogue( hDevice, numPorts, phPort, pThroughput ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFabricPortGetMultiPortThroughput", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFabricPortGetMultiPortThroughput(result, hDevice, numPorts, phPort, pThroughput); } - return logAndPropagateResult("zesFabricPortGetMultiPortThroughput", driver_result); + return logAndPropagateResult_zesFabricPortGetMultiPortThroughput(driver_result, hDevice, numPorts, phPort, pThroughput); } /////////////////////////////////////////////////////////////////////////////// @@ -2408,12 +5261,12 @@ namespace validation_layer auto pfnEnumFans = context.zesDdiTable.Device.pfnEnumFans; if( nullptr == pfnEnumFans ) - return logAndPropagateResult("zesDeviceEnumFans", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumFans(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phFan); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFansPrologue( hDevice, pCount, phFan ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFans", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFans(result, hDevice, pCount, phFan); } @@ -2424,17 +5277,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumFansPrologue( hDevice, pCount, phFan ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFans", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFans(result, hDevice, pCount, phFan); } auto driver_result = pfnEnumFans( hDevice, pCount, phFan ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFansEpilogue( hDevice, pCount, phFan ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFans", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFans(result, hDevice, pCount, phFan); } - return logAndPropagateResult("zesDeviceEnumFans", driver_result); + return logAndPropagateResult_zesDeviceEnumFans(driver_result, hDevice, pCount, phFan); } /////////////////////////////////////////////////////////////////////////////// @@ -2450,12 +5303,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Fan.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesFanGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetPropertiesPrologue( hFan, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetProperties(result, hFan, pProperties); } @@ -2466,17 +5319,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanGetPropertiesPrologue( hFan, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetProperties(result, hFan, pProperties); } auto driver_result = pfnGetProperties( hFan, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetPropertiesEpilogue( hFan, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetProperties(result, hFan, pProperties); } - return logAndPropagateResult("zesFanGetProperties", driver_result); + return logAndPropagateResult_zesFanGetProperties(driver_result, hFan, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -2492,12 +5345,12 @@ namespace validation_layer auto pfnGetConfig = context.zesDdiTable.Fan.pfnGetConfig; if( nullptr == pfnGetConfig ) - return logAndPropagateResult("zesFanGetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanGetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetConfigPrologue( hFan, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetConfig(result, hFan, pConfig); } @@ -2508,17 +5361,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanGetConfigPrologue( hFan, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetConfig(result, hFan, pConfig); } auto driver_result = pfnGetConfig( hFan, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetConfigEpilogue( hFan, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetConfig(result, hFan, pConfig); } - return logAndPropagateResult("zesFanGetConfig", driver_result); + return logAndPropagateResult_zesFanGetConfig(driver_result, hFan, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -2533,12 +5386,12 @@ namespace validation_layer auto pfnSetDefaultMode = context.zesDdiTable.Fan.pfnSetDefaultMode; if( nullptr == pfnSetDefaultMode ) - return logAndPropagateResult("zesFanSetDefaultMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanSetDefaultMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetDefaultModePrologue( hFan ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetDefaultMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetDefaultMode(result, hFan); } @@ -2549,17 +5402,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanSetDefaultModePrologue( hFan ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetDefaultMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetDefaultMode(result, hFan); } auto driver_result = pfnSetDefaultMode( hFan ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetDefaultModeEpilogue( hFan ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetDefaultMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetDefaultMode(result, hFan); } - return logAndPropagateResult("zesFanSetDefaultMode", driver_result); + return logAndPropagateResult_zesFanSetDefaultMode(driver_result, hFan); } /////////////////////////////////////////////////////////////////////////////// @@ -2575,12 +5428,12 @@ namespace validation_layer auto pfnSetFixedSpeedMode = context.zesDdiTable.Fan.pfnSetFixedSpeedMode; if( nullptr == pfnSetFixedSpeedMode ) - return logAndPropagateResult("zesFanSetFixedSpeedMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanSetFixedSpeedMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan, speed); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetFixedSpeedModePrologue( hFan, speed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetFixedSpeedMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetFixedSpeedMode(result, hFan, speed); } @@ -2591,17 +5444,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanSetFixedSpeedModePrologue( hFan, speed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetFixedSpeedMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetFixedSpeedMode(result, hFan, speed); } auto driver_result = pfnSetFixedSpeedMode( hFan, speed ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetFixedSpeedModeEpilogue( hFan, speed ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetFixedSpeedMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetFixedSpeedMode(result, hFan, speed); } - return logAndPropagateResult("zesFanSetFixedSpeedMode", driver_result); + return logAndPropagateResult_zesFanSetFixedSpeedMode(driver_result, hFan, speed); } /////////////////////////////////////////////////////////////////////////////// @@ -2617,12 +5470,12 @@ namespace validation_layer auto pfnSetSpeedTableMode = context.zesDdiTable.Fan.pfnSetSpeedTableMode; if( nullptr == pfnSetSpeedTableMode ) - return logAndPropagateResult("zesFanSetSpeedTableMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanSetSpeedTableMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan, speedTable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetSpeedTableModePrologue( hFan, speedTable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetSpeedTableMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetSpeedTableMode(result, hFan, speedTable); } @@ -2633,17 +5486,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanSetSpeedTableModePrologue( hFan, speedTable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetSpeedTableMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetSpeedTableMode(result, hFan, speedTable); } auto driver_result = pfnSetSpeedTableMode( hFan, speedTable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanSetSpeedTableModeEpilogue( hFan, speedTable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanSetSpeedTableMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanSetSpeedTableMode(result, hFan, speedTable); } - return logAndPropagateResult("zesFanSetSpeedTableMode", driver_result); + return logAndPropagateResult_zesFanSetSpeedTableMode(driver_result, hFan, speedTable); } /////////////////////////////////////////////////////////////////////////////// @@ -2662,12 +5515,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Fan.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesFanGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFanGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFan, units, pSpeed); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetStatePrologue( hFan, units, pSpeed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetState(result, hFan, units, pSpeed); } @@ -2678,17 +5531,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFanGetStatePrologue( hFan, units, pSpeed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetState(result, hFan, units, pSpeed); } auto driver_result = pfnGetState( hFan, units, pSpeed ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFanGetStateEpilogue( hFan, units, pSpeed ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFanGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFanGetState(result, hFan, units, pSpeed); } - return logAndPropagateResult("zesFanGetState", driver_result); + return logAndPropagateResult_zesFanGetState(driver_result, hFan, units, pSpeed); } /////////////////////////////////////////////////////////////////////////////// @@ -2714,12 +5567,12 @@ namespace validation_layer auto pfnEnumFirmwares = context.zesDdiTable.Device.pfnEnumFirmwares; if( nullptr == pfnEnumFirmwares ) - return logAndPropagateResult("zesDeviceEnumFirmwares", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumFirmwares(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phFirmware); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFirmwaresPrologue( hDevice, pCount, phFirmware ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFirmwares", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFirmwares(result, hDevice, pCount, phFirmware); } @@ -2730,17 +5583,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumFirmwaresPrologue( hDevice, pCount, phFirmware ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFirmwares", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFirmwares(result, hDevice, pCount, phFirmware); } auto driver_result = pfnEnumFirmwares( hDevice, pCount, phFirmware ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFirmwaresEpilogue( hDevice, pCount, phFirmware ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFirmwares", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFirmwares(result, hDevice, pCount, phFirmware); } - return logAndPropagateResult("zesDeviceEnumFirmwares", driver_result); + return logAndPropagateResult_zesDeviceEnumFirmwares(driver_result, hDevice, pCount, phFirmware); } /////////////////////////////////////////////////////////////////////////////// @@ -2757,12 +5610,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Firmware.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesFirmwareGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetPropertiesPrologue( hFirmware, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetProperties(result, hFirmware, pProperties); } @@ -2773,17 +5626,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareGetPropertiesPrologue( hFirmware, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetProperties(result, hFirmware, pProperties); } auto driver_result = pfnGetProperties( hFirmware, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetPropertiesEpilogue( hFirmware, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetProperties(result, hFirmware, pProperties); } - return logAndPropagateResult("zesFirmwareGetProperties", driver_result); + return logAndPropagateResult_zesFirmwareGetProperties(driver_result, hFirmware, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -2800,12 +5653,12 @@ namespace validation_layer auto pfnFlash = context.zesDdiTable.Firmware.pfnFlash; if( nullptr == pfnFlash ) - return logAndPropagateResult("zesFirmwareFlash", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareFlash(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware, pImage, size); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareFlashPrologue( hFirmware, pImage, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareFlash", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareFlash(result, hFirmware, pImage, size); } @@ -2816,17 +5669,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareFlashPrologue( hFirmware, pImage, size ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareFlash", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareFlash(result, hFirmware, pImage, size); } auto driver_result = pfnFlash( hFirmware, pImage, size ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareFlashEpilogue( hFirmware, pImage, size ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareFlash", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareFlash(result, hFirmware, pImage, size); } - return logAndPropagateResult("zesFirmwareFlash", driver_result); + return logAndPropagateResult_zesFirmwareFlash(driver_result, hFirmware, pImage, size); } /////////////////////////////////////////////////////////////////////////////// @@ -2842,12 +5695,12 @@ namespace validation_layer auto pfnGetFlashProgress = context.zesDdiTable.Firmware.pfnGetFlashProgress; if( nullptr == pfnGetFlashProgress ) - return logAndPropagateResult("zesFirmwareGetFlashProgress", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareGetFlashProgress(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware, pCompletionPercent); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetFlashProgressPrologue( hFirmware, pCompletionPercent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetFlashProgress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetFlashProgress(result, hFirmware, pCompletionPercent); } @@ -2858,17 +5711,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareGetFlashProgressPrologue( hFirmware, pCompletionPercent ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetFlashProgress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetFlashProgress(result, hFirmware, pCompletionPercent); } auto driver_result = pfnGetFlashProgress( hFirmware, pCompletionPercent ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetFlashProgressEpilogue( hFirmware, pCompletionPercent ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetFlashProgress", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetFlashProgress(result, hFirmware, pCompletionPercent); } - return logAndPropagateResult("zesFirmwareGetFlashProgress", driver_result); + return logAndPropagateResult_zesFirmwareGetFlashProgress(driver_result, hFirmware, pCompletionPercent); } /////////////////////////////////////////////////////////////////////////////// @@ -2885,12 +5738,12 @@ namespace validation_layer auto pfnGetConsoleLogs = context.zesDdiTable.Firmware.pfnGetConsoleLogs; if( nullptr == pfnGetConsoleLogs ) - return logAndPropagateResult("zesFirmwareGetConsoleLogs", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareGetConsoleLogs(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware, pSize, pFirmwareLog); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetConsoleLogsPrologue( hFirmware, pSize, pFirmwareLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetConsoleLogs", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetConsoleLogs(result, hFirmware, pSize, pFirmwareLog); } @@ -2901,17 +5754,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareGetConsoleLogsPrologue( hFirmware, pSize, pFirmwareLog ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetConsoleLogs", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetConsoleLogs(result, hFirmware, pSize, pFirmwareLog); } auto driver_result = pfnGetConsoleLogs( hFirmware, pSize, pFirmwareLog ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetConsoleLogsEpilogue( hFirmware, pSize, pFirmwareLog ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetConsoleLogs", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetConsoleLogs(result, hFirmware, pSize, pFirmwareLog); } - return logAndPropagateResult("zesFirmwareGetConsoleLogs", driver_result); + return logAndPropagateResult_zesFirmwareGetConsoleLogs(driver_result, hFirmware, pSize, pFirmwareLog); } /////////////////////////////////////////////////////////////////////////////// @@ -2937,12 +5790,12 @@ namespace validation_layer auto pfnEnumFrequencyDomains = context.zesDdiTable.Device.pfnEnumFrequencyDomains; if( nullptr == pfnEnumFrequencyDomains ) - return logAndPropagateResult("zesDeviceEnumFrequencyDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumFrequencyDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phFrequency); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFrequencyDomainsPrologue( hDevice, pCount, phFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFrequencyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFrequencyDomains(result, hDevice, pCount, phFrequency); } @@ -2953,17 +5806,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumFrequencyDomainsPrologue( hDevice, pCount, phFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFrequencyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFrequencyDomains(result, hDevice, pCount, phFrequency); } auto driver_result = pfnEnumFrequencyDomains( hDevice, pCount, phFrequency ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumFrequencyDomainsEpilogue( hDevice, pCount, phFrequency ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumFrequencyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumFrequencyDomains(result, hDevice, pCount, phFrequency); } - return logAndPropagateResult("zesDeviceEnumFrequencyDomains", driver_result); + return logAndPropagateResult_zesDeviceEnumFrequencyDomains(driver_result, hDevice, pCount, phFrequency); } /////////////////////////////////////////////////////////////////////////////// @@ -2979,12 +5832,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Frequency.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesFrequencyGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetPropertiesPrologue( hFrequency, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetProperties(result, hFrequency, pProperties); } @@ -2995,17 +5848,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyGetPropertiesPrologue( hFrequency, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetProperties(result, hFrequency, pProperties); } auto driver_result = pfnGetProperties( hFrequency, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetPropertiesEpilogue( hFrequency, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetProperties(result, hFrequency, pProperties); } - return logAndPropagateResult("zesFrequencyGetProperties", driver_result); + return logAndPropagateResult_zesFrequencyGetProperties(driver_result, hFrequency, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -3029,12 +5882,12 @@ namespace validation_layer auto pfnGetAvailableClocks = context.zesDdiTable.Frequency.pfnGetAvailableClocks; if( nullptr == pfnGetAvailableClocks ) - return logAndPropagateResult("zesFrequencyGetAvailableClocks", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyGetAvailableClocks(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pCount, phFrequency); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetAvailableClocksPrologue( hFrequency, pCount, phFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetAvailableClocks", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetAvailableClocks(result, hFrequency, pCount, phFrequency); } @@ -3045,17 +5898,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyGetAvailableClocksPrologue( hFrequency, pCount, phFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetAvailableClocks", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetAvailableClocks(result, hFrequency, pCount, phFrequency); } auto driver_result = pfnGetAvailableClocks( hFrequency, pCount, phFrequency ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetAvailableClocksEpilogue( hFrequency, pCount, phFrequency ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetAvailableClocks", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetAvailableClocks(result, hFrequency, pCount, phFrequency); } - return logAndPropagateResult("zesFrequencyGetAvailableClocks", driver_result); + return logAndPropagateResult_zesFrequencyGetAvailableClocks(driver_result, hFrequency, pCount, phFrequency); } /////////////////////////////////////////////////////////////////////////////// @@ -3072,12 +5925,12 @@ namespace validation_layer auto pfnGetRange = context.zesDdiTable.Frequency.pfnGetRange; if( nullptr == pfnGetRange ) - return logAndPropagateResult("zesFrequencyGetRange", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyGetRange(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pLimits); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetRangePrologue( hFrequency, pLimits ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetRange(result, hFrequency, pLimits); } @@ -3088,17 +5941,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyGetRangePrologue( hFrequency, pLimits ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetRange(result, hFrequency, pLimits); } auto driver_result = pfnGetRange( hFrequency, pLimits ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetRangeEpilogue( hFrequency, pLimits ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetRange(result, hFrequency, pLimits); } - return logAndPropagateResult("zesFrequencyGetRange", driver_result); + return logAndPropagateResult_zesFrequencyGetRange(driver_result, hFrequency, pLimits); } /////////////////////////////////////////////////////////////////////////////// @@ -3115,12 +5968,12 @@ namespace validation_layer auto pfnSetRange = context.zesDdiTable.Frequency.pfnSetRange; if( nullptr == pfnSetRange ) - return logAndPropagateResult("zesFrequencySetRange", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencySetRange(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pLimits); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencySetRangePrologue( hFrequency, pLimits ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencySetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencySetRange(result, hFrequency, pLimits); } @@ -3131,17 +5984,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencySetRangePrologue( hFrequency, pLimits ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencySetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencySetRange(result, hFrequency, pLimits); } auto driver_result = pfnSetRange( hFrequency, pLimits ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencySetRangeEpilogue( hFrequency, pLimits ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencySetRange", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencySetRange(result, hFrequency, pLimits); } - return logAndPropagateResult("zesFrequencySetRange", driver_result); + return logAndPropagateResult_zesFrequencySetRange(driver_result, hFrequency, pLimits); } /////////////////////////////////////////////////////////////////////////////// @@ -3157,12 +6010,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Frequency.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesFrequencyGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetStatePrologue( hFrequency, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetState(result, hFrequency, pState); } @@ -3173,17 +6026,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyGetStatePrologue( hFrequency, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetState(result, hFrequency, pState); } auto driver_result = pfnGetState( hFrequency, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetStateEpilogue( hFrequency, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetState(result, hFrequency, pState); } - return logAndPropagateResult("zesFrequencyGetState", driver_result); + return logAndPropagateResult_zesFrequencyGetState(driver_result, hFrequency, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -3200,12 +6053,12 @@ namespace validation_layer auto pfnGetThrottleTime = context.zesDdiTable.Frequency.pfnGetThrottleTime; if( nullptr == pfnGetThrottleTime ) - return logAndPropagateResult("zesFrequencyGetThrottleTime", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyGetThrottleTime(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pThrottleTime); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetThrottleTimePrologue( hFrequency, pThrottleTime ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetThrottleTime", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetThrottleTime(result, hFrequency, pThrottleTime); } @@ -3216,17 +6069,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyGetThrottleTimePrologue( hFrequency, pThrottleTime ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetThrottleTime", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetThrottleTime(result, hFrequency, pThrottleTime); } auto driver_result = pfnGetThrottleTime( hFrequency, pThrottleTime ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyGetThrottleTimeEpilogue( hFrequency, pThrottleTime ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyGetThrottleTime", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyGetThrottleTime(result, hFrequency, pThrottleTime); } - return logAndPropagateResult("zesFrequencyGetThrottleTime", driver_result); + return logAndPropagateResult_zesFrequencyGetThrottleTime(driver_result, hFrequency, pThrottleTime); } /////////////////////////////////////////////////////////////////////////////// @@ -3242,12 +6095,12 @@ namespace validation_layer auto pfnOcGetCapabilities = context.zesDdiTable.Frequency.pfnOcGetCapabilities; if( nullptr == pfnOcGetCapabilities ) - return logAndPropagateResult("zesFrequencyOcGetCapabilities", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetCapabilities(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pOcCapabilities); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetCapabilitiesPrologue( hFrequency, pOcCapabilities ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetCapabilities", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetCapabilities(result, hFrequency, pOcCapabilities); } @@ -3258,17 +6111,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetCapabilitiesPrologue( hFrequency, pOcCapabilities ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetCapabilities", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetCapabilities(result, hFrequency, pOcCapabilities); } auto driver_result = pfnOcGetCapabilities( hFrequency, pOcCapabilities ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetCapabilitiesEpilogue( hFrequency, pOcCapabilities ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetCapabilities", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetCapabilities(result, hFrequency, pOcCapabilities); } - return logAndPropagateResult("zesFrequencyOcGetCapabilities", driver_result); + return logAndPropagateResult_zesFrequencyOcGetCapabilities(driver_result, hFrequency, pOcCapabilities); } /////////////////////////////////////////////////////////////////////////////// @@ -3287,12 +6140,12 @@ namespace validation_layer auto pfnOcGetFrequencyTarget = context.zesDdiTable.Frequency.pfnOcGetFrequencyTarget; if( nullptr == pfnOcGetFrequencyTarget ) - return logAndPropagateResult("zesFrequencyOcGetFrequencyTarget", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetFrequencyTarget(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pCurrentOcFrequency); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetFrequencyTargetPrologue( hFrequency, pCurrentOcFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetFrequencyTarget(result, hFrequency, pCurrentOcFrequency); } @@ -3303,17 +6156,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetFrequencyTargetPrologue( hFrequency, pCurrentOcFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetFrequencyTarget(result, hFrequency, pCurrentOcFrequency); } auto driver_result = pfnOcGetFrequencyTarget( hFrequency, pCurrentOcFrequency ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetFrequencyTargetEpilogue( hFrequency, pCurrentOcFrequency ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetFrequencyTarget(result, hFrequency, pCurrentOcFrequency); } - return logAndPropagateResult("zesFrequencyOcGetFrequencyTarget", driver_result); + return logAndPropagateResult_zesFrequencyOcGetFrequencyTarget(driver_result, hFrequency, pCurrentOcFrequency); } /////////////////////////////////////////////////////////////////////////////// @@ -3332,12 +6185,12 @@ namespace validation_layer auto pfnOcSetFrequencyTarget = context.zesDdiTable.Frequency.pfnOcSetFrequencyTarget; if( nullptr == pfnOcSetFrequencyTarget ) - return logAndPropagateResult("zesFrequencyOcSetFrequencyTarget", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcSetFrequencyTarget(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, CurrentOcFrequency); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetFrequencyTargetPrologue( hFrequency, CurrentOcFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetFrequencyTarget(result, hFrequency, CurrentOcFrequency); } @@ -3348,17 +6201,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcSetFrequencyTargetPrologue( hFrequency, CurrentOcFrequency ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetFrequencyTarget(result, hFrequency, CurrentOcFrequency); } auto driver_result = pfnOcSetFrequencyTarget( hFrequency, CurrentOcFrequency ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetFrequencyTargetEpilogue( hFrequency, CurrentOcFrequency ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetFrequencyTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetFrequencyTarget(result, hFrequency, CurrentOcFrequency); } - return logAndPropagateResult("zesFrequencyOcSetFrequencyTarget", driver_result); + return logAndPropagateResult_zesFrequencyOcSetFrequencyTarget(driver_result, hFrequency, CurrentOcFrequency); } /////////////////////////////////////////////////////////////////////////////// @@ -3379,12 +6232,12 @@ namespace validation_layer auto pfnOcGetVoltageTarget = context.zesDdiTable.Frequency.pfnOcGetVoltageTarget; if( nullptr == pfnOcGetVoltageTarget ) - return logAndPropagateResult("zesFrequencyOcGetVoltageTarget", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetVoltageTarget(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetVoltageTargetPrologue( hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetVoltageTarget(result, hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset); } @@ -3395,17 +6248,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetVoltageTargetPrologue( hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetVoltageTarget(result, hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset); } auto driver_result = pfnOcGetVoltageTarget( hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetVoltageTargetEpilogue( hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetVoltageTarget(result, hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset); } - return logAndPropagateResult("zesFrequencyOcGetVoltageTarget", driver_result); + return logAndPropagateResult_zesFrequencyOcGetVoltageTarget(driver_result, hFrequency, pCurrentVoltageTarget, pCurrentVoltageOffset); } /////////////////////////////////////////////////////////////////////////////// @@ -3426,12 +6279,12 @@ namespace validation_layer auto pfnOcSetVoltageTarget = context.zesDdiTable.Frequency.pfnOcSetVoltageTarget; if( nullptr == pfnOcSetVoltageTarget ) - return logAndPropagateResult("zesFrequencyOcSetVoltageTarget", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcSetVoltageTarget(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, CurrentVoltageTarget, CurrentVoltageOffset); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetVoltageTargetPrologue( hFrequency, CurrentVoltageTarget, CurrentVoltageOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetVoltageTarget(result, hFrequency, CurrentVoltageTarget, CurrentVoltageOffset); } @@ -3442,17 +6295,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcSetVoltageTargetPrologue( hFrequency, CurrentVoltageTarget, CurrentVoltageOffset ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetVoltageTarget(result, hFrequency, CurrentVoltageTarget, CurrentVoltageOffset); } auto driver_result = pfnOcSetVoltageTarget( hFrequency, CurrentVoltageTarget, CurrentVoltageOffset ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetVoltageTargetEpilogue( hFrequency, CurrentVoltageTarget, CurrentVoltageOffset ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetVoltageTarget", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetVoltageTarget(result, hFrequency, CurrentVoltageTarget, CurrentVoltageOffset); } - return logAndPropagateResult("zesFrequencyOcSetVoltageTarget", driver_result); + return logAndPropagateResult_zesFrequencyOcSetVoltageTarget(driver_result, hFrequency, CurrentVoltageTarget, CurrentVoltageOffset); } /////////////////////////////////////////////////////////////////////////////// @@ -3468,12 +6321,12 @@ namespace validation_layer auto pfnOcSetMode = context.zesDdiTable.Frequency.pfnOcSetMode; if( nullptr == pfnOcSetMode ) - return logAndPropagateResult("zesFrequencyOcSetMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcSetMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, CurrentOcMode); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetModePrologue( hFrequency, CurrentOcMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetMode(result, hFrequency, CurrentOcMode); } @@ -3484,17 +6337,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcSetModePrologue( hFrequency, CurrentOcMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetMode(result, hFrequency, CurrentOcMode); } auto driver_result = pfnOcSetMode( hFrequency, CurrentOcMode ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetModeEpilogue( hFrequency, CurrentOcMode ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetMode(result, hFrequency, CurrentOcMode); } - return logAndPropagateResult("zesFrequencyOcSetMode", driver_result); + return logAndPropagateResult_zesFrequencyOcSetMode(driver_result, hFrequency, CurrentOcMode); } /////////////////////////////////////////////////////////////////////////////// @@ -3510,12 +6363,12 @@ namespace validation_layer auto pfnOcGetMode = context.zesDdiTable.Frequency.pfnOcGetMode; if( nullptr == pfnOcGetMode ) - return logAndPropagateResult("zesFrequencyOcGetMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pCurrentOcMode); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetModePrologue( hFrequency, pCurrentOcMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetMode(result, hFrequency, pCurrentOcMode); } @@ -3526,17 +6379,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetModePrologue( hFrequency, pCurrentOcMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetMode(result, hFrequency, pCurrentOcMode); } auto driver_result = pfnOcGetMode( hFrequency, pCurrentOcMode ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetModeEpilogue( hFrequency, pCurrentOcMode ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetMode(result, hFrequency, pCurrentOcMode); } - return logAndPropagateResult("zesFrequencyOcGetMode", driver_result); + return logAndPropagateResult_zesFrequencyOcGetMode(driver_result, hFrequency, pCurrentOcMode); } /////////////////////////////////////////////////////////////////////////////// @@ -3553,12 +6406,12 @@ namespace validation_layer auto pfnOcGetIccMax = context.zesDdiTable.Frequency.pfnOcGetIccMax; if( nullptr == pfnOcGetIccMax ) - return logAndPropagateResult("zesFrequencyOcGetIccMax", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetIccMax(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pOcIccMax); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetIccMaxPrologue( hFrequency, pOcIccMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetIccMax(result, hFrequency, pOcIccMax); } @@ -3569,17 +6422,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetIccMaxPrologue( hFrequency, pOcIccMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetIccMax(result, hFrequency, pOcIccMax); } auto driver_result = pfnOcGetIccMax( hFrequency, pOcIccMax ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetIccMaxEpilogue( hFrequency, pOcIccMax ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetIccMax(result, hFrequency, pOcIccMax); } - return logAndPropagateResult("zesFrequencyOcGetIccMax", driver_result); + return logAndPropagateResult_zesFrequencyOcGetIccMax(driver_result, hFrequency, pOcIccMax); } /////////////////////////////////////////////////////////////////////////////// @@ -3595,12 +6448,12 @@ namespace validation_layer auto pfnOcSetIccMax = context.zesDdiTable.Frequency.pfnOcSetIccMax; if( nullptr == pfnOcSetIccMax ) - return logAndPropagateResult("zesFrequencyOcSetIccMax", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcSetIccMax(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, ocIccMax); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetIccMaxPrologue( hFrequency, ocIccMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetIccMax(result, hFrequency, ocIccMax); } @@ -3611,17 +6464,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcSetIccMaxPrologue( hFrequency, ocIccMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetIccMax(result, hFrequency, ocIccMax); } auto driver_result = pfnOcSetIccMax( hFrequency, ocIccMax ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetIccMaxEpilogue( hFrequency, ocIccMax ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetIccMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetIccMax(result, hFrequency, ocIccMax); } - return logAndPropagateResult("zesFrequencyOcSetIccMax", driver_result); + return logAndPropagateResult_zesFrequencyOcSetIccMax(driver_result, hFrequency, ocIccMax); } /////////////////////////////////////////////////////////////////////////////// @@ -3638,12 +6491,12 @@ namespace validation_layer auto pfnOcGetTjMax = context.zesDdiTable.Frequency.pfnOcGetTjMax; if( nullptr == pfnOcGetTjMax ) - return logAndPropagateResult("zesFrequencyOcGetTjMax", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcGetTjMax(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, pOcTjMax); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetTjMaxPrologue( hFrequency, pOcTjMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetTjMax(result, hFrequency, pOcTjMax); } @@ -3654,17 +6507,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcGetTjMaxPrologue( hFrequency, pOcTjMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetTjMax(result, hFrequency, pOcTjMax); } auto driver_result = pfnOcGetTjMax( hFrequency, pOcTjMax ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcGetTjMaxEpilogue( hFrequency, pOcTjMax ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcGetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcGetTjMax(result, hFrequency, pOcTjMax); } - return logAndPropagateResult("zesFrequencyOcGetTjMax", driver_result); + return logAndPropagateResult_zesFrequencyOcGetTjMax(driver_result, hFrequency, pOcTjMax); } /////////////////////////////////////////////////////////////////////////////// @@ -3680,12 +6533,12 @@ namespace validation_layer auto pfnOcSetTjMax = context.zesDdiTable.Frequency.pfnOcSetTjMax; if( nullptr == pfnOcSetTjMax ) - return logAndPropagateResult("zesFrequencyOcSetTjMax", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFrequencyOcSetTjMax(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFrequency, ocTjMax); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetTjMaxPrologue( hFrequency, ocTjMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetTjMax(result, hFrequency, ocTjMax); } @@ -3696,17 +6549,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFrequencyOcSetTjMaxPrologue( hFrequency, ocTjMax ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetTjMax(result, hFrequency, ocTjMax); } auto driver_result = pfnOcSetTjMax( hFrequency, ocTjMax ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFrequencyOcSetTjMaxEpilogue( hFrequency, ocTjMax ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFrequencyOcSetTjMax", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFrequencyOcSetTjMax(result, hFrequency, ocTjMax); } - return logAndPropagateResult("zesFrequencyOcSetTjMax", driver_result); + return logAndPropagateResult_zesFrequencyOcSetTjMax(driver_result, hFrequency, ocTjMax); } /////////////////////////////////////////////////////////////////////////////// @@ -3732,12 +6585,12 @@ namespace validation_layer auto pfnEnumLeds = context.zesDdiTable.Device.pfnEnumLeds; if( nullptr == pfnEnumLeds ) - return logAndPropagateResult("zesDeviceEnumLeds", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumLeds(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phLed); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumLedsPrologue( hDevice, pCount, phLed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumLeds", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumLeds(result, hDevice, pCount, phLed); } @@ -3748,17 +6601,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumLedsPrologue( hDevice, pCount, phLed ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumLeds", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumLeds(result, hDevice, pCount, phLed); } auto driver_result = pfnEnumLeds( hDevice, pCount, phLed ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumLedsEpilogue( hDevice, pCount, phLed ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumLeds", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumLeds(result, hDevice, pCount, phLed); } - return logAndPropagateResult("zesDeviceEnumLeds", driver_result); + return logAndPropagateResult_zesDeviceEnumLeds(driver_result, hDevice, pCount, phLed); } /////////////////////////////////////////////////////////////////////////////// @@ -3774,12 +6627,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Led.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesLedGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesLedGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hLed, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedGetPropertiesPrologue( hLed, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetProperties(result, hLed, pProperties); } @@ -3790,17 +6643,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesLedGetPropertiesPrologue( hLed, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetProperties(result, hLed, pProperties); } auto driver_result = pfnGetProperties( hLed, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedGetPropertiesEpilogue( hLed, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetProperties(result, hLed, pProperties); } - return logAndPropagateResult("zesLedGetProperties", driver_result); + return logAndPropagateResult_zesLedGetProperties(driver_result, hLed, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -3816,12 +6669,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Led.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesLedGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesLedGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hLed, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedGetStatePrologue( hLed, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetState(result, hLed, pState); } @@ -3832,17 +6685,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesLedGetStatePrologue( hLed, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetState(result, hLed, pState); } auto driver_result = pfnGetState( hLed, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedGetStateEpilogue( hLed, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedGetState(result, hLed, pState); } - return logAndPropagateResult("zesLedGetState", driver_result); + return logAndPropagateResult_zesLedGetState(driver_result, hLed, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -3858,12 +6711,12 @@ namespace validation_layer auto pfnSetState = context.zesDdiTable.Led.pfnSetState; if( nullptr == pfnSetState ) - return logAndPropagateResult("zesLedSetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesLedSetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hLed, enable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedSetStatePrologue( hLed, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetState(result, hLed, enable); } @@ -3874,17 +6727,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesLedSetStatePrologue( hLed, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetState(result, hLed, enable); } auto driver_result = pfnSetState( hLed, enable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedSetStateEpilogue( hLed, enable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetState(result, hLed, enable); } - return logAndPropagateResult("zesLedSetState", driver_result); + return logAndPropagateResult_zesLedSetState(driver_result, hLed, enable); } /////////////////////////////////////////////////////////////////////////////// @@ -3900,12 +6753,12 @@ namespace validation_layer auto pfnSetColor = context.zesDdiTable.Led.pfnSetColor; if( nullptr == pfnSetColor ) - return logAndPropagateResult("zesLedSetColor", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesLedSetColor(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hLed, pColor); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedSetColorPrologue( hLed, pColor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetColor", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetColor(result, hLed, pColor); } @@ -3916,17 +6769,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesLedSetColorPrologue( hLed, pColor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetColor", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetColor(result, hLed, pColor); } auto driver_result = pfnSetColor( hLed, pColor ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesLedSetColorEpilogue( hLed, pColor ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesLedSetColor", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesLedSetColor(result, hLed, pColor); } - return logAndPropagateResult("zesLedSetColor", driver_result); + return logAndPropagateResult_zesLedSetColor(driver_result, hLed, pColor); } /////////////////////////////////////////////////////////////////////////////// @@ -3952,12 +6805,12 @@ namespace validation_layer auto pfnEnumMemoryModules = context.zesDdiTable.Device.pfnEnumMemoryModules; if( nullptr == pfnEnumMemoryModules ) - return logAndPropagateResult("zesDeviceEnumMemoryModules", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumMemoryModules(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phMemory); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumMemoryModulesPrologue( hDevice, pCount, phMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumMemoryModules", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumMemoryModules(result, hDevice, pCount, phMemory); } @@ -3968,17 +6821,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumMemoryModulesPrologue( hDevice, pCount, phMemory ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumMemoryModules", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumMemoryModules(result, hDevice, pCount, phMemory); } auto driver_result = pfnEnumMemoryModules( hDevice, pCount, phMemory ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumMemoryModulesEpilogue( hDevice, pCount, phMemory ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumMemoryModules", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumMemoryModules(result, hDevice, pCount, phMemory); } - return logAndPropagateResult("zesDeviceEnumMemoryModules", driver_result); + return logAndPropagateResult_zesDeviceEnumMemoryModules(driver_result, hDevice, pCount, phMemory); } /////////////////////////////////////////////////////////////////////////////// @@ -3994,12 +6847,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Memory.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesMemoryGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesMemoryGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMemory, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetPropertiesPrologue( hMemory, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetProperties(result, hMemory, pProperties); } @@ -4010,17 +6863,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesMemoryGetPropertiesPrologue( hMemory, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetProperties(result, hMemory, pProperties); } auto driver_result = pfnGetProperties( hMemory, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetPropertiesEpilogue( hMemory, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetProperties(result, hMemory, pProperties); } - return logAndPropagateResult("zesMemoryGetProperties", driver_result); + return logAndPropagateResult_zesMemoryGetProperties(driver_result, hMemory, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4036,12 +6889,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Memory.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesMemoryGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesMemoryGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMemory, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetStatePrologue( hMemory, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetState(result, hMemory, pState); } @@ -4052,17 +6905,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesMemoryGetStatePrologue( hMemory, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetState(result, hMemory, pState); } auto driver_result = pfnGetState( hMemory, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetStateEpilogue( hMemory, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetState(result, hMemory, pState); } - return logAndPropagateResult("zesMemoryGetState", driver_result); + return logAndPropagateResult_zesMemoryGetState(driver_result, hMemory, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -4079,12 +6932,12 @@ namespace validation_layer auto pfnGetBandwidth = context.zesDdiTable.Memory.pfnGetBandwidth; if( nullptr == pfnGetBandwidth ) - return logAndPropagateResult("zesMemoryGetBandwidth", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesMemoryGetBandwidth(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMemory, pBandwidth); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetBandwidthPrologue( hMemory, pBandwidth ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetBandwidth", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetBandwidth(result, hMemory, pBandwidth); } @@ -4095,17 +6948,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesMemoryGetBandwidthPrologue( hMemory, pBandwidth ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetBandwidth", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetBandwidth(result, hMemory, pBandwidth); } auto driver_result = pfnGetBandwidth( hMemory, pBandwidth ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesMemoryGetBandwidthEpilogue( hMemory, pBandwidth ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesMemoryGetBandwidth", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesMemoryGetBandwidth(result, hMemory, pBandwidth); } - return logAndPropagateResult("zesMemoryGetBandwidth", driver_result); + return logAndPropagateResult_zesMemoryGetBandwidth(driver_result, hMemory, pBandwidth); } /////////////////////////////////////////////////////////////////////////////// @@ -4131,12 +6984,12 @@ namespace validation_layer auto pfnEnumPerformanceFactorDomains = context.zesDdiTable.Device.pfnEnumPerformanceFactorDomains; if( nullptr == pfnEnumPerformanceFactorDomains ) - return logAndPropagateResult("zesDeviceEnumPerformanceFactorDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phPerf); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPerformanceFactorDomainsPrologue( hDevice, pCount, phPerf ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPerformanceFactorDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains(result, hDevice, pCount, phPerf); } @@ -4147,17 +7000,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumPerformanceFactorDomainsPrologue( hDevice, pCount, phPerf ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPerformanceFactorDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains(result, hDevice, pCount, phPerf); } auto driver_result = pfnEnumPerformanceFactorDomains( hDevice, pCount, phPerf ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPerformanceFactorDomainsEpilogue( hDevice, pCount, phPerf ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPerformanceFactorDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains(result, hDevice, pCount, phPerf); } - return logAndPropagateResult("zesDeviceEnumPerformanceFactorDomains", driver_result); + return logAndPropagateResult_zesDeviceEnumPerformanceFactorDomains(driver_result, hDevice, pCount, phPerf); } /////////////////////////////////////////////////////////////////////////////// @@ -4174,12 +7027,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.PerformanceFactor.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesPerformanceFactorGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPerformanceFactorGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPerf, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorGetPropertiesPrologue( hPerf, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetProperties(result, hPerf, pProperties); } @@ -4190,17 +7043,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPerformanceFactorGetPropertiesPrologue( hPerf, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetProperties(result, hPerf, pProperties); } auto driver_result = pfnGetProperties( hPerf, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorGetPropertiesEpilogue( hPerf, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetProperties(result, hPerf, pProperties); } - return logAndPropagateResult("zesPerformanceFactorGetProperties", driver_result); + return logAndPropagateResult_zesPerformanceFactorGetProperties(driver_result, hPerf, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4217,12 +7070,12 @@ namespace validation_layer auto pfnGetConfig = context.zesDdiTable.PerformanceFactor.pfnGetConfig; if( nullptr == pfnGetConfig ) - return logAndPropagateResult("zesPerformanceFactorGetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPerformanceFactorGetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPerf, pFactor); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorGetConfigPrologue( hPerf, pFactor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetConfig(result, hPerf, pFactor); } @@ -4233,17 +7086,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPerformanceFactorGetConfigPrologue( hPerf, pFactor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetConfig(result, hPerf, pFactor); } auto driver_result = pfnGetConfig( hPerf, pFactor ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorGetConfigEpilogue( hPerf, pFactor ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorGetConfig(result, hPerf, pFactor); } - return logAndPropagateResult("zesPerformanceFactorGetConfig", driver_result); + return logAndPropagateResult_zesPerformanceFactorGetConfig(driver_result, hPerf, pFactor); } /////////////////////////////////////////////////////////////////////////////// @@ -4259,12 +7112,12 @@ namespace validation_layer auto pfnSetConfig = context.zesDdiTable.PerformanceFactor.pfnSetConfig; if( nullptr == pfnSetConfig ) - return logAndPropagateResult("zesPerformanceFactorSetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPerformanceFactorSetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPerf, factor); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorSetConfigPrologue( hPerf, factor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorSetConfig(result, hPerf, factor); } @@ -4275,17 +7128,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPerformanceFactorSetConfigPrologue( hPerf, factor ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorSetConfig(result, hPerf, factor); } auto driver_result = pfnSetConfig( hPerf, factor ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPerformanceFactorSetConfigEpilogue( hPerf, factor ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPerformanceFactorSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPerformanceFactorSetConfig(result, hPerf, factor); } - return logAndPropagateResult("zesPerformanceFactorSetConfig", driver_result); + return logAndPropagateResult_zesPerformanceFactorSetConfig(driver_result, hPerf, factor); } /////////////////////////////////////////////////////////////////////////////// @@ -4311,12 +7164,12 @@ namespace validation_layer auto pfnEnumPowerDomains = context.zesDdiTable.Device.pfnEnumPowerDomains; if( nullptr == pfnEnumPowerDomains ) - return logAndPropagateResult("zesDeviceEnumPowerDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumPowerDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phPower); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPowerDomainsPrologue( hDevice, pCount, phPower ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPowerDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPowerDomains(result, hDevice, pCount, phPower); } @@ -4327,17 +7180,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumPowerDomainsPrologue( hDevice, pCount, phPower ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPowerDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPowerDomains(result, hDevice, pCount, phPower); } auto driver_result = pfnEnumPowerDomains( hDevice, pCount, phPower ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPowerDomainsEpilogue( hDevice, pCount, phPower ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPowerDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPowerDomains(result, hDevice, pCount, phPower); } - return logAndPropagateResult("zesDeviceEnumPowerDomains", driver_result); + return logAndPropagateResult_zesDeviceEnumPowerDomains(driver_result, hDevice, pCount, phPower); } /////////////////////////////////////////////////////////////////////////////// @@ -4353,12 +7206,12 @@ namespace validation_layer auto pfnGetCardPowerDomain = context.zesDdiTable.Device.pfnGetCardPowerDomain; if( nullptr == pfnGetCardPowerDomain ) - return logAndPropagateResult("zesDeviceGetCardPowerDomain", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetCardPowerDomain(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, phPower); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetCardPowerDomainPrologue( hDevice, phPower ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetCardPowerDomain", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetCardPowerDomain(result, hDevice, phPower); } @@ -4369,17 +7222,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetCardPowerDomainPrologue( hDevice, phPower ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetCardPowerDomain", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetCardPowerDomain(result, hDevice, phPower); } auto driver_result = pfnGetCardPowerDomain( hDevice, phPower ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetCardPowerDomainEpilogue( hDevice, phPower ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetCardPowerDomain", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetCardPowerDomain(result, hDevice, phPower); } - return logAndPropagateResult("zesDeviceGetCardPowerDomain", driver_result); + return logAndPropagateResult_zesDeviceGetCardPowerDomain(driver_result, hDevice, phPower); } /////////////////////////////////////////////////////////////////////////////// @@ -4395,12 +7248,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Power.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesPowerGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetPropertiesPrologue( hPower, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetProperties(result, hPower, pProperties); } @@ -4411,17 +7264,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerGetPropertiesPrologue( hPower, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetProperties(result, hPower, pProperties); } auto driver_result = pfnGetProperties( hPower, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetPropertiesEpilogue( hPower, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetProperties(result, hPower, pProperties); } - return logAndPropagateResult("zesPowerGetProperties", driver_result); + return logAndPropagateResult_zesPowerGetProperties(driver_result, hPower, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4438,12 +7291,12 @@ namespace validation_layer auto pfnGetEnergyCounter = context.zesDdiTable.Power.pfnGetEnergyCounter; if( nullptr == pfnGetEnergyCounter ) - return logAndPropagateResult("zesPowerGetEnergyCounter", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerGetEnergyCounter(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pEnergy); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetEnergyCounterPrologue( hPower, pEnergy ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyCounter", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyCounter(result, hPower, pEnergy); } @@ -4454,17 +7307,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerGetEnergyCounterPrologue( hPower, pEnergy ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyCounter", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyCounter(result, hPower, pEnergy); } auto driver_result = pfnGetEnergyCounter( hPower, pEnergy ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetEnergyCounterEpilogue( hPower, pEnergy ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyCounter", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyCounter(result, hPower, pEnergy); } - return logAndPropagateResult("zesPowerGetEnergyCounter", driver_result); + return logAndPropagateResult_zesPowerGetEnergyCounter(driver_result, hPower, pEnergy); } /////////////////////////////////////////////////////////////////////////////// @@ -4485,12 +7338,12 @@ namespace validation_layer auto pfnGetLimits = context.zesDdiTable.Power.pfnGetLimits; if( nullptr == pfnGetLimits ) - return logAndPropagateResult("zesPowerGetLimits", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerGetLimits(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pSustained, pBurst, pPeak); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetLimitsPrologue( hPower, pSustained, pBurst, pPeak ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimits(result, hPower, pSustained, pBurst, pPeak); } @@ -4501,17 +7354,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerGetLimitsPrologue( hPower, pSustained, pBurst, pPeak ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimits(result, hPower, pSustained, pBurst, pPeak); } auto driver_result = pfnGetLimits( hPower, pSustained, pBurst, pPeak ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetLimitsEpilogue( hPower, pSustained, pBurst, pPeak ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimits(result, hPower, pSustained, pBurst, pPeak); } - return logAndPropagateResult("zesPowerGetLimits", driver_result); + return logAndPropagateResult_zesPowerGetLimits(driver_result, hPower, pSustained, pBurst, pPeak); } /////////////////////////////////////////////////////////////////////////////// @@ -4532,12 +7385,12 @@ namespace validation_layer auto pfnSetLimits = context.zesDdiTable.Power.pfnSetLimits; if( nullptr == pfnSetLimits ) - return logAndPropagateResult("zesPowerSetLimits", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerSetLimits(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pSustained, pBurst, pPeak); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetLimitsPrologue( hPower, pSustained, pBurst, pPeak ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimits(result, hPower, pSustained, pBurst, pPeak); } @@ -4548,17 +7401,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerSetLimitsPrologue( hPower, pSustained, pBurst, pPeak ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimits(result, hPower, pSustained, pBurst, pPeak); } auto driver_result = pfnSetLimits( hPower, pSustained, pBurst, pPeak ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetLimitsEpilogue( hPower, pSustained, pBurst, pPeak ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimits", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimits(result, hPower, pSustained, pBurst, pPeak); } - return logAndPropagateResult("zesPowerSetLimits", driver_result); + return logAndPropagateResult_zesPowerSetLimits(driver_result, hPower, pSustained, pBurst, pPeak); } /////////////////////////////////////////////////////////////////////////////// @@ -4575,12 +7428,12 @@ namespace validation_layer auto pfnGetEnergyThreshold = context.zesDdiTable.Power.pfnGetEnergyThreshold; if( nullptr == pfnGetEnergyThreshold ) - return logAndPropagateResult("zesPowerGetEnergyThreshold", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerGetEnergyThreshold(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pThreshold); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetEnergyThresholdPrologue( hPower, pThreshold ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyThreshold(result, hPower, pThreshold); } @@ -4591,17 +7444,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerGetEnergyThresholdPrologue( hPower, pThreshold ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyThreshold(result, hPower, pThreshold); } auto driver_result = pfnGetEnergyThreshold( hPower, pThreshold ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetEnergyThresholdEpilogue( hPower, pThreshold ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetEnergyThreshold(result, hPower, pThreshold); } - return logAndPropagateResult("zesPowerGetEnergyThreshold", driver_result); + return logAndPropagateResult_zesPowerGetEnergyThreshold(driver_result, hPower, pThreshold); } /////////////////////////////////////////////////////////////////////////////// @@ -4617,12 +7470,12 @@ namespace validation_layer auto pfnSetEnergyThreshold = context.zesDdiTable.Power.pfnSetEnergyThreshold; if( nullptr == pfnSetEnergyThreshold ) - return logAndPropagateResult("zesPowerSetEnergyThreshold", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerSetEnergyThreshold(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, threshold); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetEnergyThresholdPrologue( hPower, threshold ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetEnergyThreshold(result, hPower, threshold); } @@ -4633,17 +7486,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerSetEnergyThresholdPrologue( hPower, threshold ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetEnergyThreshold(result, hPower, threshold); } auto driver_result = pfnSetEnergyThreshold( hPower, threshold ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetEnergyThresholdEpilogue( hPower, threshold ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetEnergyThreshold", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetEnergyThreshold(result, hPower, threshold); } - return logAndPropagateResult("zesPowerSetEnergyThreshold", driver_result); + return logAndPropagateResult_zesPowerSetEnergyThreshold(driver_result, hPower, threshold); } /////////////////////////////////////////////////////////////////////////////// @@ -4669,12 +7522,12 @@ namespace validation_layer auto pfnEnumPsus = context.zesDdiTable.Device.pfnEnumPsus; if( nullptr == pfnEnumPsus ) - return logAndPropagateResult("zesDeviceEnumPsus", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumPsus(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phPsu); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPsusPrologue( hDevice, pCount, phPsu ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPsus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPsus(result, hDevice, pCount, phPsu); } @@ -4685,17 +7538,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumPsusPrologue( hDevice, pCount, phPsu ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPsus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPsus(result, hDevice, pCount, phPsu); } auto driver_result = pfnEnumPsus( hDevice, pCount, phPsu ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumPsusEpilogue( hDevice, pCount, phPsu ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumPsus", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumPsus(result, hDevice, pCount, phPsu); } - return logAndPropagateResult("zesDeviceEnumPsus", driver_result); + return logAndPropagateResult_zesDeviceEnumPsus(driver_result, hDevice, pCount, phPsu); } /////////////////////////////////////////////////////////////////////////////// @@ -4711,12 +7564,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Psu.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesPsuGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPsuGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPsu, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPsuGetPropertiesPrologue( hPsu, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetProperties(result, hPsu, pProperties); } @@ -4727,17 +7580,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPsuGetPropertiesPrologue( hPsu, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetProperties(result, hPsu, pProperties); } auto driver_result = pfnGetProperties( hPsu, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPsuGetPropertiesEpilogue( hPsu, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetProperties(result, hPsu, pProperties); } - return logAndPropagateResult("zesPsuGetProperties", driver_result); + return logAndPropagateResult_zesPsuGetProperties(driver_result, hPsu, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4753,12 +7606,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Psu.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesPsuGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPsuGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPsu, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPsuGetStatePrologue( hPsu, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetState(result, hPsu, pState); } @@ -4769,17 +7622,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPsuGetStatePrologue( hPsu, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetState(result, hPsu, pState); } auto driver_result = pfnGetState( hPsu, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPsuGetStateEpilogue( hPsu, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPsuGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPsuGetState(result, hPsu, pState); } - return logAndPropagateResult("zesPsuGetState", driver_result); + return logAndPropagateResult_zesPsuGetState(driver_result, hPsu, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -4805,12 +7658,12 @@ namespace validation_layer auto pfnEnumRasErrorSets = context.zesDdiTable.Device.pfnEnumRasErrorSets; if( nullptr == pfnEnumRasErrorSets ) - return logAndPropagateResult("zesDeviceEnumRasErrorSets", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumRasErrorSets(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phRas); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumRasErrorSetsPrologue( hDevice, pCount, phRas ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumRasErrorSets", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumRasErrorSets(result, hDevice, pCount, phRas); } @@ -4821,17 +7674,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumRasErrorSetsPrologue( hDevice, pCount, phRas ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumRasErrorSets", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumRasErrorSets(result, hDevice, pCount, phRas); } auto driver_result = pfnEnumRasErrorSets( hDevice, pCount, phRas ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumRasErrorSetsEpilogue( hDevice, pCount, phRas ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumRasErrorSets", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumRasErrorSets(result, hDevice, pCount, phRas); } - return logAndPropagateResult("zesDeviceEnumRasErrorSets", driver_result); + return logAndPropagateResult_zesDeviceEnumRasErrorSets(driver_result, hDevice, pCount, phRas); } /////////////////////////////////////////////////////////////////////////////// @@ -4847,12 +7700,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Ras.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesRasGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetPropertiesPrologue( hRas, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetProperties(result, hRas, pProperties); } @@ -4863,17 +7716,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasGetPropertiesPrologue( hRas, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetProperties(result, hRas, pProperties); } auto driver_result = pfnGetProperties( hRas, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetPropertiesEpilogue( hRas, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetProperties(result, hRas, pProperties); } - return logAndPropagateResult("zesRasGetProperties", driver_result); + return logAndPropagateResult_zesRasGetProperties(driver_result, hRas, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -4890,12 +7743,12 @@ namespace validation_layer auto pfnGetConfig = context.zesDdiTable.Ras.pfnGetConfig; if( nullptr == pfnGetConfig ) - return logAndPropagateResult("zesRasGetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasGetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetConfigPrologue( hRas, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetConfig(result, hRas, pConfig); } @@ -4906,17 +7759,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasGetConfigPrologue( hRas, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetConfig(result, hRas, pConfig); } auto driver_result = pfnGetConfig( hRas, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetConfigEpilogue( hRas, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetConfig(result, hRas, pConfig); } - return logAndPropagateResult("zesRasGetConfig", driver_result); + return logAndPropagateResult_zesRasGetConfig(driver_result, hRas, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -4932,12 +7785,12 @@ namespace validation_layer auto pfnSetConfig = context.zesDdiTable.Ras.pfnSetConfig; if( nullptr == pfnSetConfig ) - return logAndPropagateResult("zesRasSetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasSetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasSetConfigPrologue( hRas, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasSetConfig(result, hRas, pConfig); } @@ -4948,17 +7801,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasSetConfigPrologue( hRas, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasSetConfig(result, hRas, pConfig); } auto driver_result = pfnSetConfig( hRas, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasSetConfigEpilogue( hRas, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasSetConfig(result, hRas, pConfig); } - return logAndPropagateResult("zesRasSetConfig", driver_result); + return logAndPropagateResult_zesRasSetConfig(driver_result, hRas, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -4975,12 +7828,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Ras.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesRasGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, clear, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetStatePrologue( hRas, clear, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetState(result, hRas, clear, pState); } @@ -4991,17 +7844,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasGetStatePrologue( hRas, clear, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetState(result, hRas, clear, pState); } auto driver_result = pfnGetState( hRas, clear, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetStateEpilogue( hRas, clear, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetState(result, hRas, clear, pState); } - return logAndPropagateResult("zesRasGetState", driver_result); + return logAndPropagateResult_zesRasGetState(driver_result, hRas, clear, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -5027,12 +7880,12 @@ namespace validation_layer auto pfnEnumSchedulers = context.zesDdiTable.Device.pfnEnumSchedulers; if( nullptr == pfnEnumSchedulers ) - return logAndPropagateResult("zesDeviceEnumSchedulers", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumSchedulers(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phScheduler); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumSchedulersPrologue( hDevice, pCount, phScheduler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumSchedulers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumSchedulers(result, hDevice, pCount, phScheduler); } @@ -5043,17 +7896,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumSchedulersPrologue( hDevice, pCount, phScheduler ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumSchedulers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumSchedulers(result, hDevice, pCount, phScheduler); } auto driver_result = pfnEnumSchedulers( hDevice, pCount, phScheduler ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumSchedulersEpilogue( hDevice, pCount, phScheduler ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumSchedulers", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumSchedulers(result, hDevice, pCount, phScheduler); } - return logAndPropagateResult("zesDeviceEnumSchedulers", driver_result); + return logAndPropagateResult_zesDeviceEnumSchedulers(driver_result, hDevice, pCount, phScheduler); } /////////////////////////////////////////////////////////////////////////////// @@ -5069,12 +7922,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Scheduler.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesSchedulerGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetPropertiesPrologue( hScheduler, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetProperties(result, hScheduler, pProperties); } @@ -5085,17 +7938,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerGetPropertiesPrologue( hScheduler, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetProperties(result, hScheduler, pProperties); } auto driver_result = pfnGetProperties( hScheduler, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetPropertiesEpilogue( hScheduler, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetProperties(result, hScheduler, pProperties); } - return logAndPropagateResult("zesSchedulerGetProperties", driver_result); + return logAndPropagateResult_zesSchedulerGetProperties(driver_result, hScheduler, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -5111,12 +7964,12 @@ namespace validation_layer auto pfnGetCurrentMode = context.zesDdiTable.Scheduler.pfnGetCurrentMode; if( nullptr == pfnGetCurrentMode ) - return logAndPropagateResult("zesSchedulerGetCurrentMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerGetCurrentMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pMode); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetCurrentModePrologue( hScheduler, pMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetCurrentMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetCurrentMode(result, hScheduler, pMode); } @@ -5127,17 +7980,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerGetCurrentModePrologue( hScheduler, pMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetCurrentMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetCurrentMode(result, hScheduler, pMode); } auto driver_result = pfnGetCurrentMode( hScheduler, pMode ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetCurrentModeEpilogue( hScheduler, pMode ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetCurrentMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetCurrentMode(result, hScheduler, pMode); } - return logAndPropagateResult("zesSchedulerGetCurrentMode", driver_result); + return logAndPropagateResult_zesSchedulerGetCurrentMode(driver_result, hScheduler, pMode); } /////////////////////////////////////////////////////////////////////////////// @@ -5155,12 +8008,12 @@ namespace validation_layer auto pfnGetTimeoutModeProperties = context.zesDdiTable.Scheduler.pfnGetTimeoutModeProperties; if( nullptr == pfnGetTimeoutModeProperties ) - return logAndPropagateResult("zesSchedulerGetTimeoutModeProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerGetTimeoutModeProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, getDefaults, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetTimeoutModePropertiesPrologue( hScheduler, getDefaults, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimeoutModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimeoutModeProperties(result, hScheduler, getDefaults, pConfig); } @@ -5171,17 +8024,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerGetTimeoutModePropertiesPrologue( hScheduler, getDefaults, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimeoutModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimeoutModeProperties(result, hScheduler, getDefaults, pConfig); } auto driver_result = pfnGetTimeoutModeProperties( hScheduler, getDefaults, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetTimeoutModePropertiesEpilogue( hScheduler, getDefaults, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimeoutModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimeoutModeProperties(result, hScheduler, getDefaults, pConfig); } - return logAndPropagateResult("zesSchedulerGetTimeoutModeProperties", driver_result); + return logAndPropagateResult_zesSchedulerGetTimeoutModeProperties(driver_result, hScheduler, getDefaults, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -5199,12 +8052,12 @@ namespace validation_layer auto pfnGetTimesliceModeProperties = context.zesDdiTable.Scheduler.pfnGetTimesliceModeProperties; if( nullptr == pfnGetTimesliceModeProperties ) - return logAndPropagateResult("zesSchedulerGetTimesliceModeProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerGetTimesliceModeProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, getDefaults, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetTimesliceModePropertiesPrologue( hScheduler, getDefaults, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimesliceModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimesliceModeProperties(result, hScheduler, getDefaults, pConfig); } @@ -5215,17 +8068,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerGetTimesliceModePropertiesPrologue( hScheduler, getDefaults, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimesliceModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimesliceModeProperties(result, hScheduler, getDefaults, pConfig); } auto driver_result = pfnGetTimesliceModeProperties( hScheduler, getDefaults, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerGetTimesliceModePropertiesEpilogue( hScheduler, getDefaults, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerGetTimesliceModeProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerGetTimesliceModeProperties(result, hScheduler, getDefaults, pConfig); } - return logAndPropagateResult("zesSchedulerGetTimesliceModeProperties", driver_result); + return logAndPropagateResult_zesSchedulerGetTimesliceModeProperties(driver_result, hScheduler, getDefaults, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -5243,12 +8096,12 @@ namespace validation_layer auto pfnSetTimeoutMode = context.zesDdiTable.Scheduler.pfnSetTimeoutMode; if( nullptr == pfnSetTimeoutMode ) - return logAndPropagateResult("zesSchedulerSetTimeoutMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerSetTimeoutMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pProperties, pNeedReload); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetTimeoutModePrologue( hScheduler, pProperties, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimeoutMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimeoutMode(result, hScheduler, pProperties, pNeedReload); } @@ -5259,17 +8112,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerSetTimeoutModePrologue( hScheduler, pProperties, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimeoutMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimeoutMode(result, hScheduler, pProperties, pNeedReload); } auto driver_result = pfnSetTimeoutMode( hScheduler, pProperties, pNeedReload ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetTimeoutModeEpilogue( hScheduler, pProperties, pNeedReload ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimeoutMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimeoutMode(result, hScheduler, pProperties, pNeedReload); } - return logAndPropagateResult("zesSchedulerSetTimeoutMode", driver_result); + return logAndPropagateResult_zesSchedulerSetTimeoutMode(driver_result, hScheduler, pProperties, pNeedReload); } /////////////////////////////////////////////////////////////////////////////// @@ -5287,12 +8140,12 @@ namespace validation_layer auto pfnSetTimesliceMode = context.zesDdiTable.Scheduler.pfnSetTimesliceMode; if( nullptr == pfnSetTimesliceMode ) - return logAndPropagateResult("zesSchedulerSetTimesliceMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerSetTimesliceMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pProperties, pNeedReload); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetTimesliceModePrologue( hScheduler, pProperties, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimesliceMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimesliceMode(result, hScheduler, pProperties, pNeedReload); } @@ -5303,17 +8156,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerSetTimesliceModePrologue( hScheduler, pProperties, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimesliceMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimesliceMode(result, hScheduler, pProperties, pNeedReload); } auto driver_result = pfnSetTimesliceMode( hScheduler, pProperties, pNeedReload ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetTimesliceModeEpilogue( hScheduler, pProperties, pNeedReload ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetTimesliceMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetTimesliceMode(result, hScheduler, pProperties, pNeedReload); } - return logAndPropagateResult("zesSchedulerSetTimesliceMode", driver_result); + return logAndPropagateResult_zesSchedulerSetTimesliceMode(driver_result, hScheduler, pProperties, pNeedReload); } /////////////////////////////////////////////////////////////////////////////// @@ -5330,12 +8183,12 @@ namespace validation_layer auto pfnSetExclusiveMode = context.zesDdiTable.Scheduler.pfnSetExclusiveMode; if( nullptr == pfnSetExclusiveMode ) - return logAndPropagateResult("zesSchedulerSetExclusiveMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerSetExclusiveMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pNeedReload); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetExclusiveModePrologue( hScheduler, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetExclusiveMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetExclusiveMode(result, hScheduler, pNeedReload); } @@ -5346,17 +8199,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerSetExclusiveModePrologue( hScheduler, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetExclusiveMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetExclusiveMode(result, hScheduler, pNeedReload); } auto driver_result = pfnSetExclusiveMode( hScheduler, pNeedReload ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetExclusiveModeEpilogue( hScheduler, pNeedReload ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetExclusiveMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetExclusiveMode(result, hScheduler, pNeedReload); } - return logAndPropagateResult("zesSchedulerSetExclusiveMode", driver_result); + return logAndPropagateResult_zesSchedulerSetExclusiveMode(driver_result, hScheduler, pNeedReload); } /////////////////////////////////////////////////////////////////////////////// @@ -5373,12 +8226,12 @@ namespace validation_layer auto pfnSetComputeUnitDebugMode = context.zesDdiTable.Scheduler.pfnSetComputeUnitDebugMode; if( nullptr == pfnSetComputeUnitDebugMode ) - return logAndPropagateResult("zesSchedulerSetComputeUnitDebugMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hScheduler, pNeedReload); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetComputeUnitDebugModePrologue( hScheduler, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetComputeUnitDebugMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode(result, hScheduler, pNeedReload); } @@ -5389,17 +8242,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesSchedulerSetComputeUnitDebugModePrologue( hScheduler, pNeedReload ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetComputeUnitDebugMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode(result, hScheduler, pNeedReload); } auto driver_result = pfnSetComputeUnitDebugMode( hScheduler, pNeedReload ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesSchedulerSetComputeUnitDebugModeEpilogue( hScheduler, pNeedReload ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesSchedulerSetComputeUnitDebugMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode(result, hScheduler, pNeedReload); } - return logAndPropagateResult("zesSchedulerSetComputeUnitDebugMode", driver_result); + return logAndPropagateResult_zesSchedulerSetComputeUnitDebugMode(driver_result, hScheduler, pNeedReload); } /////////////////////////////////////////////////////////////////////////////// @@ -5425,12 +8278,12 @@ namespace validation_layer auto pfnEnumStandbyDomains = context.zesDdiTable.Device.pfnEnumStandbyDomains; if( nullptr == pfnEnumStandbyDomains ) - return logAndPropagateResult("zesDeviceEnumStandbyDomains", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumStandbyDomains(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phStandby); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumStandbyDomainsPrologue( hDevice, pCount, phStandby ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumStandbyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumStandbyDomains(result, hDevice, pCount, phStandby); } @@ -5441,17 +8294,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumStandbyDomainsPrologue( hDevice, pCount, phStandby ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumStandbyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumStandbyDomains(result, hDevice, pCount, phStandby); } auto driver_result = pfnEnumStandbyDomains( hDevice, pCount, phStandby ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumStandbyDomainsEpilogue( hDevice, pCount, phStandby ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumStandbyDomains", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumStandbyDomains(result, hDevice, pCount, phStandby); } - return logAndPropagateResult("zesDeviceEnumStandbyDomains", driver_result); + return logAndPropagateResult_zesDeviceEnumStandbyDomains(driver_result, hDevice, pCount, phStandby); } /////////////////////////////////////////////////////////////////////////////// @@ -5467,12 +8320,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Standby.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesStandbyGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesStandbyGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hStandby, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbyGetPropertiesPrologue( hStandby, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetProperties(result, hStandby, pProperties); } @@ -5483,17 +8336,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesStandbyGetPropertiesPrologue( hStandby, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetProperties(result, hStandby, pProperties); } auto driver_result = pfnGetProperties( hStandby, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbyGetPropertiesEpilogue( hStandby, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetProperties(result, hStandby, pProperties); } - return logAndPropagateResult("zesStandbyGetProperties", driver_result); + return logAndPropagateResult_zesStandbyGetProperties(driver_result, hStandby, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -5509,12 +8362,12 @@ namespace validation_layer auto pfnGetMode = context.zesDdiTable.Standby.pfnGetMode; if( nullptr == pfnGetMode ) - return logAndPropagateResult("zesStandbyGetMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesStandbyGetMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hStandby, pMode); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbyGetModePrologue( hStandby, pMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetMode(result, hStandby, pMode); } @@ -5525,17 +8378,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesStandbyGetModePrologue( hStandby, pMode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetMode(result, hStandby, pMode); } auto driver_result = pfnGetMode( hStandby, pMode ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbyGetModeEpilogue( hStandby, pMode ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbyGetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbyGetMode(result, hStandby, pMode); } - return logAndPropagateResult("zesStandbyGetMode", driver_result); + return logAndPropagateResult_zesStandbyGetMode(driver_result, hStandby, pMode); } /////////////////////////////////////////////////////////////////////////////// @@ -5551,12 +8404,12 @@ namespace validation_layer auto pfnSetMode = context.zesDdiTable.Standby.pfnSetMode; if( nullptr == pfnSetMode ) - return logAndPropagateResult("zesStandbySetMode", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesStandbySetMode(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hStandby, mode); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbySetModePrologue( hStandby, mode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbySetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbySetMode(result, hStandby, mode); } @@ -5567,17 +8420,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesStandbySetModePrologue( hStandby, mode ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbySetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbySetMode(result, hStandby, mode); } auto driver_result = pfnSetMode( hStandby, mode ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesStandbySetModeEpilogue( hStandby, mode ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesStandbySetMode", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesStandbySetMode(result, hStandby, mode); } - return logAndPropagateResult("zesStandbySetMode", driver_result); + return logAndPropagateResult_zesStandbySetMode(driver_result, hStandby, mode); } /////////////////////////////////////////////////////////////////////////////// @@ -5603,12 +8456,12 @@ namespace validation_layer auto pfnEnumTemperatureSensors = context.zesDdiTable.Device.pfnEnumTemperatureSensors; if( nullptr == pfnEnumTemperatureSensors ) - return logAndPropagateResult("zesDeviceEnumTemperatureSensors", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumTemperatureSensors(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phTemperature); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumTemperatureSensorsPrologue( hDevice, pCount, phTemperature ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumTemperatureSensors", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumTemperatureSensors(result, hDevice, pCount, phTemperature); } @@ -5619,17 +8472,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumTemperatureSensorsPrologue( hDevice, pCount, phTemperature ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumTemperatureSensors", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumTemperatureSensors(result, hDevice, pCount, phTemperature); } auto driver_result = pfnEnumTemperatureSensors( hDevice, pCount, phTemperature ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumTemperatureSensorsEpilogue( hDevice, pCount, phTemperature ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumTemperatureSensors", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumTemperatureSensors(result, hDevice, pCount, phTemperature); } - return logAndPropagateResult("zesDeviceEnumTemperatureSensors", driver_result); + return logAndPropagateResult_zesDeviceEnumTemperatureSensors(driver_result, hDevice, pCount, phTemperature); } /////////////////////////////////////////////////////////////////////////////// @@ -5645,12 +8498,12 @@ namespace validation_layer auto pfnGetProperties = context.zesDdiTable.Temperature.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zesTemperatureGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesTemperatureGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTemperature, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetPropertiesPrologue( hTemperature, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetProperties(result, hTemperature, pProperties); } @@ -5661,17 +8514,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesTemperatureGetPropertiesPrologue( hTemperature, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetProperties(result, hTemperature, pProperties); } auto driver_result = pfnGetProperties( hTemperature, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetPropertiesEpilogue( hTemperature, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetProperties(result, hTemperature, pProperties); } - return logAndPropagateResult("zesTemperatureGetProperties", driver_result); + return logAndPropagateResult_zesTemperatureGetProperties(driver_result, hTemperature, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -5687,12 +8540,12 @@ namespace validation_layer auto pfnGetConfig = context.zesDdiTable.Temperature.pfnGetConfig; if( nullptr == pfnGetConfig ) - return logAndPropagateResult("zesTemperatureGetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesTemperatureGetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTemperature, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetConfigPrologue( hTemperature, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetConfig(result, hTemperature, pConfig); } @@ -5703,17 +8556,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesTemperatureGetConfigPrologue( hTemperature, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetConfig(result, hTemperature, pConfig); } auto driver_result = pfnGetConfig( hTemperature, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetConfigEpilogue( hTemperature, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetConfig(result, hTemperature, pConfig); } - return logAndPropagateResult("zesTemperatureGetConfig", driver_result); + return logAndPropagateResult_zesTemperatureGetConfig(driver_result, hTemperature, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -5729,12 +8582,12 @@ namespace validation_layer auto pfnSetConfig = context.zesDdiTable.Temperature.pfnSetConfig; if( nullptr == pfnSetConfig ) - return logAndPropagateResult("zesTemperatureSetConfig", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesTemperatureSetConfig(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTemperature, pConfig); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureSetConfigPrologue( hTemperature, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureSetConfig(result, hTemperature, pConfig); } @@ -5745,17 +8598,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesTemperatureSetConfigPrologue( hTemperature, pConfig ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureSetConfig(result, hTemperature, pConfig); } auto driver_result = pfnSetConfig( hTemperature, pConfig ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureSetConfigEpilogue( hTemperature, pConfig ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureSetConfig", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureSetConfig(result, hTemperature, pConfig); } - return logAndPropagateResult("zesTemperatureSetConfig", driver_result); + return logAndPropagateResult_zesTemperatureSetConfig(driver_result, hTemperature, pConfig); } /////////////////////////////////////////////////////////////////////////////// @@ -5772,12 +8625,12 @@ namespace validation_layer auto pfnGetState = context.zesDdiTable.Temperature.pfnGetState; if( nullptr == pfnGetState ) - return logAndPropagateResult("zesTemperatureGetState", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesTemperatureGetState(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTemperature, pTemperature); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetStatePrologue( hTemperature, pTemperature ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetState(result, hTemperature, pTemperature); } @@ -5788,17 +8641,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesTemperatureGetStatePrologue( hTemperature, pTemperature ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetState(result, hTemperature, pTemperature); } auto driver_result = pfnGetState( hTemperature, pTemperature ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesTemperatureGetStateEpilogue( hTemperature, pTemperature ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesTemperatureGetState", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesTemperatureGetState(result, hTemperature, pTemperature); } - return logAndPropagateResult("zesTemperatureGetState", driver_result); + return logAndPropagateResult_zesTemperatureGetState(driver_result, hTemperature, pTemperature); } /////////////////////////////////////////////////////////////////////////////// @@ -5822,12 +8675,12 @@ namespace validation_layer auto pfnGetLimitsExt = context.zesDdiTable.Power.pfnGetLimitsExt; if( nullptr == pfnGetLimitsExt ) - return logAndPropagateResult("zesPowerGetLimitsExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerGetLimitsExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pCount, pSustained); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetLimitsExtPrologue( hPower, pCount, pSustained ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimitsExt(result, hPower, pCount, pSustained); } @@ -5838,17 +8691,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerGetLimitsExtPrologue( hPower, pCount, pSustained ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimitsExt(result, hPower, pCount, pSustained); } auto driver_result = pfnGetLimitsExt( hPower, pCount, pSustained ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerGetLimitsExtEpilogue( hPower, pCount, pSustained ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerGetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerGetLimitsExt(result, hPower, pCount, pSustained); } - return logAndPropagateResult("zesPowerGetLimitsExt", driver_result); + return logAndPropagateResult_zesPowerGetLimitsExt(driver_result, hPower, pCount, pSustained); } /////////////////////////////////////////////////////////////////////////////// @@ -5865,12 +8718,12 @@ namespace validation_layer auto pfnSetLimitsExt = context.zesDdiTable.Power.pfnSetLimitsExt; if( nullptr == pfnSetLimitsExt ) - return logAndPropagateResult("zesPowerSetLimitsExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesPowerSetLimitsExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hPower, pCount, pSustained); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetLimitsExtPrologue( hPower, pCount, pSustained ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimitsExt(result, hPower, pCount, pSustained); } @@ -5881,17 +8734,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesPowerSetLimitsExtPrologue( hPower, pCount, pSustained ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimitsExt(result, hPower, pCount, pSustained); } auto driver_result = pfnSetLimitsExt( hPower, pCount, pSustained ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesPowerSetLimitsExtEpilogue( hPower, pCount, pSustained ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesPowerSetLimitsExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesPowerSetLimitsExt(result, hPower, pCount, pSustained); } - return logAndPropagateResult("zesPowerSetLimitsExt", driver_result); + return logAndPropagateResult_zesPowerSetLimitsExt(driver_result, hPower, pCount, pSustained); } /////////////////////////////////////////////////////////////////////////////// @@ -5920,12 +8773,12 @@ namespace validation_layer auto pfnGetActivityExt = context.zesDdiTable.Engine.pfnGetActivityExt; if( nullptr == pfnGetActivityExt ) - return logAndPropagateResult("zesEngineGetActivityExt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesEngineGetActivityExt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hEngine, pCount, pStats); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetActivityExtPrologue( hEngine, pCount, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivityExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivityExt(result, hEngine, pCount, pStats); } @@ -5936,17 +8789,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesEngineGetActivityExtPrologue( hEngine, pCount, pStats ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivityExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivityExt(result, hEngine, pCount, pStats); } auto driver_result = pfnGetActivityExt( hEngine, pCount, pStats ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesEngineGetActivityExtEpilogue( hEngine, pCount, pStats ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesEngineGetActivityExt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesEngineGetActivityExt(result, hEngine, pCount, pStats); } - return logAndPropagateResult("zesEngineGetActivityExt", driver_result); + return logAndPropagateResult_zesEngineGetActivityExt(driver_result, hEngine, pCount, pStats); } /////////////////////////////////////////////////////////////////////////////// @@ -5970,12 +8823,12 @@ namespace validation_layer auto pfnGetStateExp = context.zesDdiTable.RasExp.pfnGetStateExp; if( nullptr == pfnGetStateExp ) - return logAndPropagateResult("zesRasGetStateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasGetStateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, pCount, pState); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetStateExpPrologue( hRas, pCount, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetStateExp(result, hRas, pCount, pState); } @@ -5986,21 +8839,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasGetStateExpPrologue( hRas, pCount, pState ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetStateExp(result, hRas, pCount, pState); } auto driver_result = pfnGetStateExp( hRas, pCount, pState ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasGetStateExpEpilogue( hRas, pCount, pState ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasGetStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasGetStateExp(result, hRas, pCount, pState); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesRasGetStateExp", driver_result); + return logAndPropagateResult_zesRasGetStateExp(driver_result, hRas, pCount, pState); } /////////////////////////////////////////////////////////////////////////////// @@ -6016,12 +8869,12 @@ namespace validation_layer auto pfnClearStateExp = context.zesDdiTable.RasExp.pfnClearStateExp; if( nullptr == pfnClearStateExp ) - return logAndPropagateResult("zesRasClearStateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesRasClearStateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hRas, category); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasClearStateExpPrologue( hRas, category ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasClearStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasClearStateExp(result, hRas, category); } @@ -6032,17 +8885,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesRasClearStateExpPrologue( hRas, category ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasClearStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasClearStateExp(result, hRas, category); } auto driver_result = pfnClearStateExp( hRas, category ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesRasClearStateExpEpilogue( hRas, category ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesRasClearStateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesRasClearStateExp(result, hRas, category); } - return logAndPropagateResult("zesRasClearStateExp", driver_result); + return logAndPropagateResult_zesRasClearStateExp(driver_result, hRas, category); } /////////////////////////////////////////////////////////////////////////////// @@ -6059,12 +8912,12 @@ namespace validation_layer auto pfnGetSecurityVersionExp = context.zesDdiTable.FirmwareExp.pfnGetSecurityVersionExp; if( nullptr == pfnGetSecurityVersionExp ) - return logAndPropagateResult("zesFirmwareGetSecurityVersionExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareGetSecurityVersionExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware, pVersion); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetSecurityVersionExpPrologue( hFirmware, pVersion ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetSecurityVersionExp(result, hFirmware, pVersion); } @@ -6075,21 +8928,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareGetSecurityVersionExpPrologue( hFirmware, pVersion ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetSecurityVersionExp(result, hFirmware, pVersion); } auto driver_result = pfnGetSecurityVersionExp( hFirmware, pVersion ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareGetSecurityVersionExpEpilogue( hFirmware, pVersion ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareGetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareGetSecurityVersionExp(result, hFirmware, pVersion); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesFirmwareGetSecurityVersionExp", driver_result); + return logAndPropagateResult_zesFirmwareGetSecurityVersionExp(driver_result, hFirmware, pVersion); } /////////////////////////////////////////////////////////////////////////////// @@ -6104,12 +8957,12 @@ namespace validation_layer auto pfnSetSecurityVersionExp = context.zesDdiTable.FirmwareExp.pfnSetSecurityVersionExp; if( nullptr == pfnSetSecurityVersionExp ) - return logAndPropagateResult("zesFirmwareSetSecurityVersionExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesFirmwareSetSecurityVersionExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hFirmware); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareSetSecurityVersionExpPrologue( hFirmware ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareSetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareSetSecurityVersionExp(result, hFirmware); } @@ -6120,17 +8973,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesFirmwareSetSecurityVersionExpPrologue( hFirmware ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareSetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareSetSecurityVersionExp(result, hFirmware); } auto driver_result = pfnSetSecurityVersionExp( hFirmware ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesFirmwareSetSecurityVersionExpEpilogue( hFirmware ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesFirmwareSetSecurityVersionExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesFirmwareSetSecurityVersionExp(result, hFirmware); } - return logAndPropagateResult("zesFirmwareSetSecurityVersionExp", driver_result); + return logAndPropagateResult_zesFirmwareSetSecurityVersionExp(driver_result, hFirmware); } /////////////////////////////////////////////////////////////////////////////// @@ -6154,12 +9007,12 @@ namespace validation_layer auto pfnGetSubDevicePropertiesExp = context.zesDdiTable.DeviceExp.pfnGetSubDevicePropertiesExp; if( nullptr == pfnGetSubDevicePropertiesExp ) - return logAndPropagateResult("zesDeviceGetSubDevicePropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pSubdeviceProps); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetSubDevicePropertiesExpPrologue( hDevice, pCount, pSubdeviceProps ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetSubDevicePropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp(result, hDevice, pCount, pSubdeviceProps); } @@ -6170,21 +9023,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceGetSubDevicePropertiesExpPrologue( hDevice, pCount, pSubdeviceProps ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetSubDevicePropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp(result, hDevice, pCount, pSubdeviceProps); } auto driver_result = pfnGetSubDevicePropertiesExp( hDevice, pCount, pSubdeviceProps ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceGetSubDevicePropertiesExpEpilogue( hDevice, pCount, pSubdeviceProps ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceGetSubDevicePropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp(result, hDevice, pCount, pSubdeviceProps); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesDeviceGetSubDevicePropertiesExp", driver_result); + return logAndPropagateResult_zesDeviceGetSubDevicePropertiesExp(driver_result, hDevice, pCount, pSubdeviceProps); } /////////////////////////////////////////////////////////////////////////////// @@ -6204,12 +9057,12 @@ namespace validation_layer auto pfnGetDeviceByUuidExp = context.zesDdiTable.DriverExp.pfnGetDeviceByUuidExp; if( nullptr == pfnGetDeviceByUuidExp ) - return logAndPropagateResult("zesDriverGetDeviceByUuidExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDriverGetDeviceByUuidExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, uuid, phDevice, onSubdevice, subdeviceId); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetDeviceByUuidExpPrologue( hDriver, uuid, phDevice, onSubdevice, subdeviceId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetDeviceByUuidExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetDeviceByUuidExp(result, hDriver, uuid, phDevice, onSubdevice, subdeviceId); } @@ -6220,14 +9073,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDriverGetDeviceByUuidExpPrologue( hDriver, uuid, phDevice, onSubdevice, subdeviceId ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetDeviceByUuidExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetDeviceByUuidExp(result, hDriver, uuid, phDevice, onSubdevice, subdeviceId); } auto driver_result = pfnGetDeviceByUuidExp( hDriver, uuid, phDevice, onSubdevice, subdeviceId ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDriverGetDeviceByUuidExpEpilogue( hDriver, uuid, phDevice, onSubdevice, subdeviceId ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDriverGetDeviceByUuidExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDriverGetDeviceByUuidExp(result, hDriver, uuid, phDevice, onSubdevice, subdeviceId); } @@ -6239,7 +9092,7 @@ namespace validation_layer } } - return logAndPropagateResult("zesDriverGetDeviceByUuidExp", driver_result); + return logAndPropagateResult_zesDriverGetDeviceByUuidExp(driver_result, hDriver, uuid, phDevice, onSubdevice, subdeviceId); } /////////////////////////////////////////////////////////////////////////////// @@ -6265,12 +9118,12 @@ namespace validation_layer auto pfnEnumActiveVFExp = context.zesDdiTable.DeviceExp.pfnEnumActiveVFExp; if( nullptr == pfnEnumActiveVFExp ) - return logAndPropagateResult("zesDeviceEnumActiveVFExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumActiveVFExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phVFhandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumActiveVFExpPrologue( hDevice, pCount, phVFhandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumActiveVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumActiveVFExp(result, hDevice, pCount, phVFhandle); } @@ -6281,17 +9134,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumActiveVFExpPrologue( hDevice, pCount, phVFhandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumActiveVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumActiveVFExp(result, hDevice, pCount, phVFhandle); } auto driver_result = pfnEnumActiveVFExp( hDevice, pCount, phVFhandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumActiveVFExpEpilogue( hDevice, pCount, phVFhandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumActiveVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumActiveVFExp(result, hDevice, pCount, phVFhandle); } - return logAndPropagateResult("zesDeviceEnumActiveVFExp", driver_result); + return logAndPropagateResult_zesDeviceEnumActiveVFExp(driver_result, hDevice, pCount, phVFhandle); } /////////////////////////////////////////////////////////////////////////////// @@ -6307,12 +9160,12 @@ namespace validation_layer auto pfnGetVFPropertiesExp = context.zesDdiTable.VFManagementExp.pfnGetVFPropertiesExp; if( nullptr == pfnGetVFPropertiesExp ) - return logAndPropagateResult("zesVFManagementGetVFPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFPropertiesExpPrologue( hVFhandle, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFPropertiesExp(result, hVFhandle, pProperties); } @@ -6323,21 +9176,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFPropertiesExpPrologue( hVFhandle, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFPropertiesExp(result, hVFhandle, pProperties); } auto driver_result = pfnGetVFPropertiesExp( hVFhandle, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFPropertiesExpEpilogue( hVFhandle, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFPropertiesExp(result, hVFhandle, pProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesVFManagementGetVFPropertiesExp", driver_result); + return logAndPropagateResult_zesVFManagementGetVFPropertiesExp(driver_result, hVFhandle, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -6365,12 +9218,12 @@ namespace validation_layer auto pfnGetVFMemoryUtilizationExp = context.zesDdiTable.VFManagementExp.pfnGetVFMemoryUtilizationExp; if( nullptr == pfnGetVFMemoryUtilizationExp ) - return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCount, pMemUtil); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFMemoryUtilizationExpPrologue( hVFhandle, pCount, pMemUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp(result, hVFhandle, pCount, pMemUtil); } @@ -6381,21 +9234,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFMemoryUtilizationExpPrologue( hVFhandle, pCount, pMemUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp(result, hVFhandle, pCount, pMemUtil); } auto driver_result = pfnGetVFMemoryUtilizationExp( hVFhandle, pCount, pMemUtil ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFMemoryUtilizationExpEpilogue( hVFhandle, pCount, pMemUtil ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp(result, hVFhandle, pCount, pMemUtil); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp", driver_result); + return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp(driver_result, hVFhandle, pCount, pMemUtil); } /////////////////////////////////////////////////////////////////////////////// @@ -6423,12 +9276,12 @@ namespace validation_layer auto pfnGetVFEngineUtilizationExp = context.zesDdiTable.VFManagementExp.pfnGetVFEngineUtilizationExp; if( nullptr == pfnGetVFEngineUtilizationExp ) - return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCount, pEngineUtil); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFEngineUtilizationExpPrologue( hVFhandle, pCount, pEngineUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp(result, hVFhandle, pCount, pEngineUtil); } @@ -6439,21 +9292,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFEngineUtilizationExpPrologue( hVFhandle, pCount, pEngineUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp(result, hVFhandle, pCount, pEngineUtil); } auto driver_result = pfnGetVFEngineUtilizationExp( hVFhandle, pCount, pEngineUtil ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFEngineUtilizationExpEpilogue( hVFhandle, pCount, pEngineUtil ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp(result, hVFhandle, pCount, pEngineUtil); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp", driver_result); + return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp(driver_result, hVFhandle, pCount, pEngineUtil); } /////////////////////////////////////////////////////////////////////////////// @@ -6471,12 +9324,12 @@ namespace validation_layer auto pfnSetVFTelemetryModeExp = context.zesDdiTable.VFManagementExp.pfnSetVFTelemetryModeExp; if( nullptr == pfnSetVFTelemetryModeExp ) - return logAndPropagateResult("zesVFManagementSetVFTelemetryModeExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, flags, enable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementSetVFTelemetryModeExpPrologue( hVFhandle, flags, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetryModeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp(result, hVFhandle, flags, enable); } @@ -6487,17 +9340,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementSetVFTelemetryModeExpPrologue( hVFhandle, flags, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetryModeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp(result, hVFhandle, flags, enable); } auto driver_result = pfnSetVFTelemetryModeExp( hVFhandle, flags, enable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementSetVFTelemetryModeExpEpilogue( hVFhandle, flags, enable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetryModeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp(result, hVFhandle, flags, enable); } - return logAndPropagateResult("zesVFManagementSetVFTelemetryModeExp", driver_result); + return logAndPropagateResult_zesVFManagementSetVFTelemetryModeExp(driver_result, hVFhandle, flags, enable); } /////////////////////////////////////////////////////////////////////////////// @@ -6515,12 +9368,12 @@ namespace validation_layer auto pfnSetVFTelemetrySamplingIntervalExp = context.zesDdiTable.VFManagementExp.pfnSetVFTelemetrySamplingIntervalExp; if( nullptr == pfnSetVFTelemetrySamplingIntervalExp ) - return logAndPropagateResult("zesVFManagementSetVFTelemetrySamplingIntervalExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, flag, samplingInterval); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementSetVFTelemetrySamplingIntervalExpPrologue( hVFhandle, flag, samplingInterval ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetrySamplingIntervalExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp(result, hVFhandle, flag, samplingInterval); } @@ -6531,17 +9384,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementSetVFTelemetrySamplingIntervalExpPrologue( hVFhandle, flag, samplingInterval ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetrySamplingIntervalExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp(result, hVFhandle, flag, samplingInterval); } auto driver_result = pfnSetVFTelemetrySamplingIntervalExp( hVFhandle, flag, samplingInterval ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementSetVFTelemetrySamplingIntervalExpEpilogue( hVFhandle, flag, samplingInterval ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementSetVFTelemetrySamplingIntervalExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp(result, hVFhandle, flag, samplingInterval); } - return logAndPropagateResult("zesVFManagementSetVFTelemetrySamplingIntervalExp", driver_result); + return logAndPropagateResult_zesVFManagementSetVFTelemetrySamplingIntervalExp(driver_result, hVFhandle, flag, samplingInterval); } /////////////////////////////////////////////////////////////////////////////// @@ -6567,12 +9420,12 @@ namespace validation_layer auto pfnEnumEnabledVFExp = context.zesDdiTable.DeviceExp.pfnEnumEnabledVFExp; if( nullptr == pfnEnumEnabledVFExp ) - return logAndPropagateResult("zesDeviceEnumEnabledVFExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesDeviceEnumEnabledVFExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phVFhandle); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumEnabledVFExpPrologue( hDevice, pCount, phVFhandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEnabledVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEnabledVFExp(result, hDevice, pCount, phVFhandle); } @@ -6583,17 +9436,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesDeviceEnumEnabledVFExpPrologue( hDevice, pCount, phVFhandle ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEnabledVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEnabledVFExp(result, hDevice, pCount, phVFhandle); } auto driver_result = pfnEnumEnabledVFExp( hDevice, pCount, phVFhandle ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesDeviceEnumEnabledVFExpEpilogue( hDevice, pCount, phVFhandle ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesDeviceEnumEnabledVFExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesDeviceEnumEnabledVFExp(result, hDevice, pCount, phVFhandle); } - return logAndPropagateResult("zesDeviceEnumEnabledVFExp", driver_result); + return logAndPropagateResult_zesDeviceEnumEnabledVFExp(driver_result, hDevice, pCount, phVFhandle); } /////////////////////////////////////////////////////////////////////////////// @@ -6609,12 +9462,12 @@ namespace validation_layer auto pfnGetVFCapabilitiesExp = context.zesDdiTable.VFManagementExp.pfnGetVFCapabilitiesExp; if( nullptr == pfnGetVFCapabilitiesExp ) - return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCapability); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFCapabilitiesExpPrologue( hVFhandle, pCapability ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp(result, hVFhandle, pCapability); } @@ -6625,21 +9478,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFCapabilitiesExpPrologue( hVFhandle, pCapability ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp(result, hVFhandle, pCapability); } auto driver_result = pfnGetVFCapabilitiesExp( hVFhandle, pCapability ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFCapabilitiesExpEpilogue( hVFhandle, pCapability ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp(result, hVFhandle, pCapability); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp", driver_result); + return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp(driver_result, hVFhandle, pCapability); } /////////////////////////////////////////////////////////////////////////////// @@ -6665,12 +9518,12 @@ namespace validation_layer auto pfnGetVFMemoryUtilizationExp2 = context.zesDdiTable.VFManagementExp.pfnGetVFMemoryUtilizationExp2; if( nullptr == pfnGetVFMemoryUtilizationExp2 ) - return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp2", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCount, pMemUtil); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFMemoryUtilizationExp2Prologue( hVFhandle, pCount, pMemUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2(result, hVFhandle, pCount, pMemUtil); } @@ -6681,17 +9534,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFMemoryUtilizationExp2Prologue( hVFhandle, pCount, pMemUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2(result, hVFhandle, pCount, pMemUtil); } auto driver_result = pfnGetVFMemoryUtilizationExp2( hVFhandle, pCount, pMemUtil ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFMemoryUtilizationExp2Epilogue( hVFhandle, pCount, pMemUtil ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2(result, hVFhandle, pCount, pMemUtil); } - return logAndPropagateResult("zesVFManagementGetVFMemoryUtilizationExp2", driver_result); + return logAndPropagateResult_zesVFManagementGetVFMemoryUtilizationExp2(driver_result, hVFhandle, pCount, pMemUtil); } /////////////////////////////////////////////////////////////////////////////// @@ -6717,12 +9570,12 @@ namespace validation_layer auto pfnGetVFEngineUtilizationExp2 = context.zesDdiTable.VFManagementExp.pfnGetVFEngineUtilizationExp2; if( nullptr == pfnGetVFEngineUtilizationExp2 ) - return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp2", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCount, pEngineUtil); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFEngineUtilizationExp2Prologue( hVFhandle, pCount, pEngineUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2(result, hVFhandle, pCount, pEngineUtil); } @@ -6733,17 +9586,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFEngineUtilizationExp2Prologue( hVFhandle, pCount, pEngineUtil ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2(result, hVFhandle, pCount, pEngineUtil); } auto driver_result = pfnGetVFEngineUtilizationExp2( hVFhandle, pCount, pEngineUtil ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFEngineUtilizationExp2Epilogue( hVFhandle, pCount, pEngineUtil ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2(result, hVFhandle, pCount, pEngineUtil); } - return logAndPropagateResult("zesVFManagementGetVFEngineUtilizationExp2", driver_result); + return logAndPropagateResult_zesVFManagementGetVFEngineUtilizationExp2(driver_result, hVFhandle, pCount, pEngineUtil); } /////////////////////////////////////////////////////////////////////////////// @@ -6759,12 +9612,12 @@ namespace validation_layer auto pfnGetVFCapabilitiesExp2 = context.zesDdiTable.VFManagementExp.pfnGetVFCapabilitiesExp2; if( nullptr == pfnGetVFCapabilitiesExp2 ) - return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp2", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hVFhandle, pCapability); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFCapabilitiesExp2Prologue( hVFhandle, pCapability ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2(result, hVFhandle, pCapability); } @@ -6775,17 +9628,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zesHandleLifetime.zesVFManagementGetVFCapabilitiesExp2Prologue( hVFhandle, pCapability ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2(result, hVFhandle, pCapability); } auto driver_result = pfnGetVFCapabilitiesExp2( hVFhandle, pCapability ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zesValidation->zesVFManagementGetVFCapabilitiesExp2Epilogue( hVFhandle, pCapability ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2(result, hVFhandle, pCapability); } - return logAndPropagateResult("zesVFManagementGetVFCapabilitiesExp2", driver_result); + return logAndPropagateResult_zesVFManagementGetVFCapabilitiesExp2(driver_result, hVFhandle, pCapability); } } // namespace validation_layer diff --git a/source/layers/validation/zet_valddi.cpp b/source/layers/validation/zet_valddi.cpp index d2310ae6..11bde17f 100644 --- a/source/layers/validation/zet_valddi.cpp +++ b/source/layers/validation/zet_valddi.cpp @@ -10,13 +10,1556 @@ * */ #include "ze_validation_layer.h" +#include + +// Define a macro for marking potentially unused functions +#if defined(_MSC_VER) + // MSVC doesn't support __attribute__((unused)), just omit the marking + #define VALIDATION_MAYBE_UNUSED +#elif defined(__GNUC__) || defined(__clang__) + // GCC and Clang support __attribute__((unused)) + #define VALIDATION_MAYBE_UNUSED __attribute__((unused)) +#else + #define VALIDATION_MAYBE_UNUSED +#endif namespace validation_layer { - static ze_result_t logAndPropagateResult(const char* fname, ze_result_t result) { - if (result != ZE_RESULT_SUCCESS) { - context.logger->log_trace("Error (" + loader::to_string(result) + ") in " + std::string(fname)); - } + // Generate specific logAndPropagateResult functions for each API function + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetModuleGetDebugInfo( + ze_result_t result, + zet_module_handle_t hModule, ///< [in] handle of the module + zet_module_debug_info_format_t format, ///< [in] debug info format requested + size_t* pSize, ///< [in,out] size of debug info in bytes + uint8_t* pDebugInfo ///< [in,out][optional] byte pointer to debug info +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetModuleGetDebugInfo("; + oss << "hModule=" << loader::to_string(hModule); + oss << ", "; + oss << "format=" << loader::to_string(format); + oss << ", "; + oss << "pSize=" << loader::to_string(pSize); + oss << ", "; + oss << "pDebugInfo=" << loader::to_string(pDebugInfo); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDeviceGetDebugProperties( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] device handle + zet_device_debug_properties_t* pDebugProperties ///< [in,out] query result for debug properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDeviceGetDebugProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pDebugProperties=" << loader::to_string(pDebugProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugAttach( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] device handle + const zet_debug_config_t* config, ///< [in] the debug configuration + zet_debug_session_handle_t* phDebug ///< [out] debug session handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugAttach("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "config=" << loader::to_string(config); + oss << ", "; + oss << "phDebug=" << loader::to_string(phDebug); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugDetach( + ze_result_t result, + zet_debug_session_handle_t hDebug ///< [in][release] debug session handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugDetach("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugReadEvent( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + uint64_t timeout, ///< [in] if non-zero, then indicates the maximum time (in milliseconds) to + ///< yield before returning ::ZE_RESULT_SUCCESS or ::ZE_RESULT_NOT_READY; + ///< if zero, then immediately returns the status of the event; + ///< if `UINT64_MAX`, then function will not return until complete or + ///< device is lost. + ///< Due to external dependencies, timeout may be rounded to the closest + ///< value allowed by the accuracy of those dependencies. + zet_debug_event_t* event ///< [in,out] a pointer to a ::zet_debug_event_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugReadEvent("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "timeout=" << loader::to_string(timeout); + oss << ", "; + oss << "event=" << loader::to_string(event); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugAcknowledgeEvent( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + const zet_debug_event_t* event ///< [in] a pointer to a ::zet_debug_event_t. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugAcknowledgeEvent("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "event=" << loader::to_string(event); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugInterrupt( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread ///< [in] the thread to interrupt +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugInterrupt("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugResume( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread ///< [in] the thread to resume +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugResume("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugReadMemory( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread, ///< [in] the thread identifier. + const zet_debug_memory_space_desc_t* desc, ///< [in] memory space descriptor + size_t size, ///< [in] the number of bytes to read + void* buffer ///< [in,out] a buffer to hold a copy of the memory +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugReadMemory("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "buffer=" << loader::to_string(buffer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugWriteMemory( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread, ///< [in] the thread identifier. + const zet_debug_memory_space_desc_t* desc, ///< [in] memory space descriptor + size_t size, ///< [in] the number of bytes to write + const void* buffer ///< [in] a buffer holding the pattern to write +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugWriteMemory("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "size=" << loader::to_string(size); + oss << ", "; + oss << "buffer=" << loader::to_string(buffer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugGetRegisterSetProperties( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] device handle + uint32_t* pCount, ///< [in,out] pointer to the number of register set properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of register set properties available. + ///< if count is greater than the number of register set properties + ///< available, then the driver shall update the value with the correct + ///< number of registry set properties available. + zet_debug_regset_properties_t* pRegisterSetProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< register set properties. + ///< if count is less than the number of register set properties available, + ///< then driver shall only retrieve that number of register set properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugGetRegisterSetProperties("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pRegisterSetProperties=" << loader::to_string(pRegisterSetProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugGetThreadRegisterSetProperties( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread, ///< [in] the thread identifier specifying a single stopped thread + uint32_t* pCount, ///< [in,out] pointer to the number of register set properties. + ///< if count is zero, then the driver shall update the value with the + ///< total number of register set properties available. + ///< if count is greater than the number of register set properties + ///< available, then the driver shall update the value with the correct + ///< number of registry set properties available. + zet_debug_regset_properties_t* pRegisterSetProperties ///< [in,out][optional][range(0, *pCount)] array of query results for + ///< register set properties. + ///< if count is less than the number of register set properties available, + ///< then driver shall only retrieve that number of register set properties. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugGetThreadRegisterSetProperties("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "pRegisterSetProperties=" << loader::to_string(pRegisterSetProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugReadRegisters( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread, ///< [in] the thread identifier + uint32_t type, ///< [in] register set type + uint32_t start, ///< [in] the starting offset into the register state area; must be less + ///< than the `count` member of ::zet_debug_regset_properties_t for the + ///< type + uint32_t count, ///< [in] the number of registers to read; start+count must be less than or + ///< equal to the `count` member of ::zet_debug_regset_properties_t for the + ///< type + void* pRegisterValues ///< [in,out][optional][range(0, count)] buffer of register values +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugReadRegisters("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ", "; + oss << "type=" << loader::to_string(type); + oss << ", "; + oss << "start=" << loader::to_string(start); + oss << ", "; + oss << "count=" << loader::to_string(count); + oss << ", "; + oss << "pRegisterValues=" << loader::to_string(pRegisterValues); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDebugWriteRegisters( + ze_result_t result, + zet_debug_session_handle_t hDebug, ///< [in] debug session handle + ze_device_thread_t thread, ///< [in] the thread identifier + uint32_t type, ///< [in] register set type + uint32_t start, ///< [in] the starting offset into the register state area; must be less + ///< than the `count` member of ::zet_debug_regset_properties_t for the + ///< type + uint32_t count, ///< [in] the number of registers to write; start+count must be less than + ///< or equal to the `count` member of ::zet_debug_regset_properties_t for + ///< the type + void* pRegisterValues ///< [in,out][optional][range(0, count)] buffer of register values +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDebugWriteRegisters("; + oss << "hDebug=" << loader::to_string(hDebug); + oss << ", "; + oss << "thread=" << loader::to_string(thread); + oss << ", "; + oss << "type=" << loader::to_string(type); + oss << ", "; + oss << "start=" << loader::to_string(start); + oss << ", "; + oss << "count=" << loader::to_string(count); + oss << ", "; + oss << "pRegisterValues=" << loader::to_string(pRegisterValues); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupGet( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of metric groups. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric groups available. + ///< if count is greater than the number of metric groups available, then + ///< the driver shall update the value with the correct number of metric + ///< groups available. + zet_metric_group_handle_t* phMetricGroups ///< [in,out][optional][range(0, *pCount)] array of handle of metric groups. + ///< if count is less than the number of metric groups available, then + ///< driver shall only retrieve that number of metric groups. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupGet("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phMetricGroups=" << loader::to_string(phMetricGroups); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupGetProperties( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + zet_metric_group_properties_t* pProperties ///< [in,out] metric group properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupGetProperties("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupCalculateMetricValues( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + zet_metric_group_calculation_type_t type, ///< [in] calculation type to be applied on raw data + size_t rawDataSize, ///< [in] size in bytes of raw data buffer + const uint8_t* pRawData, ///< [in][range(0, rawDataSize)] buffer of raw data to calculate + uint32_t* pMetricValueCount, ///< [in,out] pointer to number of metric values calculated. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric values to be calculated. + ///< if count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with the actual number of + ///< metric values to be calculated. + zet_typed_value_t* pMetricValues ///< [in,out][optional][range(0, *pMetricValueCount)] buffer of calculated metrics. + ///< if count is less than the number available in the raw data buffer, + ///< then driver shall only calculate that number of metric values. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupCalculateMetricValues("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "type=" << loader::to_string(type); + oss << ", "; + oss << "rawDataSize=" << loader::to_string(rawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ", "; + oss << "pMetricValueCount=" << loader::to_string(pMetricValueCount); + oss << ", "; + oss << "pMetricValues=" << loader::to_string(pMetricValues); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGet( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + uint32_t* pCount, ///< [in,out] pointer to the number of metrics. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metrics available. + ///< if count is greater than the number of metrics available, then the + ///< driver shall update the value with the correct number of metrics available. + zet_metric_handle_t* phMetrics ///< [in,out][optional][range(0, *pCount)] array of handle of metrics. + ///< if count is less than the number of metrics available, then driver + ///< shall only retrieve that number of metrics. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGet("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phMetrics=" << loader::to_string(phMetrics); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGetProperties( + ze_result_t result, + zet_metric_handle_t hMetric, ///< [in] handle of the metric + zet_metric_properties_t* pProperties ///< [in,out] metric properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGetProperties("; + oss << "hMetric=" << loader::to_string(hMetric); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetContextActivateMetricGroups( + ze_result_t result, + zet_context_handle_t hContext, ///< [in] handle of the context object + zet_device_handle_t hDevice, ///< [in] handle of the device + uint32_t count, ///< [in] metric group count to activate; must be 0 if `nullptr == + ///< phMetricGroups` + zet_metric_group_handle_t* phMetricGroups ///< [in][optional][range(0, count)] handles of the metric groups to activate. + ///< nullptr deactivates all previously used metric groups. + ///< all metrics groups must come from a different domains. + ///< metric query and metric stream must use activated metric groups. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetContextActivateMetricGroups("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "count=" << loader::to_string(count); + oss << ", "; + oss << "phMetricGroups=" << loader::to_string(phMetricGroups); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricStreamerOpen( + ze_result_t result, + zet_context_handle_t hContext, ///< [in] handle of the context object + zet_device_handle_t hDevice, ///< [in] handle of the device + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + zet_metric_streamer_desc_t* desc, ///< [in,out] metric streamer descriptor + ze_event_handle_t hNotificationEvent, ///< [in][optional] event used for report availability notification + zet_metric_streamer_handle_t* phMetricStreamer ///< [out] handle of metric streamer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricStreamerOpen("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "hNotificationEvent=" << loader::to_string(hNotificationEvent); + oss << ", "; + oss << "phMetricStreamer=" << loader::to_string(phMetricStreamer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetCommandListAppendMetricStreamerMarker( + ze_result_t result, + zet_command_list_handle_t hCommandList, ///< [in] handle of the command list + zet_metric_streamer_handle_t hMetricStreamer, ///< [in] handle of the metric streamer + uint32_t value ///< [in] streamer marker value +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetCommandListAppendMetricStreamerMarker("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hMetricStreamer=" << loader::to_string(hMetricStreamer); + oss << ", "; + oss << "value=" << loader::to_string(value); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricStreamerClose( + ze_result_t result, + zet_metric_streamer_handle_t hMetricStreamer ///< [in][release] handle of the metric streamer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricStreamerClose("; + oss << "hMetricStreamer=" << loader::to_string(hMetricStreamer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricStreamerReadData( + ze_result_t result, + zet_metric_streamer_handle_t hMetricStreamer, ///< [in] handle of the metric streamer + uint32_t maxReportCount, ///< [in] the maximum number of reports the application wants to receive. + ///< if `UINT32_MAX`, then function will retrieve all reports available + size_t* pRawDataSize, ///< [in,out] pointer to size in bytes of raw data requested to read. + ///< if size is zero, then the driver will update the value with the total + ///< size in bytes needed for all reports available. + ///< if size is non-zero, then driver will only retrieve the number of + ///< reports that fit into the buffer. + ///< if size is larger than size needed for all reports, then driver will + ///< update the value with the actual size needed. + uint8_t* pRawData ///< [in,out][optional][range(0, *pRawDataSize)] buffer containing streamer + ///< reports in raw format +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricStreamerReadData("; + oss << "hMetricStreamer=" << loader::to_string(hMetricStreamer); + oss << ", "; + oss << "maxReportCount=" << loader::to_string(maxReportCount); + oss << ", "; + oss << "pRawDataSize=" << loader::to_string(pRawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryPoolCreate( + ze_result_t result, + zet_context_handle_t hContext, ///< [in] handle of the context object + zet_device_handle_t hDevice, ///< [in] handle of the device + zet_metric_group_handle_t hMetricGroup, ///< [in] metric group associated with the query object. + const zet_metric_query_pool_desc_t* desc, ///< [in] metric query pool descriptor + zet_metric_query_pool_handle_t* phMetricQueryPool ///< [out] handle of metric query pool +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryPoolCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phMetricQueryPool=" << loader::to_string(phMetricQueryPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryPoolDestroy( + ze_result_t result, + zet_metric_query_pool_handle_t hMetricQueryPool ///< [in][release] handle of the metric query pool +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryPoolDestroy("; + oss << "hMetricQueryPool=" << loader::to_string(hMetricQueryPool); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryCreate( + ze_result_t result, + zet_metric_query_pool_handle_t hMetricQueryPool,///< [in] handle of the metric query pool + uint32_t index, ///< [in] index of the query within the pool + zet_metric_query_handle_t* phMetricQuery ///< [out] handle of metric query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryCreate("; + oss << "hMetricQueryPool=" << loader::to_string(hMetricQueryPool); + oss << ", "; + oss << "index=" << loader::to_string(index); + oss << ", "; + oss << "phMetricQuery=" << loader::to_string(phMetricQuery); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryDestroy( + ze_result_t result, + zet_metric_query_handle_t hMetricQuery ///< [in][release] handle of metric query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryDestroy("; + oss << "hMetricQuery=" << loader::to_string(hMetricQuery); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryReset( + ze_result_t result, + zet_metric_query_handle_t hMetricQuery ///< [in] handle of metric query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryReset("; + oss << "hMetricQuery=" << loader::to_string(hMetricQuery); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetCommandListAppendMetricQueryBegin( + ze_result_t result, + zet_command_list_handle_t hCommandList, ///< [in] handle of the command list + zet_metric_query_handle_t hMetricQuery ///< [in] handle of the metric query +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetCommandListAppendMetricQueryBegin("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hMetricQuery=" << loader::to_string(hMetricQuery); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetCommandListAppendMetricQueryEnd( + ze_result_t result, + zet_command_list_handle_t hCommandList, ///< [in] handle of the command list + zet_metric_query_handle_t hMetricQuery, ///< [in] handle of the metric query + ze_event_handle_t hSignalEvent, ///< [in][optional] handle of the event to signal on completion + uint32_t numWaitEvents, ///< [in] must be zero + ze_event_handle_t* phWaitEvents ///< [in][mbz] must be nullptr +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetCommandListAppendMetricQueryEnd("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hMetricQuery=" << loader::to_string(hMetricQuery); + oss << ", "; + oss << "hSignalEvent=" << loader::to_string(hSignalEvent); + oss << ", "; + oss << "numWaitEvents=" << loader::to_string(numWaitEvents); + oss << ", "; + oss << "phWaitEvents=" << loader::to_string(phWaitEvents); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier( + ze_result_t result, + zet_command_list_handle_t hCommandList ///< [in] handle of the command list +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetCommandListAppendMetricMemoryBarrier("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricQueryGetData( + ze_result_t result, + zet_metric_query_handle_t hMetricQuery, ///< [in] handle of the metric query + size_t* pRawDataSize, ///< [in,out] pointer to size in bytes of raw data requested to read. + ///< if size is zero, then the driver will update the value with the total + ///< size in bytes needed for all reports available. + ///< if size is non-zero, then driver will only retrieve the number of + ///< reports that fit into the buffer. + ///< if size is larger than size needed for all reports, then driver will + ///< update the value with the actual size needed. + uint8_t* pRawData ///< [in,out][optional][range(0, *pRawDataSize)] buffer containing query + ///< reports in raw format +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricQueryGetData("; + oss << "hMetricQuery=" << loader::to_string(hMetricQuery); + oss << ", "; + oss << "pRawDataSize=" << loader::to_string(pRawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetKernelGetProfileInfo( + ze_result_t result, + zet_kernel_handle_t hKernel, ///< [in] handle to kernel + zet_profile_properties_t* pProfileProperties ///< [out] pointer to profile properties +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetKernelGetProfileInfo("; + oss << "hKernel=" << loader::to_string(hKernel); + oss << ", "; + oss << "pProfileProperties=" << loader::to_string(pProfileProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetTracerExpCreate( + ze_result_t result, + zet_context_handle_t hContext, ///< [in] handle of the context object + const zet_tracer_exp_desc_t* desc, ///< [in] pointer to tracer descriptor + zet_tracer_exp_handle_t* phTracer ///< [out] pointer to handle of tracer object created +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetTracerExpCreate("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "phTracer=" << loader::to_string(phTracer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetTracerExpDestroy( + ze_result_t result, + zet_tracer_exp_handle_t hTracer ///< [in][release] handle of tracer object to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetTracerExpDestroy("; + oss << "hTracer=" << loader::to_string(hTracer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetTracerExpSetPrologues( + ze_result_t result, + zet_tracer_exp_handle_t hTracer, ///< [in] handle of the tracer + zet_core_callbacks_t* pCoreCbs ///< [in] pointer to table of 'core' callback function pointers +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetTracerExpSetPrologues("; + oss << "hTracer=" << loader::to_string(hTracer); + oss << ", "; + oss << "pCoreCbs=" << loader::to_string(pCoreCbs); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetTracerExpSetEpilogues( + ze_result_t result, + zet_tracer_exp_handle_t hTracer, ///< [in] handle of the tracer + zet_core_callbacks_t* pCoreCbs ///< [in] pointer to table of 'core' callback function pointers +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetTracerExpSetEpilogues("; + oss << "hTracer=" << loader::to_string(hTracer); + oss << ", "; + oss << "pCoreCbs=" << loader::to_string(pCoreCbs); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetTracerExpSetEnabled( + ze_result_t result, + zet_tracer_exp_handle_t hTracer, ///< [in] handle of the tracer + ze_bool_t enable ///< [in] enable the tracer if true; disable if false +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetTracerExpSetEnabled("; + oss << "hTracer=" << loader::to_string(hTracer); + oss << ", "; + oss << "enable=" << loader::to_string(enable); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] handle of the device + uint32_t metricGroupCount, ///< [in] metric group count + zet_metric_group_handle_t * phMetricGroups, ///< [in,out] metrics groups to be re-arranged to be sets of concurrent + ///< groups + uint32_t * pMetricGroupsCountPerConcurrentGroup,///< [in,out][optional][*pConcurrentGroupCount] count of metric groups per + ///< concurrent group. + uint32_t * pConcurrentGroupCount ///< [out] number of concurrent groups. + ///< The value of this parameter could be used to determine the number of + ///< replays necessary. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDeviceGetConcurrentMetricGroupsExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "metricGroupCount=" << loader::to_string(metricGroupCount); + oss << ", "; + oss << "phMetricGroups=" << loader::to_string(phMetricGroups); + oss << ", "; + oss << "pMetricGroupsCountPerConcurrentGroup=" << loader::to_string(pMetricGroupsCountPerConcurrentGroup); + oss << ", "; + oss << "pConcurrentGroupCount=" << loader::to_string(pConcurrentGroupCount); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerCreateExp( + ze_result_t result, + zet_context_handle_t hContext, ///< [in] handle of the context object + zet_device_handle_t hDevice, ///< [in] handle of the device + uint32_t metricGroupCount, ///< [in] metric group count + zet_metric_group_handle_t* phMetricGroups, ///< [in][range(0, metricGroupCount )] handles of the metric groups to + ///< trace + zet_metric_tracer_exp_desc_t* desc, ///< [in,out] metric tracer descriptor + ze_event_handle_t hNotificationEvent, ///< [in][optional] event used for report availability notification. Note: + ///< If buffer is not drained when the event it flagged, there is a risk of + ///< HW event buffer being overrun + zet_metric_tracer_exp_handle_t* phMetricTracer ///< [out] handle of the metric tracer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerCreateExp("; + oss << "hContext=" << loader::to_string(hContext); + oss << ", "; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "metricGroupCount=" << loader::to_string(metricGroupCount); + oss << ", "; + oss << "phMetricGroups=" << loader::to_string(phMetricGroups); + oss << ", "; + oss << "desc=" << loader::to_string(desc); + oss << ", "; + oss << "hNotificationEvent=" << loader::to_string(hNotificationEvent); + oss << ", "; + oss << "phMetricTracer=" << loader::to_string(phMetricTracer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerDestroyExp( + ze_result_t result, + zet_metric_tracer_exp_handle_t hMetricTracer ///< [in] handle of the metric tracer +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerDestroyExp("; + oss << "hMetricTracer=" << loader::to_string(hMetricTracer); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerEnableExp( + ze_result_t result, + zet_metric_tracer_exp_handle_t hMetricTracer, ///< [in] handle of the metric tracer + ze_bool_t synchronous ///< [in] request synchronous behavior. Confirmation of successful + ///< asynchronous operation is done by calling ::zetMetricTracerReadDataExp() + ///< and checking the return status: ::ZE_RESULT_NOT_READY will be returned + ///< when the tracer is inactive. ::ZE_RESULT_SUCCESS will be returned + ///< when the tracer is active. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerEnableExp("; + oss << "hMetricTracer=" << loader::to_string(hMetricTracer); + oss << ", "; + oss << "synchronous=" << loader::to_string(synchronous); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerDisableExp( + ze_result_t result, + zet_metric_tracer_exp_handle_t hMetricTracer, ///< [in] handle of the metric tracer + ze_bool_t synchronous ///< [in] request synchronous behavior. Confirmation of successful + ///< asynchronous operation is done by calling ::zetMetricTracerReadDataExp() + ///< and checking the return status: ::ZE_RESULT_SUCCESS will be returned + ///< when the tracer is active or when it is inactive but still has data. + ///< ::ZE_RESULT_NOT_READY will be returned when the tracer is inactive and + ///< has no more data to be retrieved. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerDisableExp("; + oss << "hMetricTracer=" << loader::to_string(hMetricTracer); + oss << ", "; + oss << "synchronous=" << loader::to_string(synchronous); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerReadDataExp( + ze_result_t result, + zet_metric_tracer_exp_handle_t hMetricTracer, ///< [in] handle of the metric tracer + size_t* pRawDataSize, ///< [in,out] pointer to size in bytes of raw data requested to read. + ///< if size is zero, then the driver will update the value with the total + ///< size in bytes needed for all data available. + ///< if size is non-zero, then driver will only retrieve that amount of + ///< data. + ///< if size is larger than size needed for all data, then driver will + ///< update the value with the actual size needed. + uint8_t* pRawData ///< [in,out][optional][range(0, *pRawDataSize)] buffer containing tracer + ///< data in raw format +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerReadDataExp("; + oss << "hMetricTracer=" << loader::to_string(hMetricTracer); + oss << ", "; + oss << "pRawDataSize=" << loader::to_string(pRawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricDecoderCreateExp( + ze_result_t result, + zet_metric_tracer_exp_handle_t hMetricTracer, ///< [in] handle of the metric tracer + zet_metric_decoder_exp_handle_t* phMetricDecoder///< [out] handle of the metric decoder object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricDecoderCreateExp("; + oss << "hMetricTracer=" << loader::to_string(hMetricTracer); + oss << ", "; + oss << "phMetricDecoder=" << loader::to_string(phMetricDecoder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricDecoderDestroyExp( + ze_result_t result, + zet_metric_decoder_exp_handle_t phMetricDecoder ///< [in] handle of the metric decoder object +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricDecoderDestroyExp("; + oss << "phMetricDecoder=" << loader::to_string(phMetricDecoder); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp( + ze_result_t result, + zet_metric_decoder_exp_handle_t hMetricDecoder, ///< [in] handle of the metric decoder object + uint32_t* pCount, ///< [in,out] pointer to number of decodable metric in the hMetricDecoder + ///< handle. If count is zero, then the driver shall + ///< update the value with the total number of decodable metrics available + ///< in the decoder. if count is greater than zero + ///< but less than the total number of decodable metrics available in the + ///< decoder, then only that number will be returned. + ///< if count is greater than the number of decodable metrics available in + ///< the decoder, then the driver shall update the + ///< value with the actual number of decodable metrics available. + zet_metric_handle_t* phMetrics ///< [in,out] [range(0, *pCount)] array of handles of decodable metrics in + ///< the hMetricDecoder handle provided. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricDecoderGetDecodableMetricsExp("; + oss << "hMetricDecoder=" << loader::to_string(hMetricDecoder); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phMetrics=" << loader::to_string(phMetrics); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricTracerDecodeExp( + ze_result_t result, + zet_metric_decoder_exp_handle_t phMetricDecoder,///< [in] handle of the metric decoder object + size_t* pRawDataSize, ///< [in,out] size in bytes of raw data buffer. If pMetricEntriesCount is + ///< greater than zero but less than total number of + ///< decodable metrics available in the raw data buffer, then driver shall + ///< update this value with actual number of raw + ///< data bytes processed. + uint8_t* pRawData, ///< [in,out][optional][range(0, *pRawDataSize)] buffer containing tracer + ///< data in raw format + uint32_t metricsCount, ///< [in] number of decodable metrics in the tracer for which the + ///< hMetricDecoder handle was provided. See + ///< ::zetMetricDecoderGetDecodableMetricsExp(). If metricCount is greater + ///< than zero but less than the number decodable + ///< metrics available in the raw data buffer, then driver shall only + ///< decode those. + zet_metric_handle_t* phMetrics, ///< [in] [range(0, metricsCount)] array of handles of decodable metrics in + ///< the decoder for which the hMetricDecoder handle was + ///< provided. Metrics handles are expected to be for decodable metrics, + ///< see ::zetMetricDecoderGetDecodableMetricsExp() + uint32_t* pSetCount, ///< [in,out] pointer to number of metric sets. If count is zero, then the + ///< driver shall update the value with the total + ///< number of metric sets to be decoded. If count is greater than the + ///< number available in the raw data buffer, then the + ///< driver shall update the value with the actual number of metric sets to + ///< be decoded. There is a 1:1 relation between + ///< the number of sets and sub-devices returned in the decoded entries. + uint32_t* pMetricEntriesCountPerSet, ///< [in,out][optional][range(0, *pSetCount)] buffer of metric entries + ///< counts per metric set, one value per set. + uint32_t* pMetricEntriesCount, ///< [in,out] pointer to the total number of metric entries decoded, for + ///< all metric sets. If count is zero, then the + ///< driver shall update the value with the total number of metric entries + ///< to be decoded. If count is greater than zero + ///< but less than the total number of metric entries available in the raw + ///< data, then user provided number will be decoded. + ///< If count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with + ///< the actual number of decodable metric entries decoded. If set to null, + ///< then driver will only update the value of + ///< pSetCount. + zet_metric_entry_exp_t* pMetricEntries ///< [in,out][optional][range(0, *pMetricEntriesCount)] buffer containing + ///< decoded metric entries +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricTracerDecodeExp("; + oss << "phMetricDecoder=" << loader::to_string(phMetricDecoder); + oss << ", "; + oss << "pRawDataSize=" << loader::to_string(pRawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ", "; + oss << "metricsCount=" << loader::to_string(metricsCount); + oss << ", "; + oss << "phMetrics=" << loader::to_string(phMetrics); + oss << ", "; + oss << "pSetCount=" << loader::to_string(pSetCount); + oss << ", "; + oss << "pMetricEntriesCountPerSet=" << loader::to_string(pMetricEntriesCountPerSet); + oss << ", "; + oss << "pMetricEntriesCount=" << loader::to_string(pMetricEntriesCount); + oss << ", "; + oss << "pMetricEntries=" << loader::to_string(pMetricEntries); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetCommandListAppendMarkerExp( + ze_result_t result, + zet_command_list_handle_t hCommandList, ///< [in] handle to the command list + zet_metric_group_handle_t hMetricGroup, ///< [in] handle to the marker metric group. + ///< ::zet_metric_group_type_exp_flags_t could be used to check whether + ///< marker is supoported by the metric group. + uint32_t value ///< [in] marker value +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetCommandListAppendMarkerExp("; + oss << "hCommandList=" << loader::to_string(hCommandList); + oss << ", "; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "value=" << loader::to_string(value); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDeviceEnableMetricsExp( + ze_result_t result, + zet_device_handle_t hDevice ///< [in] handle of the device where metrics collection has to be enabled. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDeviceEnableMetricsExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDeviceDisableMetricsExp( + ze_result_t result, + zet_device_handle_t hDevice ///< [in] handle of the device where metrics collection has to be disabled +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDeviceDisableMetricsExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + zet_metric_group_calculation_type_t type, ///< [in] calculation type to be applied on raw data + size_t rawDataSize, ///< [in] size in bytes of raw data buffer + const uint8_t* pRawData, ///< [in][range(0, rawDataSize)] buffer of raw data to calculate + uint32_t* pSetCount, ///< [in,out] pointer to number of metric sets. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric sets to be calculated. + ///< if count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with the actual number of + ///< metric sets to be calculated. + uint32_t* pTotalMetricValueCount, ///< [in,out] pointer to number of the total number of metric values + ///< calculated, for all metric sets. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric values to be calculated. + ///< if count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with the actual number of + ///< metric values to be calculated. + uint32_t* pMetricCounts, ///< [in,out][optional][range(0, *pSetCount)] buffer of metric counts per + ///< metric set. + zet_typed_value_t* pMetricValues ///< [in,out][optional][range(0, *pTotalMetricValueCount)] buffer of + ///< calculated metrics. + ///< if count is less than the number available in the raw data buffer, + ///< then driver shall only calculate that number of metric values. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupCalculateMultipleMetricValuesExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "type=" << loader::to_string(type); + oss << ", "; + oss << "rawDataSize=" << loader::to_string(rawDataSize); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ", "; + oss << "pSetCount=" << loader::to_string(pSetCount); + oss << ", "; + oss << "pTotalMetricValueCount=" << loader::to_string(pTotalMetricValueCount); + oss << ", "; + oss << "pMetricCounts=" << loader::to_string(pMetricCounts); + oss << ", "; + oss << "pMetricValues=" << loader::to_string(pMetricValues); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + ze_bool_t synchronizedWithHost, ///< [in] Returns the timestamps synchronized to the host or the device. + uint64_t* globalTimestamp, ///< [out] Device timestamp. + uint64_t* metricTimestamp ///< [out] Metric timestamp. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupGetGlobalTimestampsExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "synchronizedWithHost=" << loader::to_string(synchronizedWithHost); + oss << ", "; + oss << "globalTimestamp=" << loader::to_string(globalTimestamp); + oss << ", "; + oss << "metricTimestamp=" << loader::to_string(metricTimestamp); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupGetExportDataExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] handle of the metric group + const uint8_t* pRawData, ///< [in] buffer of raw data + size_t rawDataSize, ///< [in] size in bytes of raw data buffer + size_t* pExportDataSize, ///< [in,out] size in bytes of export data buffer + ///< if size is zero, then the driver shall update the value with the + ///< number of bytes necessary to store the exported data. + ///< if size is greater than required, then the driver shall update the + ///< value with the actual number of bytes necessary to store the exported data. + uint8_t * pExportData ///< [in,out][optional][range(0, *pExportDataSize)] buffer of exported data. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupGetExportDataExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "pRawData=" << loader::to_string(pRawData); + oss << ", "; + oss << "rawDataSize=" << loader::to_string(rawDataSize); + oss << ", "; + oss << "pExportDataSize=" << loader::to_string(pExportDataSize); + oss << ", "; + oss << "pExportData=" << loader::to_string(pExportData); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp( + ze_result_t result, + ze_driver_handle_t hDriver, ///< [in] handle of the driver instance + zet_metric_group_calculation_type_t type, ///< [in] calculation type to be applied on raw data + size_t exportDataSize, ///< [in] size in bytes of exported data buffer + const uint8_t* pExportData, ///< [in][range(0, exportDataSize)] buffer of exported data to calculate + zet_metric_calculate_exp_desc_t* pCalculateDescriptor, ///< [in] descriptor specifying calculation specific parameters + uint32_t* pSetCount, ///< [in,out] pointer to number of metric sets. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric sets to be calculated. + ///< if count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with the actual number of + ///< metric sets to be calculated. + uint32_t* pTotalMetricValueCount, ///< [in,out] pointer to number of the total number of metric values + ///< calculated, for all metric sets. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric values to be calculated. + ///< if count is greater than the number available in the raw data buffer, + ///< then the driver shall update the value with the actual number of + ///< metric values to be calculated. + uint32_t* pMetricCounts, ///< [in,out][optional][range(0, *pSetCount)] buffer of metric counts per + ///< metric set. + zet_typed_value_t* pMetricValues ///< [in,out][optional][range(0, *pTotalMetricValueCount)] buffer of + ///< calculated metrics. + ///< if count is less than the number available in the raw data buffer, + ///< then driver shall only calculate that number of metric values. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupCalculateMetricExportDataExp("; + oss << "hDriver=" << loader::to_string(hDriver); + oss << ", "; + oss << "type=" << loader::to_string(type); + oss << ", "; + oss << "exportDataSize=" << loader::to_string(exportDataSize); + oss << ", "; + oss << "pExportData=" << loader::to_string(pExportData); + oss << ", "; + oss << "pCalculateDescriptor=" << loader::to_string(pCalculateDescriptor); + oss << ", "; + oss << "pSetCount=" << loader::to_string(pSetCount); + oss << ", "; + oss << "pTotalMetricValueCount=" << loader::to_string(pTotalMetricValueCount); + oss << ", "; + oss << "pMetricCounts=" << loader::to_string(pMetricCounts); + oss << ", "; + oss << "pMetricValues=" << loader::to_string(pMetricValues); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricProgrammableGetExp( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] handle of the device + uint32_t* pCount, ///< [in,out] pointer to the number of metric programmable handles. + ///< if count is zero, then the driver shall update the value with the + ///< total number of metric programmable handles available. + ///< if count is greater than the number of metric programmable handles + ///< available, then the driver shall update the value with the correct + ///< number of metric programmable handles available. + zet_metric_programmable_exp_handle_t* phMetricProgrammables ///< [in,out][optional][range(0, *pCount)] array of handle of metric programmables. + ///< if count is less than the number of metric programmables available, + ///< then driver shall only retrieve that number of metric programmables. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricProgrammableGetExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pCount=" << loader::to_string(pCount); + oss << ", "; + oss << "phMetricProgrammables=" << loader::to_string(phMetricProgrammables); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricProgrammableGetPropertiesExp( + ze_result_t result, + zet_metric_programmable_exp_handle_t hMetricProgrammable, ///< [in] handle of the metric programmable + zet_metric_programmable_exp_properties_t* pProperties ///< [in,out] properties of the metric programmable +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricProgrammableGetPropertiesExp("; + oss << "hMetricProgrammable=" << loader::to_string(hMetricProgrammable); + oss << ", "; + oss << "pProperties=" << loader::to_string(pProperties); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricProgrammableGetParamInfoExp( + ze_result_t result, + zet_metric_programmable_exp_handle_t hMetricProgrammable, ///< [in] handle of the metric programmable + uint32_t* pParameterCount, ///< [in,out] count of the parameters to retrieve parameter info. + ///< if value pParameterCount is greater than count of parameters + ///< available, then pParameterCount will be updated with count of + ///< parameters available. + ///< The count of parameters available can be queried using ::zetMetricProgrammableGetPropertiesExp. + zet_metric_programmable_param_info_exp_t* pParameterInfo///< [in,out][range(1, *pParameterCount)] array of parameter info. + ///< if parameterCount is less than the number of parameters available, + ///< then driver shall only retrieve that number of parameter info. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricProgrammableGetParamInfoExp("; + oss << "hMetricProgrammable=" << loader::to_string(hMetricProgrammable); + oss << ", "; + oss << "pParameterCount=" << loader::to_string(pParameterCount); + oss << ", "; + oss << "pParameterInfo=" << loader::to_string(pParameterInfo); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp( + ze_result_t result, + zet_metric_programmable_exp_handle_t hMetricProgrammable, ///< [in] handle of the metric programmable + uint32_t parameterOrdinal, ///< [in] ordinal of the parameter in the metric programmable + uint32_t* pValueInfoCount, ///< [in,out] count of parameter value information to retrieve. + ///< if value at pValueInfoCount is greater than count of value info + ///< available, then pValueInfoCount will be updated with count of value + ///< info available. + ///< The count of parameter value info available can be queried using ::zetMetricProgrammableGetParamInfoExp. + zet_metric_programmable_param_value_info_exp_t* pValueInfo ///< [in,out][range(1, *pValueInfoCount)] array of parameter value info. + ///< if pValueInfoCount is less than the number of value info available, + ///< then driver shall only retrieve that number of value info. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricProgrammableGetParamValueInfoExp("; + oss << "hMetricProgrammable=" << loader::to_string(hMetricProgrammable); + oss << ", "; + oss << "parameterOrdinal=" << loader::to_string(parameterOrdinal); + oss << ", "; + oss << "pValueInfoCount=" << loader::to_string(pValueInfoCount); + oss << ", "; + oss << "pValueInfo=" << loader::to_string(pValueInfo); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricCreateFromProgrammableExp2( + ze_result_t result, + zet_metric_programmable_exp_handle_t hMetricProgrammable, ///< [in] handle of the metric programmable + uint32_t parameterCount, ///< [in] Count of parameters to set. + zet_metric_programmable_param_value_exp_t* pParameterValues,///< [in] list of parameter values to be set. + const char* pName, ///< [in] pointer to metric name to be used. Must point to a + ///< null-terminated character array no longer than ::ZET_MAX_METRIC_NAME. + const char* pDescription, ///< [in] pointer to metric description to be used. Must point to a + ///< null-terminated character array no longer than + ///< ::ZET_MAX_METRIC_DESCRIPTION. + uint32_t* pMetricHandleCount, ///< [in,out] Pointer to the number of metric handles. + ///< if count is zero, then the driver shall update the value with the + ///< number of metric handles available for this programmable. + ///< if count is greater than the number of metric handles available, then + ///< the driver shall update the value with the correct number of metric + ///< handles available. + zet_metric_handle_t* phMetricHandles ///< [in,out][optional][range(0,*pMetricHandleCount)] array of handle of metrics. + ///< if count is less than the number of metrics available, then driver + ///< shall only retrieve that number of metric handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricCreateFromProgrammableExp2("; + oss << "hMetricProgrammable=" << loader::to_string(hMetricProgrammable); + oss << ", "; + oss << "parameterCount=" << loader::to_string(parameterCount); + oss << ", "; + oss << "pParameterValues=" << loader::to_string(pParameterValues); + oss << ", "; + oss << "pName=" << loader::to_string(pName); + oss << ", "; + oss << "pDescription=" << loader::to_string(pDescription); + oss << ", "; + oss << "pMetricHandleCount=" << loader::to_string(pMetricHandleCount); + oss << ", "; + oss << "phMetricHandles=" << loader::to_string(phMetricHandles); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricCreateFromProgrammableExp( + ze_result_t result, + zet_metric_programmable_exp_handle_t hMetricProgrammable, ///< [in] handle of the metric programmable + zet_metric_programmable_param_value_exp_t* pParameterValues,///< [in] list of parameter values to be set. + uint32_t parameterCount, ///< [in] Count of parameters to set. + const char* pName, ///< [in] pointer to metric name to be used. Must point to a + ///< null-terminated character array no longer than ::ZET_MAX_METRIC_NAME. + const char* pDescription, ///< [in] pointer to metric description to be used. Must point to a + ///< null-terminated character array no longer than + ///< ::ZET_MAX_METRIC_DESCRIPTION. + uint32_t* pMetricHandleCount, ///< [in,out] Pointer to the number of metric handles. + ///< if count is zero, then the driver shall update the value with the + ///< number of metric handles available for this programmable. + ///< if count is greater than the number of metric handles available, then + ///< the driver shall update the value with the correct number of metric + ///< handles available. + zet_metric_handle_t* phMetricHandles ///< [in,out][optional][range(0,*pMetricHandleCount)] array of handle of metrics. + ///< if count is less than the number of metrics available, then driver + ///< shall only retrieve that number of metric handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricCreateFromProgrammableExp("; + oss << "hMetricProgrammable=" << loader::to_string(hMetricProgrammable); + oss << ", "; + oss << "pParameterValues=" << loader::to_string(pParameterValues); + oss << ", "; + oss << "parameterCount=" << loader::to_string(parameterCount); + oss << ", "; + oss << "pName=" << loader::to_string(pName); + oss << ", "; + oss << "pDescription=" << loader::to_string(pDescription); + oss << ", "; + oss << "pMetricHandleCount=" << loader::to_string(pMetricHandleCount); + oss << ", "; + oss << "phMetricHandles=" << loader::to_string(phMetricHandles); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] handle of the device. + uint32_t metricCount, ///< [in] number of metric handles. + zet_metric_handle_t * phMetrics, ///< [in] metric handles to be added to the metric groups. + const char * pMetricGroupNamePrefix, ///< [in] prefix to the name created for the metric groups. Must point to a + ///< null-terminated character array no longer than + ///< ::ZET_MAX_METRIC_GROUP_NAME_PREFIX_EXP. + const char * pDescription, ///< [in] pointer to description of the metric groups. Must point to a + ///< null-terminated character array no longer than + ///< ::ZET_MAX_METRIC_GROUP_DESCRIPTION. + uint32_t * pMetricGroupCount, ///< [in,out] pointer to the number of metric group handles to be created. + ///< if pMetricGroupCount is zero, then the driver shall update the value + ///< with the maximum possible number of metric group handles that could be created. + ///< if pMetricGroupCount is greater than the number of metric group + ///< handles that could be created, then the driver shall update the value + ///< with the correct number of metric group handles generated. + ///< if pMetricGroupCount is lesser than the number of metric group handles + ///< that could be created, then ::ZE_RESULT_ERROR_INVALID_ARGUMENT is returned. + zet_metric_group_handle_t* phMetricGroup ///< [in,out][optional][range(0, *pMetricGroupCount)] array of handle of + ///< metric group handles. + ///< Created Metric group handles. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetDeviceCreateMetricGroupsFromMetricsExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "metricCount=" << loader::to_string(metricCount); + oss << ", "; + oss << "phMetrics=" << loader::to_string(phMetrics); + oss << ", "; + oss << "pMetricGroupNamePrefix=" << loader::to_string(pMetricGroupNamePrefix); + oss << ", "; + oss << "pDescription=" << loader::to_string(pDescription); + oss << ", "; + oss << "pMetricGroupCount=" << loader::to_string(pMetricGroupCount); + oss << ", "; + oss << "phMetricGroup=" << loader::to_string(phMetricGroup); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupCreateExp( + ze_result_t result, + zet_device_handle_t hDevice, ///< [in] handle of the device + const char* pName, ///< [in] pointer to metric group name. Must point to a null-terminated + ///< character array no longer than ::ZET_MAX_METRIC_GROUP_NAME. + const char* pDescription, ///< [in] pointer to metric group description. Must point to a + ///< null-terminated character array no longer than + ///< ::ZET_MAX_METRIC_GROUP_DESCRIPTION. + zet_metric_group_sampling_type_flags_t samplingType,///< [in] Sampling type for the metric group. + zet_metric_group_handle_t* phMetricGroup ///< [in,out] Created Metric group handle +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupCreateExp("; + oss << "hDevice=" << loader::to_string(hDevice); + oss << ", "; + oss << "pName=" << loader::to_string(pName); + oss << ", "; + oss << "pDescription=" << loader::to_string(pDescription); + oss << ", "; + oss << "samplingType=" << loader::to_string(samplingType); + oss << ", "; + oss << "phMetricGroup=" << loader::to_string(phMetricGroup); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupAddMetricExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] Handle of the metric group + zet_metric_handle_t hMetric, ///< [in] Metric to be added to the group. + size_t * pErrorStringSize, ///< [in,out][optional] Size of the error string to query, if an error was + ///< reported during adding the metric handle. + ///< if *pErrorStringSize is zero, then the driver shall update the value + ///< with the size of the error string in bytes. + char* pErrorString ///< [in,out][optional][range(0, *pErrorStringSize)] Error string. + ///< if *pErrorStringSize is less than the length of the error string + ///< available, then driver shall only retrieve that length of error string. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupAddMetricExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "hMetric=" << loader::to_string(hMetric); + oss << ", "; + oss << "pErrorStringSize=" << loader::to_string(pErrorStringSize); + oss << ", "; + oss << "pErrorString=" << loader::to_string(pErrorString); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupRemoveMetricExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup, ///< [in] Handle of the metric group + zet_metric_handle_t hMetric ///< [in] Metric handle to be removed from the metric group. +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupRemoveMetricExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ", "; + oss << "hMetric=" << loader::to_string(hMetric); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupCloseExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup ///< [in] Handle of the metric group +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupCloseExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricGroupDestroyExp( + ze_result_t result, + zet_metric_group_handle_t hMetricGroup ///< [in] Handle of the metric group to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricGroupDestroyExp("; + oss << "hMetricGroup=" << loader::to_string(hMetricGroup); + oss << ")"; + context.logger->log_trace(oss.str()); + return result; + } + VALIDATION_MAYBE_UNUSED static ze_result_t logAndPropagateResult_zetMetricDestroyExp( + ze_result_t result, + zet_metric_handle_t hMetric ///< [in] Handle of the metric to destroy +) { + std::string status = (result == ZE_RESULT_SUCCESS) ? "SUCCESS" : "ERROR"; + std::ostringstream oss; + oss << status << " (" << loader::to_string(result) << ") in zetMetricDestroyExp("; + oss << "hMetric=" << loader::to_string(hMetric); + oss << ")"; + context.logger->log_trace(oss.str()); return result; } @@ -35,12 +1578,12 @@ namespace validation_layer auto pfnGetDebugInfo = context.zetDdiTable.Module.pfnGetDebugInfo; if( nullptr == pfnGetDebugInfo ) - return logAndPropagateResult("zetModuleGetDebugInfo", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetModuleGetDebugInfo(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hModule, format, pSize, pDebugInfo); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetModuleGetDebugInfoPrologue( hModule, format, pSize, pDebugInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetModuleGetDebugInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetModuleGetDebugInfo(result, hModule, format, pSize, pDebugInfo); } @@ -51,17 +1594,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetModuleGetDebugInfoPrologue( hModule, format, pSize, pDebugInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetModuleGetDebugInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetModuleGetDebugInfo(result, hModule, format, pSize, pDebugInfo); } auto driver_result = pfnGetDebugInfo( hModule, format, pSize, pDebugInfo ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetModuleGetDebugInfoEpilogue( hModule, format, pSize, pDebugInfo ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetModuleGetDebugInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetModuleGetDebugInfo(result, hModule, format, pSize, pDebugInfo); } - return logAndPropagateResult("zetModuleGetDebugInfo", driver_result); + return logAndPropagateResult_zetModuleGetDebugInfo(driver_result, hModule, format, pSize, pDebugInfo); } /////////////////////////////////////////////////////////////////////////////// @@ -77,12 +1620,12 @@ namespace validation_layer auto pfnGetDebugProperties = context.zetDdiTable.Device.pfnGetDebugProperties; if( nullptr == pfnGetDebugProperties ) - return logAndPropagateResult("zetDeviceGetDebugProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDeviceGetDebugProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pDebugProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceGetDebugPropertiesPrologue( hDevice, pDebugProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetDebugProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetDebugProperties(result, hDevice, pDebugProperties); } @@ -93,17 +1636,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDeviceGetDebugPropertiesPrologue( hDevice, pDebugProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetDebugProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetDebugProperties(result, hDevice, pDebugProperties); } auto driver_result = pfnGetDebugProperties( hDevice, pDebugProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceGetDebugPropertiesEpilogue( hDevice, pDebugProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetDebugProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetDebugProperties(result, hDevice, pDebugProperties); } - return logAndPropagateResult("zetDeviceGetDebugProperties", driver_result); + return logAndPropagateResult_zetDeviceGetDebugProperties(driver_result, hDevice, pDebugProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -120,12 +1663,12 @@ namespace validation_layer auto pfnAttach = context.zetDdiTable.Debug.pfnAttach; if( nullptr == pfnAttach ) - return logAndPropagateResult("zetDebugAttach", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugAttach(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, config, phDebug); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugAttachPrologue( hDevice, config, phDebug ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAttach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAttach(result, hDevice, config, phDebug); } @@ -136,17 +1679,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugAttachPrologue( hDevice, config, phDebug ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAttach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAttach(result, hDevice, config, phDebug); } auto driver_result = pfnAttach( hDevice, config, phDebug ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugAttachEpilogue( hDevice, config, phDebug ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAttach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAttach(result, hDevice, config, phDebug); } - return logAndPropagateResult("zetDebugAttach", driver_result); + return logAndPropagateResult_zetDebugAttach(driver_result, hDevice, config, phDebug); } /////////////////////////////////////////////////////////////////////////////// @@ -161,12 +1704,12 @@ namespace validation_layer auto pfnDetach = context.zetDdiTable.Debug.pfnDetach; if( nullptr == pfnDetach ) - return logAndPropagateResult("zetDebugDetach", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugDetach(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugDetachPrologue( hDebug ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugDetach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugDetach(result, hDebug); } @@ -177,17 +1720,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugDetachPrologue( hDebug ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugDetach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugDetach(result, hDebug); } auto driver_result = pfnDetach( hDebug ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugDetachEpilogue( hDebug ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugDetach", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugDetach(result, hDebug); } - return logAndPropagateResult("zetDebugDetach", driver_result); + return logAndPropagateResult_zetDebugDetach(driver_result, hDebug); } /////////////////////////////////////////////////////////////////////////////// @@ -210,12 +1753,12 @@ namespace validation_layer auto pfnReadEvent = context.zetDdiTable.Debug.pfnReadEvent; if( nullptr == pfnReadEvent ) - return logAndPropagateResult("zetDebugReadEvent", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugReadEvent(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, timeout, event); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadEventPrologue( hDebug, timeout, event ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadEvent(result, hDebug, timeout, event); } @@ -226,17 +1769,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugReadEventPrologue( hDebug, timeout, event ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadEvent(result, hDebug, timeout, event); } auto driver_result = pfnReadEvent( hDebug, timeout, event ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadEventEpilogue( hDebug, timeout, event ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadEvent(result, hDebug, timeout, event); } - return logAndPropagateResult("zetDebugReadEvent", driver_result); + return logAndPropagateResult_zetDebugReadEvent(driver_result, hDebug, timeout, event); } /////////////////////////////////////////////////////////////////////////////// @@ -252,12 +1795,12 @@ namespace validation_layer auto pfnAcknowledgeEvent = context.zetDdiTable.Debug.pfnAcknowledgeEvent; if( nullptr == pfnAcknowledgeEvent ) - return logAndPropagateResult("zetDebugAcknowledgeEvent", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugAcknowledgeEvent(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, event); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugAcknowledgeEventPrologue( hDebug, event ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAcknowledgeEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAcknowledgeEvent(result, hDebug, event); } @@ -268,17 +1811,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugAcknowledgeEventPrologue( hDebug, event ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAcknowledgeEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAcknowledgeEvent(result, hDebug, event); } auto driver_result = pfnAcknowledgeEvent( hDebug, event ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugAcknowledgeEventEpilogue( hDebug, event ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugAcknowledgeEvent", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugAcknowledgeEvent(result, hDebug, event); } - return logAndPropagateResult("zetDebugAcknowledgeEvent", driver_result); + return logAndPropagateResult_zetDebugAcknowledgeEvent(driver_result, hDebug, event); } /////////////////////////////////////////////////////////////////////////////// @@ -294,12 +1837,12 @@ namespace validation_layer auto pfnInterrupt = context.zetDdiTable.Debug.pfnInterrupt; if( nullptr == pfnInterrupt ) - return logAndPropagateResult("zetDebugInterrupt", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugInterrupt(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugInterruptPrologue( hDebug, thread ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugInterrupt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugInterrupt(result, hDebug, thread); } @@ -310,17 +1853,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugInterruptPrologue( hDebug, thread ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugInterrupt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugInterrupt(result, hDebug, thread); } auto driver_result = pfnInterrupt( hDebug, thread ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugInterruptEpilogue( hDebug, thread ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugInterrupt", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugInterrupt(result, hDebug, thread); } - return logAndPropagateResult("zetDebugInterrupt", driver_result); + return logAndPropagateResult_zetDebugInterrupt(driver_result, hDebug, thread); } /////////////////////////////////////////////////////////////////////////////// @@ -336,12 +1879,12 @@ namespace validation_layer auto pfnResume = context.zetDdiTable.Debug.pfnResume; if( nullptr == pfnResume ) - return logAndPropagateResult("zetDebugResume", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugResume(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugResumePrologue( hDebug, thread ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugResume", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugResume(result, hDebug, thread); } @@ -352,17 +1895,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugResumePrologue( hDebug, thread ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugResume", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugResume(result, hDebug, thread); } auto driver_result = pfnResume( hDebug, thread ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugResumeEpilogue( hDebug, thread ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugResume", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugResume(result, hDebug, thread); } - return logAndPropagateResult("zetDebugResume", driver_result); + return logAndPropagateResult_zetDebugResume(driver_result, hDebug, thread); } /////////////////////////////////////////////////////////////////////////////// @@ -381,12 +1924,12 @@ namespace validation_layer auto pfnReadMemory = context.zetDdiTable.Debug.pfnReadMemory; if( nullptr == pfnReadMemory ) - return logAndPropagateResult("zetDebugReadMemory", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugReadMemory(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread, desc, size, buffer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadMemoryPrologue( hDebug, thread, desc, size, buffer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadMemory(result, hDebug, thread, desc, size, buffer); } @@ -397,17 +1940,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugReadMemoryPrologue( hDebug, thread, desc, size, buffer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadMemory(result, hDebug, thread, desc, size, buffer); } auto driver_result = pfnReadMemory( hDebug, thread, desc, size, buffer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadMemoryEpilogue( hDebug, thread, desc, size, buffer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadMemory(result, hDebug, thread, desc, size, buffer); } - return logAndPropagateResult("zetDebugReadMemory", driver_result); + return logAndPropagateResult_zetDebugReadMemory(driver_result, hDebug, thread, desc, size, buffer); } /////////////////////////////////////////////////////////////////////////////// @@ -426,12 +1969,12 @@ namespace validation_layer auto pfnWriteMemory = context.zetDdiTable.Debug.pfnWriteMemory; if( nullptr == pfnWriteMemory ) - return logAndPropagateResult("zetDebugWriteMemory", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugWriteMemory(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread, desc, size, buffer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugWriteMemoryPrologue( hDebug, thread, desc, size, buffer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteMemory(result, hDebug, thread, desc, size, buffer); } @@ -442,17 +1985,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugWriteMemoryPrologue( hDebug, thread, desc, size, buffer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteMemory(result, hDebug, thread, desc, size, buffer); } auto driver_result = pfnWriteMemory( hDebug, thread, desc, size, buffer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugWriteMemoryEpilogue( hDebug, thread, desc, size, buffer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteMemory", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteMemory(result, hDebug, thread, desc, size, buffer); } - return logAndPropagateResult("zetDebugWriteMemory", driver_result); + return logAndPropagateResult_zetDebugWriteMemory(driver_result, hDebug, thread, desc, size, buffer); } /////////////////////////////////////////////////////////////////////////////// @@ -477,12 +2020,12 @@ namespace validation_layer auto pfnGetRegisterSetProperties = context.zetDdiTable.Debug.pfnGetRegisterSetProperties; if( nullptr == pfnGetRegisterSetProperties ) - return logAndPropagateResult("zetDebugGetRegisterSetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugGetRegisterSetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, pRegisterSetProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugGetRegisterSetPropertiesPrologue( hDevice, pCount, pRegisterSetProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetRegisterSetProperties(result, hDevice, pCount, pRegisterSetProperties); } @@ -493,17 +2036,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugGetRegisterSetPropertiesPrologue( hDevice, pCount, pRegisterSetProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetRegisterSetProperties(result, hDevice, pCount, pRegisterSetProperties); } auto driver_result = pfnGetRegisterSetProperties( hDevice, pCount, pRegisterSetProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugGetRegisterSetPropertiesEpilogue( hDevice, pCount, pRegisterSetProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetRegisterSetProperties(result, hDevice, pCount, pRegisterSetProperties); } - return logAndPropagateResult("zetDebugGetRegisterSetProperties", driver_result); + return logAndPropagateResult_zetDebugGetRegisterSetProperties(driver_result, hDevice, pCount, pRegisterSetProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -529,12 +2072,12 @@ namespace validation_layer auto pfnGetThreadRegisterSetProperties = context.zetDdiTable.Debug.pfnGetThreadRegisterSetProperties; if( nullptr == pfnGetThreadRegisterSetProperties ) - return logAndPropagateResult("zetDebugGetThreadRegisterSetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugGetThreadRegisterSetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread, pCount, pRegisterSetProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugGetThreadRegisterSetPropertiesPrologue( hDebug, thread, pCount, pRegisterSetProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetThreadRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetThreadRegisterSetProperties(result, hDebug, thread, pCount, pRegisterSetProperties); } @@ -545,17 +2088,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugGetThreadRegisterSetPropertiesPrologue( hDebug, thread, pCount, pRegisterSetProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetThreadRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetThreadRegisterSetProperties(result, hDebug, thread, pCount, pRegisterSetProperties); } auto driver_result = pfnGetThreadRegisterSetProperties( hDebug, thread, pCount, pRegisterSetProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugGetThreadRegisterSetPropertiesEpilogue( hDebug, thread, pCount, pRegisterSetProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugGetThreadRegisterSetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugGetThreadRegisterSetProperties(result, hDebug, thread, pCount, pRegisterSetProperties); } - return logAndPropagateResult("zetDebugGetThreadRegisterSetProperties", driver_result); + return logAndPropagateResult_zetDebugGetThreadRegisterSetProperties(driver_result, hDebug, thread, pCount, pRegisterSetProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -579,12 +2122,12 @@ namespace validation_layer auto pfnReadRegisters = context.zetDdiTable.Debug.pfnReadRegisters; if( nullptr == pfnReadRegisters ) - return logAndPropagateResult("zetDebugReadRegisters", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugReadRegisters(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread, type, start, count, pRegisterValues); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadRegistersPrologue( hDebug, thread, type, start, count, pRegisterValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } @@ -595,17 +2138,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugReadRegistersPrologue( hDebug, thread, type, start, count, pRegisterValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } auto driver_result = pfnReadRegisters( hDebug, thread, type, start, count, pRegisterValues ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugReadRegistersEpilogue( hDebug, thread, type, start, count, pRegisterValues ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugReadRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugReadRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } - return logAndPropagateResult("zetDebugReadRegisters", driver_result); + return logAndPropagateResult_zetDebugReadRegisters(driver_result, hDebug, thread, type, start, count, pRegisterValues); } /////////////////////////////////////////////////////////////////////////////// @@ -629,12 +2172,12 @@ namespace validation_layer auto pfnWriteRegisters = context.zetDdiTable.Debug.pfnWriteRegisters; if( nullptr == pfnWriteRegisters ) - return logAndPropagateResult("zetDebugWriteRegisters", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDebugWriteRegisters(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDebug, thread, type, start, count, pRegisterValues); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugWriteRegistersPrologue( hDebug, thread, type, start, count, pRegisterValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } @@ -645,17 +2188,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDebugWriteRegistersPrologue( hDebug, thread, type, start, count, pRegisterValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } auto driver_result = pfnWriteRegisters( hDebug, thread, type, start, count, pRegisterValues ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDebugWriteRegistersEpilogue( hDebug, thread, type, start, count, pRegisterValues ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDebugWriteRegisters", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDebugWriteRegisters(result, hDebug, thread, type, start, count, pRegisterValues); } - return logAndPropagateResult("zetDebugWriteRegisters", driver_result); + return logAndPropagateResult_zetDebugWriteRegisters(driver_result, hDebug, thread, type, start, count, pRegisterValues); } /////////////////////////////////////////////////////////////////////////////// @@ -679,12 +2222,12 @@ namespace validation_layer auto pfnGet = context.zetDdiTable.MetricGroup.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zetMetricGroupGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phMetricGroups); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetPrologue( hDevice, pCount, phMetricGroups ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGet(result, hDevice, pCount, phMetricGroups); } @@ -695,14 +2238,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupGetPrologue( hDevice, pCount, phMetricGroups ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGet(result, hDevice, pCount, phMetricGroups); } auto driver_result = pfnGet( hDevice, pCount, phMetricGroups ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetEpilogue( hDevice, pCount, phMetricGroups ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGet(result, hDevice, pCount, phMetricGroups); } @@ -715,7 +2258,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricGroupGet", driver_result); + return logAndPropagateResult_zetMetricGroupGet(driver_result, hDevice, pCount, phMetricGroups); } /////////////////////////////////////////////////////////////////////////////// @@ -731,12 +2274,12 @@ namespace validation_layer auto pfnGetProperties = context.zetDdiTable.MetricGroup.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zetMetricGroupGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetPropertiesPrologue( hMetricGroup, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetProperties(result, hMetricGroup, pProperties); } @@ -747,17 +2290,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupGetPropertiesPrologue( hMetricGroup, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetProperties(result, hMetricGroup, pProperties); } auto driver_result = pfnGetProperties( hMetricGroup, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetPropertiesEpilogue( hMetricGroup, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetProperties(result, hMetricGroup, pProperties); } - return logAndPropagateResult("zetMetricGroupGetProperties", driver_result); + return logAndPropagateResult_zetMetricGroupGetProperties(driver_result, hMetricGroup, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -784,12 +2327,12 @@ namespace validation_layer auto pfnCalculateMetricValues = context.zetDdiTable.MetricGroup.pfnCalculateMetricValues; if( nullptr == pfnCalculateMetricValues ) - return logAndPropagateResult("zetMetricGroupCalculateMetricValues", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupCalculateMetricValues(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMetricValuesPrologue( hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricValues(result, hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues); } @@ -800,17 +2343,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupCalculateMetricValuesPrologue( hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricValues(result, hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues); } auto driver_result = pfnCalculateMetricValues( hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMetricValuesEpilogue( hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricValues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricValues(result, hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues); } - return logAndPropagateResult("zetMetricGroupCalculateMetricValues", driver_result); + return logAndPropagateResult_zetMetricGroupCalculateMetricValues(driver_result, hMetricGroup, type, rawDataSize, pRawData, pMetricValueCount, pMetricValues); } /////////////////////////////////////////////////////////////////////////////// @@ -833,12 +2376,12 @@ namespace validation_layer auto pfnGet = context.zetDdiTable.Metric.pfnGet; if( nullptr == pfnGet ) - return logAndPropagateResult("zetMetricGet", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGet(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, pCount, phMetrics); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGetPrologue( hMetricGroup, pCount, phMetrics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGet(result, hMetricGroup, pCount, phMetrics); } @@ -849,14 +2392,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGetPrologue( hMetricGroup, pCount, phMetrics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGet(result, hMetricGroup, pCount, phMetrics); } auto driver_result = pfnGet( hMetricGroup, pCount, phMetrics ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGetEpilogue( hMetricGroup, pCount, phMetrics ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGet", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGet(result, hMetricGroup, pCount, phMetrics); } @@ -869,7 +2412,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricGet", driver_result); + return logAndPropagateResult_zetMetricGet(driver_result, hMetricGroup, pCount, phMetrics); } /////////////////////////////////////////////////////////////////////////////// @@ -885,12 +2428,12 @@ namespace validation_layer auto pfnGetProperties = context.zetDdiTable.Metric.pfnGetProperties; if( nullptr == pfnGetProperties ) - return logAndPropagateResult("zetMetricGetProperties", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGetProperties(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetric, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGetPropertiesPrologue( hMetric, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGetProperties(result, hMetric, pProperties); } @@ -901,17 +2444,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGetPropertiesPrologue( hMetric, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGetProperties(result, hMetric, pProperties); } auto driver_result = pfnGetProperties( hMetric, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGetPropertiesEpilogue( hMetric, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGetProperties", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGetProperties(result, hMetric, pProperties); } - return logAndPropagateResult("zetMetricGetProperties", driver_result); + return logAndPropagateResult_zetMetricGetProperties(driver_result, hMetric, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -933,12 +2476,12 @@ namespace validation_layer auto pfnActivateMetricGroups = context.zetDdiTable.Context.pfnActivateMetricGroups; if( nullptr == pfnActivateMetricGroups ) - return logAndPropagateResult("zetContextActivateMetricGroups", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetContextActivateMetricGroups(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, count, phMetricGroups); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetContextActivateMetricGroupsPrologue( hContext, hDevice, count, phMetricGroups ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetContextActivateMetricGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetContextActivateMetricGroups(result, hContext, hDevice, count, phMetricGroups); } @@ -949,17 +2492,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetContextActivateMetricGroupsPrologue( hContext, hDevice, count, phMetricGroups ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetContextActivateMetricGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetContextActivateMetricGroups(result, hContext, hDevice, count, phMetricGroups); } auto driver_result = pfnActivateMetricGroups( hContext, hDevice, count, phMetricGroups ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetContextActivateMetricGroupsEpilogue( hContext, hDevice, count, phMetricGroups ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetContextActivateMetricGroups", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetContextActivateMetricGroups(result, hContext, hDevice, count, phMetricGroups); } - return logAndPropagateResult("zetContextActivateMetricGroups", driver_result); + return logAndPropagateResult_zetContextActivateMetricGroups(driver_result, hContext, hDevice, count, phMetricGroups); } /////////////////////////////////////////////////////////////////////////////// @@ -979,12 +2522,12 @@ namespace validation_layer auto pfnOpen = context.zetDdiTable.MetricStreamer.pfnOpen; if( nullptr == pfnOpen ) - return logAndPropagateResult("zetMetricStreamerOpen", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricStreamerOpen(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerOpenPrologue( hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerOpen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerOpen(result, hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer); } @@ -995,17 +2538,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricStreamerOpenPrologue( hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerOpen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerOpen(result, hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer); } auto driver_result = pfnOpen( hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerOpenEpilogue( hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerOpen", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerOpen(result, hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer); } - return logAndPropagateResult("zetMetricStreamerOpen", driver_result); + return logAndPropagateResult_zetMetricStreamerOpen(driver_result, hContext, hDevice, hMetricGroup, desc, hNotificationEvent, phMetricStreamer); } /////////////////////////////////////////////////////////////////////////////// @@ -1022,12 +2565,12 @@ namespace validation_layer auto pfnAppendMetricStreamerMarker = context.zetDdiTable.CommandList.pfnAppendMetricStreamerMarker; if( nullptr == pfnAppendMetricStreamerMarker ) - return logAndPropagateResult("zetCommandListAppendMetricStreamerMarker", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetCommandListAppendMetricStreamerMarker(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hMetricStreamer, value); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricStreamerMarkerPrologue( hCommandList, hMetricStreamer, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricStreamerMarker", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricStreamerMarker(result, hCommandList, hMetricStreamer, value); } @@ -1038,17 +2581,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetCommandListAppendMetricStreamerMarkerPrologue( hCommandList, hMetricStreamer, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricStreamerMarker", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricStreamerMarker(result, hCommandList, hMetricStreamer, value); } auto driver_result = pfnAppendMetricStreamerMarker( hCommandList, hMetricStreamer, value ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricStreamerMarkerEpilogue( hCommandList, hMetricStreamer, value ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricStreamerMarker", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricStreamerMarker(result, hCommandList, hMetricStreamer, value); } - return logAndPropagateResult("zetCommandListAppendMetricStreamerMarker", driver_result); + return logAndPropagateResult_zetCommandListAppendMetricStreamerMarker(driver_result, hCommandList, hMetricStreamer, value); } /////////////////////////////////////////////////////////////////////////////// @@ -1063,12 +2606,12 @@ namespace validation_layer auto pfnClose = context.zetDdiTable.MetricStreamer.pfnClose; if( nullptr == pfnClose ) - return logAndPropagateResult("zetMetricStreamerClose", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricStreamerClose(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricStreamer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerClosePrologue( hMetricStreamer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerClose(result, hMetricStreamer); } @@ -1079,17 +2622,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricStreamerClosePrologue( hMetricStreamer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerClose(result, hMetricStreamer); } auto driver_result = pfnClose( hMetricStreamer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerCloseEpilogue( hMetricStreamer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerClose", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerClose(result, hMetricStreamer); } - return logAndPropagateResult("zetMetricStreamerClose", driver_result); + return logAndPropagateResult_zetMetricStreamerClose(driver_result, hMetricStreamer); } /////////////////////////////////////////////////////////////////////////////// @@ -1115,12 +2658,12 @@ namespace validation_layer auto pfnReadData = context.zetDdiTable.MetricStreamer.pfnReadData; if( nullptr == pfnReadData ) - return logAndPropagateResult("zetMetricStreamerReadData", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricStreamerReadData(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricStreamer, maxReportCount, pRawDataSize, pRawData); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerReadDataPrologue( hMetricStreamer, maxReportCount, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerReadData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerReadData(result, hMetricStreamer, maxReportCount, pRawDataSize, pRawData); } @@ -1131,17 +2674,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricStreamerReadDataPrologue( hMetricStreamer, maxReportCount, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerReadData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerReadData(result, hMetricStreamer, maxReportCount, pRawDataSize, pRawData); } auto driver_result = pfnReadData( hMetricStreamer, maxReportCount, pRawDataSize, pRawData ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricStreamerReadDataEpilogue( hMetricStreamer, maxReportCount, pRawDataSize, pRawData ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricStreamerReadData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricStreamerReadData(result, hMetricStreamer, maxReportCount, pRawDataSize, pRawData); } - return logAndPropagateResult("zetMetricStreamerReadData", driver_result); + return logAndPropagateResult_zetMetricStreamerReadData(driver_result, hMetricStreamer, maxReportCount, pRawDataSize, pRawData); } /////////////////////////////////////////////////////////////////////////////// @@ -1160,12 +2703,12 @@ namespace validation_layer auto pfnCreate = context.zetDdiTable.MetricQueryPool.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zetMetricQueryPoolCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryPoolCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, hMetricGroup, desc, phMetricQueryPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryPoolCreatePrologue( hContext, hDevice, hMetricGroup, desc, phMetricQueryPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolCreate(result, hContext, hDevice, hMetricGroup, desc, phMetricQueryPool); } @@ -1176,14 +2719,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryPoolCreatePrologue( hContext, hDevice, hMetricGroup, desc, phMetricQueryPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolCreate(result, hContext, hDevice, hMetricGroup, desc, phMetricQueryPool); } auto driver_result = pfnCreate( hContext, hDevice, hMetricGroup, desc, phMetricQueryPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryPoolCreateEpilogue( hContext, hDevice, hMetricGroup, desc, phMetricQueryPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolCreate(result, hContext, hDevice, hMetricGroup, desc, phMetricQueryPool); } @@ -1195,7 +2738,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetMetricQueryPoolCreate", driver_result); + return logAndPropagateResult_zetMetricQueryPoolCreate(driver_result, hContext, hDevice, hMetricGroup, desc, phMetricQueryPool); } /////////////////////////////////////////////////////////////////////////////// @@ -1210,12 +2753,12 @@ namespace validation_layer auto pfnDestroy = context.zetDdiTable.MetricQueryPool.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zetMetricQueryPoolDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryPoolDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricQueryPool); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryPoolDestroyPrologue( hMetricQueryPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolDestroy(result, hMetricQueryPool); } @@ -1226,17 +2769,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryPoolDestroyPrologue( hMetricQueryPool ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolDestroy(result, hMetricQueryPool); } auto driver_result = pfnDestroy( hMetricQueryPool ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryPoolDestroyEpilogue( hMetricQueryPool ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryPoolDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryPoolDestroy(result, hMetricQueryPool); } - return logAndPropagateResult("zetMetricQueryPoolDestroy", driver_result); + return logAndPropagateResult_zetMetricQueryPoolDestroy(driver_result, hMetricQueryPool); } /////////////////////////////////////////////////////////////////////////////// @@ -1253,12 +2796,12 @@ namespace validation_layer auto pfnCreate = context.zetDdiTable.MetricQuery.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zetMetricQueryCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricQueryPool, index, phMetricQuery); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryCreatePrologue( hMetricQueryPool, index, phMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryCreate(result, hMetricQueryPool, index, phMetricQuery); } @@ -1269,14 +2812,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryCreatePrologue( hMetricQueryPool, index, phMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryCreate(result, hMetricQueryPool, index, phMetricQuery); } auto driver_result = pfnCreate( hMetricQueryPool, index, phMetricQuery ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryCreateEpilogue( hMetricQueryPool, index, phMetricQuery ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryCreate(result, hMetricQueryPool, index, phMetricQuery); } @@ -1288,7 +2831,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetMetricQueryCreate", driver_result); + return logAndPropagateResult_zetMetricQueryCreate(driver_result, hMetricQueryPool, index, phMetricQuery); } /////////////////////////////////////////////////////////////////////////////// @@ -1303,12 +2846,12 @@ namespace validation_layer auto pfnDestroy = context.zetDdiTable.MetricQuery.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zetMetricQueryDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricQuery); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryDestroyPrologue( hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryDestroy(result, hMetricQuery); } @@ -1319,17 +2862,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryDestroyPrologue( hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryDestroy(result, hMetricQuery); } auto driver_result = pfnDestroy( hMetricQuery ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryDestroyEpilogue( hMetricQuery ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryDestroy(result, hMetricQuery); } - return logAndPropagateResult("zetMetricQueryDestroy", driver_result); + return logAndPropagateResult_zetMetricQueryDestroy(driver_result, hMetricQuery); } /////////////////////////////////////////////////////////////////////////////// @@ -1344,12 +2887,12 @@ namespace validation_layer auto pfnReset = context.zetDdiTable.MetricQuery.pfnReset; if( nullptr == pfnReset ) - return logAndPropagateResult("zetMetricQueryReset", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryReset(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricQuery); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryResetPrologue( hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryReset(result, hMetricQuery); } @@ -1360,17 +2903,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryResetPrologue( hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryReset(result, hMetricQuery); } auto driver_result = pfnReset( hMetricQuery ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryResetEpilogue( hMetricQuery ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryReset", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryReset(result, hMetricQuery); } - return logAndPropagateResult("zetMetricQueryReset", driver_result); + return logAndPropagateResult_zetMetricQueryReset(driver_result, hMetricQuery); } /////////////////////////////////////////////////////////////////////////////// @@ -1386,12 +2929,12 @@ namespace validation_layer auto pfnAppendMetricQueryBegin = context.zetDdiTable.CommandList.pfnAppendMetricQueryBegin; if( nullptr == pfnAppendMetricQueryBegin ) - return logAndPropagateResult("zetCommandListAppendMetricQueryBegin", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetCommandListAppendMetricQueryBegin(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hMetricQuery); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricQueryBeginPrologue( hCommandList, hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryBegin", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryBegin(result, hCommandList, hMetricQuery); } @@ -1402,17 +2945,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetCommandListAppendMetricQueryBeginPrologue( hCommandList, hMetricQuery ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryBegin", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryBegin(result, hCommandList, hMetricQuery); } auto driver_result = pfnAppendMetricQueryBegin( hCommandList, hMetricQuery ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricQueryBeginEpilogue( hCommandList, hMetricQuery ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryBegin", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryBegin(result, hCommandList, hMetricQuery); } - return logAndPropagateResult("zetCommandListAppendMetricQueryBegin", driver_result); + return logAndPropagateResult_zetCommandListAppendMetricQueryBegin(driver_result, hCommandList, hMetricQuery); } /////////////////////////////////////////////////////////////////////////////// @@ -1431,12 +2974,12 @@ namespace validation_layer auto pfnAppendMetricQueryEnd = context.zetDdiTable.CommandList.pfnAppendMetricQueryEnd; if( nullptr == pfnAppendMetricQueryEnd ) - return logAndPropagateResult("zetCommandListAppendMetricQueryEnd", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetCommandListAppendMetricQueryEnd(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricQueryEndPrologue( hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryEnd", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryEnd(result, hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents); } @@ -1447,17 +2990,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetCommandListAppendMetricQueryEndPrologue( hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryEnd", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryEnd(result, hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents); } auto driver_result = pfnAppendMetricQueryEnd( hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricQueryEndEpilogue( hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricQueryEnd", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricQueryEnd(result, hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents); } - return logAndPropagateResult("zetCommandListAppendMetricQueryEnd", driver_result); + return logAndPropagateResult_zetCommandListAppendMetricQueryEnd(driver_result, hCommandList, hMetricQuery, hSignalEvent, numWaitEvents, phWaitEvents); } /////////////////////////////////////////////////////////////////////////////// @@ -1472,12 +3015,12 @@ namespace validation_layer auto pfnAppendMetricMemoryBarrier = context.zetDdiTable.CommandList.pfnAppendMetricMemoryBarrier; if( nullptr == pfnAppendMetricMemoryBarrier ) - return logAndPropagateResult("zetCommandListAppendMetricMemoryBarrier", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricMemoryBarrierPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricMemoryBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier(result, hCommandList); } @@ -1488,17 +3031,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetCommandListAppendMetricMemoryBarrierPrologue( hCommandList ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricMemoryBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier(result, hCommandList); } auto driver_result = pfnAppendMetricMemoryBarrier( hCommandList ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMetricMemoryBarrierEpilogue( hCommandList ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMetricMemoryBarrier", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier(result, hCommandList); } - return logAndPropagateResult("zetCommandListAppendMetricMemoryBarrier", driver_result); + return logAndPropagateResult_zetCommandListAppendMetricMemoryBarrier(driver_result, hCommandList); } /////////////////////////////////////////////////////////////////////////////// @@ -1522,12 +3065,12 @@ namespace validation_layer auto pfnGetData = context.zetDdiTable.MetricQuery.pfnGetData; if( nullptr == pfnGetData ) - return logAndPropagateResult("zetMetricQueryGetData", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricQueryGetData(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricQuery, pRawDataSize, pRawData); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryGetDataPrologue( hMetricQuery, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryGetData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryGetData(result, hMetricQuery, pRawDataSize, pRawData); } @@ -1538,17 +3081,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricQueryGetDataPrologue( hMetricQuery, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryGetData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryGetData(result, hMetricQuery, pRawDataSize, pRawData); } auto driver_result = pfnGetData( hMetricQuery, pRawDataSize, pRawData ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricQueryGetDataEpilogue( hMetricQuery, pRawDataSize, pRawData ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricQueryGetData", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricQueryGetData(result, hMetricQuery, pRawDataSize, pRawData); } - return logAndPropagateResult("zetMetricQueryGetData", driver_result); + return logAndPropagateResult_zetMetricQueryGetData(driver_result, hMetricQuery, pRawDataSize, pRawData); } /////////////////////////////////////////////////////////////////////////////// @@ -1564,12 +3107,12 @@ namespace validation_layer auto pfnGetProfileInfo = context.zetDdiTable.Kernel.pfnGetProfileInfo; if( nullptr == pfnGetProfileInfo ) - return logAndPropagateResult("zetKernelGetProfileInfo", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetKernelGetProfileInfo(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hKernel, pProfileProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetKernelGetProfileInfoPrologue( hKernel, pProfileProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetKernelGetProfileInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetKernelGetProfileInfo(result, hKernel, pProfileProperties); } @@ -1580,17 +3123,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetKernelGetProfileInfoPrologue( hKernel, pProfileProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetKernelGetProfileInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetKernelGetProfileInfo(result, hKernel, pProfileProperties); } auto driver_result = pfnGetProfileInfo( hKernel, pProfileProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetKernelGetProfileInfoEpilogue( hKernel, pProfileProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetKernelGetProfileInfo", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetKernelGetProfileInfo(result, hKernel, pProfileProperties); } - return logAndPropagateResult("zetKernelGetProfileInfo", driver_result); + return logAndPropagateResult_zetKernelGetProfileInfo(driver_result, hKernel, pProfileProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -1607,12 +3150,12 @@ namespace validation_layer auto pfnCreate = context.zetDdiTable.TracerExp.pfnCreate; if( nullptr == pfnCreate ) - return logAndPropagateResult("zetTracerExpCreate", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetTracerExpCreate(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, desc, phTracer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpCreatePrologue( hContext, desc, phTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpCreate(result, hContext, desc, phTracer); } @@ -1623,14 +3166,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetTracerExpCreatePrologue( hContext, desc, phTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpCreate(result, hContext, desc, phTracer); } auto driver_result = pfnCreate( hContext, desc, phTracer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpCreateEpilogue( hContext, desc, phTracer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpCreate", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpCreate(result, hContext, desc, phTracer); } @@ -1642,7 +3185,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetTracerExpCreate", driver_result); + return logAndPropagateResult_zetTracerExpCreate(driver_result, hContext, desc, phTracer); } /////////////////////////////////////////////////////////////////////////////// @@ -1657,12 +3200,12 @@ namespace validation_layer auto pfnDestroy = context.zetDdiTable.TracerExp.pfnDestroy; if( nullptr == pfnDestroy ) - return logAndPropagateResult("zetTracerExpDestroy", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetTracerExpDestroy(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTracer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpDestroyPrologue( hTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpDestroy(result, hTracer); } @@ -1673,17 +3216,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetTracerExpDestroyPrologue( hTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpDestroy(result, hTracer); } auto driver_result = pfnDestroy( hTracer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpDestroyEpilogue( hTracer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpDestroy", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpDestroy(result, hTracer); } - return logAndPropagateResult("zetTracerExpDestroy", driver_result); + return logAndPropagateResult_zetTracerExpDestroy(driver_result, hTracer); } /////////////////////////////////////////////////////////////////////////////// @@ -1699,12 +3242,12 @@ namespace validation_layer auto pfnSetPrologues = context.zetDdiTable.TracerExp.pfnSetPrologues; if( nullptr == pfnSetPrologues ) - return logAndPropagateResult("zetTracerExpSetPrologues", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetTracerExpSetPrologues(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTracer, pCoreCbs); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetProloguesPrologue( hTracer, pCoreCbs ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetPrologues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetPrologues(result, hTracer, pCoreCbs); } @@ -1715,17 +3258,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetTracerExpSetProloguesPrologue( hTracer, pCoreCbs ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetPrologues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetPrologues(result, hTracer, pCoreCbs); } auto driver_result = pfnSetPrologues( hTracer, pCoreCbs ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetProloguesEpilogue( hTracer, pCoreCbs ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetPrologues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetPrologues(result, hTracer, pCoreCbs); } - return logAndPropagateResult("zetTracerExpSetPrologues", driver_result); + return logAndPropagateResult_zetTracerExpSetPrologues(driver_result, hTracer, pCoreCbs); } /////////////////////////////////////////////////////////////////////////////// @@ -1741,12 +3284,12 @@ namespace validation_layer auto pfnSetEpilogues = context.zetDdiTable.TracerExp.pfnSetEpilogues; if( nullptr == pfnSetEpilogues ) - return logAndPropagateResult("zetTracerExpSetEpilogues", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetTracerExpSetEpilogues(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTracer, pCoreCbs); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetEpiloguesPrologue( hTracer, pCoreCbs ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEpilogues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEpilogues(result, hTracer, pCoreCbs); } @@ -1757,17 +3300,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetTracerExpSetEpiloguesPrologue( hTracer, pCoreCbs ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEpilogues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEpilogues(result, hTracer, pCoreCbs); } auto driver_result = pfnSetEpilogues( hTracer, pCoreCbs ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetEpiloguesEpilogue( hTracer, pCoreCbs ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEpilogues", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEpilogues(result, hTracer, pCoreCbs); } - return logAndPropagateResult("zetTracerExpSetEpilogues", driver_result); + return logAndPropagateResult_zetTracerExpSetEpilogues(driver_result, hTracer, pCoreCbs); } /////////////////////////////////////////////////////////////////////////////// @@ -1783,12 +3326,12 @@ namespace validation_layer auto pfnSetEnabled = context.zetDdiTable.TracerExp.pfnSetEnabled; if( nullptr == pfnSetEnabled ) - return logAndPropagateResult("zetTracerExpSetEnabled", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetTracerExpSetEnabled(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hTracer, enable); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetEnabledPrologue( hTracer, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEnabled", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEnabled(result, hTracer, enable); } @@ -1799,17 +3342,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetTracerExpSetEnabledPrologue( hTracer, enable ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEnabled", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEnabled(result, hTracer, enable); } auto driver_result = pfnSetEnabled( hTracer, enable ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetTracerExpSetEnabledEpilogue( hTracer, enable ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetTracerExpSetEnabled", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetTracerExpSetEnabled(result, hTracer, enable); } - return logAndPropagateResult("zetTracerExpSetEnabled", driver_result); + return logAndPropagateResult_zetTracerExpSetEnabled(driver_result, hTracer, enable); } /////////////////////////////////////////////////////////////////////////////// @@ -1832,12 +3375,12 @@ namespace validation_layer auto pfnGetConcurrentMetricGroupsExp = context.zetDdiTable.DeviceExp.pfnGetConcurrentMetricGroupsExp; if( nullptr == pfnGetConcurrentMetricGroupsExp ) - return logAndPropagateResult("zetDeviceGetConcurrentMetricGroupsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceGetConcurrentMetricGroupsExpPrologue( hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetConcurrentMetricGroupsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp(result, hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount); } @@ -1848,21 +3391,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDeviceGetConcurrentMetricGroupsExpPrologue( hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetConcurrentMetricGroupsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp(result, hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount); } auto driver_result = pfnGetConcurrentMetricGroupsExp( hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceGetConcurrentMetricGroupsExpEpilogue( hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceGetConcurrentMetricGroupsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp(result, hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetDeviceGetConcurrentMetricGroupsExp", driver_result); + return logAndPropagateResult_zetDeviceGetConcurrentMetricGroupsExp(driver_result, hDevice, metricGroupCount, phMetricGroups, pMetricGroupsCountPerConcurrentGroup, pConcurrentGroupCount); } /////////////////////////////////////////////////////////////////////////////// @@ -1886,12 +3429,12 @@ namespace validation_layer auto pfnCreateExp = context.zetDdiTable.MetricTracerExp.pfnCreateExp; if( nullptr == pfnCreateExp ) - return logAndPropagateResult("zetMetricTracerCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerCreateExpPrologue( hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerCreateExp(result, hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer); } @@ -1902,14 +3445,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerCreateExpPrologue( hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerCreateExp(result, hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer); } auto driver_result = pfnCreateExp( hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerCreateExpEpilogue( hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerCreateExp(result, hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer); } @@ -1921,7 +3464,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetMetricTracerCreateExp", driver_result); + return logAndPropagateResult_zetMetricTracerCreateExp(driver_result, hContext, hDevice, metricGroupCount, phMetricGroups, desc, hNotificationEvent, phMetricTracer); } /////////////////////////////////////////////////////////////////////////////// @@ -1936,12 +3479,12 @@ namespace validation_layer auto pfnDestroyExp = context.zetDdiTable.MetricTracerExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zetMetricTracerDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricTracer); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDestroyExpPrologue( hMetricTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDestroyExp(result, hMetricTracer); } @@ -1952,17 +3495,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerDestroyExpPrologue( hMetricTracer ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDestroyExp(result, hMetricTracer); } auto driver_result = pfnDestroyExp( hMetricTracer ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDestroyExpEpilogue( hMetricTracer ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDestroyExp(result, hMetricTracer); } - return logAndPropagateResult("zetMetricTracerDestroyExp", driver_result); + return logAndPropagateResult_zetMetricTracerDestroyExp(driver_result, hMetricTracer); } /////////////////////////////////////////////////////////////////////////////// @@ -1982,12 +3525,12 @@ namespace validation_layer auto pfnEnableExp = context.zetDdiTable.MetricTracerExp.pfnEnableExp; if( nullptr == pfnEnableExp ) - return logAndPropagateResult("zetMetricTracerEnableExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerEnableExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricTracer, synchronous); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerEnableExpPrologue( hMetricTracer, synchronous ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerEnableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerEnableExp(result, hMetricTracer, synchronous); } @@ -1998,17 +3541,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerEnableExpPrologue( hMetricTracer, synchronous ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerEnableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerEnableExp(result, hMetricTracer, synchronous); } auto driver_result = pfnEnableExp( hMetricTracer, synchronous ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerEnableExpEpilogue( hMetricTracer, synchronous ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerEnableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerEnableExp(result, hMetricTracer, synchronous); } - return logAndPropagateResult("zetMetricTracerEnableExp", driver_result); + return logAndPropagateResult_zetMetricTracerEnableExp(driver_result, hMetricTracer, synchronous); } /////////////////////////////////////////////////////////////////////////////// @@ -2029,12 +3572,12 @@ namespace validation_layer auto pfnDisableExp = context.zetDdiTable.MetricTracerExp.pfnDisableExp; if( nullptr == pfnDisableExp ) - return logAndPropagateResult("zetMetricTracerDisableExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerDisableExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricTracer, synchronous); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDisableExpPrologue( hMetricTracer, synchronous ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDisableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDisableExp(result, hMetricTracer, synchronous); } @@ -2045,17 +3588,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerDisableExpPrologue( hMetricTracer, synchronous ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDisableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDisableExp(result, hMetricTracer, synchronous); } auto driver_result = pfnDisableExp( hMetricTracer, synchronous ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDisableExpEpilogue( hMetricTracer, synchronous ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDisableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDisableExp(result, hMetricTracer, synchronous); } - return logAndPropagateResult("zetMetricTracerDisableExp", driver_result); + return logAndPropagateResult_zetMetricTracerDisableExp(driver_result, hMetricTracer, synchronous); } /////////////////////////////////////////////////////////////////////////////// @@ -2079,12 +3622,12 @@ namespace validation_layer auto pfnReadDataExp = context.zetDdiTable.MetricTracerExp.pfnReadDataExp; if( nullptr == pfnReadDataExp ) - return logAndPropagateResult("zetMetricTracerReadDataExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerReadDataExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricTracer, pRawDataSize, pRawData); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerReadDataExpPrologue( hMetricTracer, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerReadDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerReadDataExp(result, hMetricTracer, pRawDataSize, pRawData); } @@ -2095,17 +3638,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerReadDataExpPrologue( hMetricTracer, pRawDataSize, pRawData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerReadDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerReadDataExp(result, hMetricTracer, pRawDataSize, pRawData); } auto driver_result = pfnReadDataExp( hMetricTracer, pRawDataSize, pRawData ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerReadDataExpEpilogue( hMetricTracer, pRawDataSize, pRawData ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerReadDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerReadDataExp(result, hMetricTracer, pRawDataSize, pRawData); } - return logAndPropagateResult("zetMetricTracerReadDataExp", driver_result); + return logAndPropagateResult_zetMetricTracerReadDataExp(driver_result, hMetricTracer, pRawDataSize, pRawData); } /////////////////////////////////////////////////////////////////////////////// @@ -2121,12 +3664,12 @@ namespace validation_layer auto pfnCreateExp = context.zetDdiTable.MetricDecoderExp.pfnCreateExp; if( nullptr == pfnCreateExp ) - return logAndPropagateResult("zetMetricDecoderCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricDecoderCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricTracer, phMetricDecoder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderCreateExpPrologue( hMetricTracer, phMetricDecoder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderCreateExp(result, hMetricTracer, phMetricDecoder); } @@ -2137,14 +3680,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricDecoderCreateExpPrologue( hMetricTracer, phMetricDecoder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderCreateExp(result, hMetricTracer, phMetricDecoder); } auto driver_result = pfnCreateExp( hMetricTracer, phMetricDecoder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderCreateExpEpilogue( hMetricTracer, phMetricDecoder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderCreateExp(result, hMetricTracer, phMetricDecoder); } @@ -2156,7 +3699,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetMetricDecoderCreateExp", driver_result); + return logAndPropagateResult_zetMetricDecoderCreateExp(driver_result, hMetricTracer, phMetricDecoder); } /////////////////////////////////////////////////////////////////////////////// @@ -2171,12 +3714,12 @@ namespace validation_layer auto pfnDestroyExp = context.zetDdiTable.MetricDecoderExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zetMetricDecoderDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricDecoderDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, phMetricDecoder); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderDestroyExpPrologue( phMetricDecoder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderDestroyExp(result, phMetricDecoder); } @@ -2187,17 +3730,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricDecoderDestroyExpPrologue( phMetricDecoder ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderDestroyExp(result, phMetricDecoder); } auto driver_result = pfnDestroyExp( phMetricDecoder ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderDestroyExpEpilogue( phMetricDecoder ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderDestroyExp(result, phMetricDecoder); } - return logAndPropagateResult("zetMetricDecoderDestroyExp", driver_result); + return logAndPropagateResult_zetMetricDecoderDestroyExp(driver_result, phMetricDecoder); } /////////////////////////////////////////////////////////////////////////////// @@ -2223,12 +3766,12 @@ namespace validation_layer auto pfnGetDecodableMetricsExp = context.zetDdiTable.MetricDecoderExp.pfnGetDecodableMetricsExp; if( nullptr == pfnGetDecodableMetricsExp ) - return logAndPropagateResult("zetMetricDecoderGetDecodableMetricsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricDecoder, pCount, phMetrics); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderGetDecodableMetricsExpPrologue( hMetricDecoder, pCount, phMetrics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderGetDecodableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp(result, hMetricDecoder, pCount, phMetrics); } @@ -2239,14 +3782,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricDecoderGetDecodableMetricsExpPrologue( hMetricDecoder, pCount, phMetrics ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderGetDecodableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp(result, hMetricDecoder, pCount, phMetrics); } auto driver_result = pfnGetDecodableMetricsExp( hMetricDecoder, pCount, phMetrics ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDecoderGetDecodableMetricsExpEpilogue( hMetricDecoder, pCount, phMetrics ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDecoderGetDecodableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp(result, hMetricDecoder, pCount, phMetrics); } @@ -2259,7 +3802,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricDecoderGetDecodableMetricsExp", driver_result); + return logAndPropagateResult_zetMetricDecoderGetDecodableMetricsExp(driver_result, hMetricDecoder, pCount, phMetrics); } /////////////////////////////////////////////////////////////////////////////// @@ -2313,12 +3856,12 @@ namespace validation_layer auto pfnDecodeExp = context.zetDdiTable.MetricTracerExp.pfnDecodeExp; if( nullptr == pfnDecodeExp ) - return logAndPropagateResult("zetMetricTracerDecodeExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricTracerDecodeExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDecodeExpPrologue( phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDecodeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDecodeExp(result, phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries); } @@ -2329,17 +3872,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricTracerDecodeExpPrologue( phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDecodeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDecodeExp(result, phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries); } auto driver_result = pfnDecodeExp( phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricTracerDecodeExpEpilogue( phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricTracerDecodeExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricTracerDecodeExp(result, phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries); } - return logAndPropagateResult("zetMetricTracerDecodeExp", driver_result); + return logAndPropagateResult_zetMetricTracerDecodeExp(driver_result, phMetricDecoder, pRawDataSize, pRawData, metricsCount, phMetrics, pSetCount, pMetricEntriesCountPerSet, pMetricEntriesCount, pMetricEntries); } /////////////////////////////////////////////////////////////////////////////// @@ -2358,12 +3901,12 @@ namespace validation_layer auto pfnAppendMarkerExp = context.zetDdiTable.CommandListExp.pfnAppendMarkerExp; if( nullptr == pfnAppendMarkerExp ) - return logAndPropagateResult("zetCommandListAppendMarkerExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetCommandListAppendMarkerExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hCommandList, hMetricGroup, value); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMarkerExpPrologue( hCommandList, hMetricGroup, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMarkerExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMarkerExp(result, hCommandList, hMetricGroup, value); } @@ -2374,17 +3917,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetCommandListAppendMarkerExpPrologue( hCommandList, hMetricGroup, value ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMarkerExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMarkerExp(result, hCommandList, hMetricGroup, value); } auto driver_result = pfnAppendMarkerExp( hCommandList, hMetricGroup, value ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetCommandListAppendMarkerExpEpilogue( hCommandList, hMetricGroup, value ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetCommandListAppendMarkerExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetCommandListAppendMarkerExp(result, hCommandList, hMetricGroup, value); } - return logAndPropagateResult("zetCommandListAppendMarkerExp", driver_result); + return logAndPropagateResult_zetCommandListAppendMarkerExp(driver_result, hCommandList, hMetricGroup, value); } /////////////////////////////////////////////////////////////////////////////// @@ -2399,12 +3942,12 @@ namespace validation_layer auto pfnEnableMetricsExp = context.zetDdiTable.DeviceExp.pfnEnableMetricsExp; if( nullptr == pfnEnableMetricsExp ) - return logAndPropagateResult("zetDeviceEnableMetricsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDeviceEnableMetricsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceEnableMetricsExpPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceEnableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceEnableMetricsExp(result, hDevice); } @@ -2415,17 +3958,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDeviceEnableMetricsExpPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceEnableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceEnableMetricsExp(result, hDevice); } auto driver_result = pfnEnableMetricsExp( hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceEnableMetricsExpEpilogue( hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceEnableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceEnableMetricsExp(result, hDevice); } - return logAndPropagateResult("zetDeviceEnableMetricsExp", driver_result); + return logAndPropagateResult_zetDeviceEnableMetricsExp(driver_result, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -2440,12 +3983,12 @@ namespace validation_layer auto pfnDisableMetricsExp = context.zetDdiTable.DeviceExp.pfnDisableMetricsExp; if( nullptr == pfnDisableMetricsExp ) - return logAndPropagateResult("zetDeviceDisableMetricsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDeviceDisableMetricsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceDisableMetricsExpPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceDisableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceDisableMetricsExp(result, hDevice); } @@ -2456,17 +3999,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDeviceDisableMetricsExpPrologue( hDevice ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceDisableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceDisableMetricsExp(result, hDevice); } auto driver_result = pfnDisableMetricsExp( hDevice ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceDisableMetricsExpEpilogue( hDevice ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceDisableMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceDisableMetricsExp(result, hDevice); } - return logAndPropagateResult("zetDeviceDisableMetricsExp", driver_result); + return logAndPropagateResult_zetDeviceDisableMetricsExp(driver_result, hDevice); } /////////////////////////////////////////////////////////////////////////////// @@ -2503,12 +4046,12 @@ namespace validation_layer auto pfnCalculateMultipleMetricValuesExp = context.zetDdiTable.MetricGroupExp.pfnCalculateMultipleMetricValuesExp; if( nullptr == pfnCalculateMultipleMetricValuesExp ) - return logAndPropagateResult("zetMetricGroupCalculateMultipleMetricValuesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMultipleMetricValuesExpPrologue( hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMultipleMetricValuesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp(result, hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } @@ -2519,17 +4062,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupCalculateMultipleMetricValuesExpPrologue( hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMultipleMetricValuesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp(result, hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } auto driver_result = pfnCalculateMultipleMetricValuesExp( hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMultipleMetricValuesExpEpilogue( hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMultipleMetricValuesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp(result, hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } - return logAndPropagateResult("zetMetricGroupCalculateMultipleMetricValuesExp", driver_result); + return logAndPropagateResult_zetMetricGroupCalculateMultipleMetricValuesExp(driver_result, hMetricGroup, type, rawDataSize, pRawData, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } /////////////////////////////////////////////////////////////////////////////// @@ -2547,12 +4090,12 @@ namespace validation_layer auto pfnGetGlobalTimestampsExp = context.zetDdiTable.MetricGroupExp.pfnGetGlobalTimestampsExp; if( nullptr == pfnGetGlobalTimestampsExp ) - return logAndPropagateResult("zetMetricGroupGetGlobalTimestampsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetGlobalTimestampsExpPrologue( hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetGlobalTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp(result, hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp); } @@ -2563,21 +4106,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupGetGlobalTimestampsExpPrologue( hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetGlobalTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp(result, hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp); } auto driver_result = pfnGetGlobalTimestampsExp( hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetGlobalTimestampsExpEpilogue( hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetGlobalTimestampsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp(result, hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetMetricGroupGetGlobalTimestampsExp", driver_result); + return logAndPropagateResult_zetMetricGroupGetGlobalTimestampsExp(driver_result, hMetricGroup, synchronizedWithHost, globalTimestamp, metricTimestamp); } /////////////////////////////////////////////////////////////////////////////// @@ -2600,12 +4143,12 @@ namespace validation_layer auto pfnGetExportDataExp = context.zetDdiTable.MetricGroupExp.pfnGetExportDataExp; if( nullptr == pfnGetExportDataExp ) - return logAndPropagateResult("zetMetricGroupGetExportDataExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupGetExportDataExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetExportDataExpPrologue( hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetExportDataExp(result, hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData); } @@ -2616,21 +4159,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupGetExportDataExpPrologue( hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetExportDataExp(result, hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData); } auto driver_result = pfnGetExportDataExp( hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupGetExportDataExpEpilogue( hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupGetExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupGetExportDataExp(result, hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetMetricGroupGetExportDataExp", driver_result); + return logAndPropagateResult_zetMetricGroupGetExportDataExp(driver_result, hMetricGroup, pRawData, rawDataSize, pExportDataSize, pExportData); } /////////////////////////////////////////////////////////////////////////////// @@ -2668,12 +4211,12 @@ namespace validation_layer auto pfnCalculateMetricExportDataExp = context.zetDdiTable.MetricGroupExp.pfnCalculateMetricExportDataExp; if( nullptr == pfnCalculateMetricExportDataExp ) - return logAndPropagateResult("zetMetricGroupCalculateMetricExportDataExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMetricExportDataExpPrologue( hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp(result, hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } @@ -2684,17 +4227,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupCalculateMetricExportDataExpPrologue( hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp(result, hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } auto driver_result = pfnCalculateMetricExportDataExp( hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCalculateMetricExportDataExpEpilogue( hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCalculateMetricExportDataExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp(result, hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } - return logAndPropagateResult("zetMetricGroupCalculateMetricExportDataExp", driver_result); + return logAndPropagateResult_zetMetricGroupCalculateMetricExportDataExp(driver_result, hDriver, type, exportDataSize, pExportData, pCalculateDescriptor, pSetCount, pTotalMetricValueCount, pMetricCounts, pMetricValues); } /////////////////////////////////////////////////////////////////////////////// @@ -2718,12 +4261,12 @@ namespace validation_layer auto pfnGetExp = context.zetDdiTable.MetricProgrammableExp.pfnGetExp; if( nullptr == pfnGetExp ) - return logAndPropagateResult("zetMetricProgrammableGetExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricProgrammableGetExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pCount, phMetricProgrammables); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetExpPrologue( hDevice, pCount, phMetricProgrammables ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetExp(result, hDevice, pCount, phMetricProgrammables); } @@ -2734,14 +4277,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricProgrammableGetExpPrologue( hDevice, pCount, phMetricProgrammables ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetExp(result, hDevice, pCount, phMetricProgrammables); } auto driver_result = pfnGetExp( hDevice, pCount, phMetricProgrammables ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetExpEpilogue( hDevice, pCount, phMetricProgrammables ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetExp(result, hDevice, pCount, phMetricProgrammables); } @@ -2754,7 +4297,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricProgrammableGetExp", driver_result); + return logAndPropagateResult_zetMetricProgrammableGetExp(driver_result, hDevice, pCount, phMetricProgrammables); } /////////////////////////////////////////////////////////////////////////////// @@ -2770,12 +4313,12 @@ namespace validation_layer auto pfnGetPropertiesExp = context.zetDdiTable.MetricProgrammableExp.pfnGetPropertiesExp; if( nullptr == pfnGetPropertiesExp ) - return logAndPropagateResult("zetMetricProgrammableGetPropertiesExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricProgrammableGetPropertiesExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricProgrammable, pProperties); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetPropertiesExpPrologue( hMetricProgrammable, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetPropertiesExp(result, hMetricProgrammable, pProperties); } @@ -2786,21 +4329,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricProgrammableGetPropertiesExpPrologue( hMetricProgrammable, pProperties ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetPropertiesExp(result, hMetricProgrammable, pProperties); } auto driver_result = pfnGetPropertiesExp( hMetricProgrammable, pProperties ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetPropertiesExpEpilogue( hMetricProgrammable, pProperties ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetPropertiesExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetPropertiesExp(result, hMetricProgrammable, pProperties); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetMetricProgrammableGetPropertiesExp", driver_result); + return logAndPropagateResult_zetMetricProgrammableGetPropertiesExp(driver_result, hMetricProgrammable, pProperties); } /////////////////////////////////////////////////////////////////////////////// @@ -2823,12 +4366,12 @@ namespace validation_layer auto pfnGetParamInfoExp = context.zetDdiTable.MetricProgrammableExp.pfnGetParamInfoExp; if( nullptr == pfnGetParamInfoExp ) - return logAndPropagateResult("zetMetricProgrammableGetParamInfoExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricProgrammableGetParamInfoExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricProgrammable, pParameterCount, pParameterInfo); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetParamInfoExpPrologue( hMetricProgrammable, pParameterCount, pParameterInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamInfoExp(result, hMetricProgrammable, pParameterCount, pParameterInfo); } @@ -2839,21 +4382,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricProgrammableGetParamInfoExpPrologue( hMetricProgrammable, pParameterCount, pParameterInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamInfoExp(result, hMetricProgrammable, pParameterCount, pParameterInfo); } auto driver_result = pfnGetParamInfoExp( hMetricProgrammable, pParameterCount, pParameterInfo ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetParamInfoExpEpilogue( hMetricProgrammable, pParameterCount, pParameterInfo ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamInfoExp(result, hMetricProgrammable, pParameterCount, pParameterInfo); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetMetricProgrammableGetParamInfoExp", driver_result); + return logAndPropagateResult_zetMetricProgrammableGetParamInfoExp(driver_result, hMetricProgrammable, pParameterCount, pParameterInfo); } /////////////////////////////////////////////////////////////////////////////// @@ -2877,12 +4420,12 @@ namespace validation_layer auto pfnGetParamValueInfoExp = context.zetDdiTable.MetricProgrammableExp.pfnGetParamValueInfoExp; if( nullptr == pfnGetParamValueInfoExp ) - return logAndPropagateResult("zetMetricProgrammableGetParamValueInfoExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetParamValueInfoExpPrologue( hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamValueInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp(result, hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo); } @@ -2893,21 +4436,21 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricProgrammableGetParamValueInfoExpPrologue( hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamValueInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp(result, hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo); } auto driver_result = pfnGetParamValueInfoExp( hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricProgrammableGetParamValueInfoExpEpilogue( hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricProgrammableGetParamValueInfoExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp(result, hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo); } if( driver_result == ZE_RESULT_SUCCESS && context.enableHandleLifetime ){ } - return logAndPropagateResult("zetMetricProgrammableGetParamValueInfoExp", driver_result); + return logAndPropagateResult_zetMetricProgrammableGetParamValueInfoExp(driver_result, hMetricProgrammable, parameterOrdinal, pValueInfoCount, pValueInfo); } /////////////////////////////////////////////////////////////////////////////// @@ -2938,12 +4481,12 @@ namespace validation_layer auto pfnCreateFromProgrammableExp2 = context.zetDdiTable.MetricExp.pfnCreateFromProgrammableExp2; if( nullptr == pfnCreateFromProgrammableExp2 ) - return logAndPropagateResult("zetMetricCreateFromProgrammableExp2", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricCreateFromProgrammableExp2(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricCreateFromProgrammableExp2Prologue( hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp2(result, hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles); } @@ -2954,14 +4497,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricCreateFromProgrammableExp2Prologue( hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp2(result, hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles); } auto driver_result = pfnCreateFromProgrammableExp2( hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricCreateFromProgrammableExp2Epilogue( hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp2", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp2(result, hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles); } @@ -2974,7 +4517,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricCreateFromProgrammableExp2", driver_result); + return logAndPropagateResult_zetMetricCreateFromProgrammableExp2(driver_result, hMetricProgrammable, parameterCount, pParameterValues, pName, pDescription, pMetricHandleCount, phMetricHandles); } /////////////////////////////////////////////////////////////////////////////// @@ -3005,12 +4548,12 @@ namespace validation_layer auto pfnCreateFromProgrammableExp = context.zetDdiTable.MetricExp.pfnCreateFromProgrammableExp; if( nullptr == pfnCreateFromProgrammableExp ) - return logAndPropagateResult("zetMetricCreateFromProgrammableExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricCreateFromProgrammableExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricCreateFromProgrammableExpPrologue( hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp(result, hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles); } @@ -3021,14 +4564,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricCreateFromProgrammableExpPrologue( hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp(result, hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles); } auto driver_result = pfnCreateFromProgrammableExp( hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricCreateFromProgrammableExpEpilogue( hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricCreateFromProgrammableExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricCreateFromProgrammableExp(result, hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles); } @@ -3041,7 +4584,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetMetricCreateFromProgrammableExp", driver_result); + return logAndPropagateResult_zetMetricCreateFromProgrammableExp(driver_result, hMetricProgrammable, pParameterValues, parameterCount, pName, pDescription, pMetricHandleCount, phMetricHandles); } /////////////////////////////////////////////////////////////////////////////// @@ -3075,12 +4618,12 @@ namespace validation_layer auto pfnCreateMetricGroupsFromMetricsExp = context.zetDdiTable.DeviceExp.pfnCreateMetricGroupsFromMetricsExp; if( nullptr == pfnCreateMetricGroupsFromMetricsExp ) - return logAndPropagateResult("zetDeviceCreateMetricGroupsFromMetricsExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceCreateMetricGroupsFromMetricsExpPrologue( hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceCreateMetricGroupsFromMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp(result, hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup); } @@ -3091,14 +4634,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetDeviceCreateMetricGroupsFromMetricsExpPrologue( hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceCreateMetricGroupsFromMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp(result, hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup); } auto driver_result = pfnCreateMetricGroupsFromMetricsExp( hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetDeviceCreateMetricGroupsFromMetricsExpEpilogue( hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetDeviceCreateMetricGroupsFromMetricsExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp(result, hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup); } @@ -3111,7 +4654,7 @@ namespace validation_layer } } } - return logAndPropagateResult("zetDeviceCreateMetricGroupsFromMetricsExp", driver_result); + return logAndPropagateResult_zetDeviceCreateMetricGroupsFromMetricsExp(driver_result, hDevice, metricCount, phMetrics, pMetricGroupNamePrefix, pDescription, pMetricGroupCount, phMetricGroup); } /////////////////////////////////////////////////////////////////////////////// @@ -3133,12 +4676,12 @@ namespace validation_layer auto pfnCreateExp = context.zetDdiTable.MetricGroupExp.pfnCreateExp; if( nullptr == pfnCreateExp ) - return logAndPropagateResult("zetMetricGroupCreateExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupCreateExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hDevice, pName, pDescription, samplingType, phMetricGroup); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCreateExpPrologue( hDevice, pName, pDescription, samplingType, phMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCreateExp(result, hDevice, pName, pDescription, samplingType, phMetricGroup); } @@ -3149,14 +4692,14 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupCreateExpPrologue( hDevice, pName, pDescription, samplingType, phMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCreateExp(result, hDevice, pName, pDescription, samplingType, phMetricGroup); } auto driver_result = pfnCreateExp( hDevice, pName, pDescription, samplingType, phMetricGroup ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCreateExpEpilogue( hDevice, pName, pDescription, samplingType, phMetricGroup ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCreateExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCreateExp(result, hDevice, pName, pDescription, samplingType, phMetricGroup); } @@ -3168,7 +4711,7 @@ namespace validation_layer } } - return logAndPropagateResult("zetMetricGroupCreateExp", driver_result); + return logAndPropagateResult_zetMetricGroupCreateExp(driver_result, hDevice, pName, pDescription, samplingType, phMetricGroup); } /////////////////////////////////////////////////////////////////////////////// @@ -3191,12 +4734,12 @@ namespace validation_layer auto pfnAddMetricExp = context.zetDdiTable.MetricGroupExp.pfnAddMetricExp; if( nullptr == pfnAddMetricExp ) - return logAndPropagateResult("zetMetricGroupAddMetricExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupAddMetricExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, hMetric, pErrorStringSize, pErrorString); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupAddMetricExpPrologue( hMetricGroup, hMetric, pErrorStringSize, pErrorString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupAddMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupAddMetricExp(result, hMetricGroup, hMetric, pErrorStringSize, pErrorString); } @@ -3207,17 +4750,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupAddMetricExpPrologue( hMetricGroup, hMetric, pErrorStringSize, pErrorString ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupAddMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupAddMetricExp(result, hMetricGroup, hMetric, pErrorStringSize, pErrorString); } auto driver_result = pfnAddMetricExp( hMetricGroup, hMetric, pErrorStringSize, pErrorString ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupAddMetricExpEpilogue( hMetricGroup, hMetric, pErrorStringSize, pErrorString ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupAddMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupAddMetricExp(result, hMetricGroup, hMetric, pErrorStringSize, pErrorString); } - return logAndPropagateResult("zetMetricGroupAddMetricExp", driver_result); + return logAndPropagateResult_zetMetricGroupAddMetricExp(driver_result, hMetricGroup, hMetric, pErrorStringSize, pErrorString); } /////////////////////////////////////////////////////////////////////////////// @@ -3233,12 +4776,12 @@ namespace validation_layer auto pfnRemoveMetricExp = context.zetDdiTable.MetricGroupExp.pfnRemoveMetricExp; if( nullptr == pfnRemoveMetricExp ) - return logAndPropagateResult("zetMetricGroupRemoveMetricExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupRemoveMetricExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup, hMetric); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupRemoveMetricExpPrologue( hMetricGroup, hMetric ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupRemoveMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupRemoveMetricExp(result, hMetricGroup, hMetric); } @@ -3249,17 +4792,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupRemoveMetricExpPrologue( hMetricGroup, hMetric ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupRemoveMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupRemoveMetricExp(result, hMetricGroup, hMetric); } auto driver_result = pfnRemoveMetricExp( hMetricGroup, hMetric ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupRemoveMetricExpEpilogue( hMetricGroup, hMetric ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupRemoveMetricExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupRemoveMetricExp(result, hMetricGroup, hMetric); } - return logAndPropagateResult("zetMetricGroupRemoveMetricExp", driver_result); + return logAndPropagateResult_zetMetricGroupRemoveMetricExp(driver_result, hMetricGroup, hMetric); } /////////////////////////////////////////////////////////////////////////////// @@ -3274,12 +4817,12 @@ namespace validation_layer auto pfnCloseExp = context.zetDdiTable.MetricGroupExp.pfnCloseExp; if( nullptr == pfnCloseExp ) - return logAndPropagateResult("zetMetricGroupCloseExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupCloseExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCloseExpPrologue( hMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCloseExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCloseExp(result, hMetricGroup); } @@ -3290,17 +4833,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupCloseExpPrologue( hMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCloseExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCloseExp(result, hMetricGroup); } auto driver_result = pfnCloseExp( hMetricGroup ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupCloseExpEpilogue( hMetricGroup ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupCloseExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupCloseExp(result, hMetricGroup); } - return logAndPropagateResult("zetMetricGroupCloseExp", driver_result); + return logAndPropagateResult_zetMetricGroupCloseExp(driver_result, hMetricGroup); } /////////////////////////////////////////////////////////////////////////////// @@ -3315,12 +4858,12 @@ namespace validation_layer auto pfnDestroyExp = context.zetDdiTable.MetricGroupExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zetMetricGroupDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricGroupDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetricGroup); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupDestroyExpPrologue( hMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupDestroyExp(result, hMetricGroup); } @@ -3331,17 +4874,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricGroupDestroyExpPrologue( hMetricGroup ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupDestroyExp(result, hMetricGroup); } auto driver_result = pfnDestroyExp( hMetricGroup ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricGroupDestroyExpEpilogue( hMetricGroup ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricGroupDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricGroupDestroyExp(result, hMetricGroup); } - return logAndPropagateResult("zetMetricGroupDestroyExp", driver_result); + return logAndPropagateResult_zetMetricGroupDestroyExp(driver_result, hMetricGroup); } /////////////////////////////////////////////////////////////////////////////// @@ -3356,12 +4899,12 @@ namespace validation_layer auto pfnDestroyExp = context.zetDdiTable.MetricExp.pfnDestroyExp; if( nullptr == pfnDestroyExp ) - return logAndPropagateResult("zetMetricDestroyExp", ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); + return logAndPropagateResult_zetMetricDestroyExp(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, hMetric); auto numValHandlers = context.validationHandlers.size(); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDestroyExpPrologue( hMetric ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDestroyExp(result, hMetric); } @@ -3372,17 +4915,17 @@ namespace validation_layer if(context.enableHandleLifetime ){ auto result = context.handleLifetime->zetHandleLifetime.zetMetricDestroyExpPrologue( hMetric ); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDestroyExp(result, hMetric); } auto driver_result = pfnDestroyExp( hMetric ); for (size_t i = 0; i < numValHandlers; i++) { auto result = context.validationHandlers[i]->zetValidation->zetMetricDestroyExpEpilogue( hMetric ,driver_result); - if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult("zetMetricDestroyExp", result); + if(result!=ZE_RESULT_SUCCESS) return logAndPropagateResult_zetMetricDestroyExp(result, hMetric); } - return logAndPropagateResult("zetMetricDestroyExp", driver_result); + return logAndPropagateResult_zetMetricDestroyExp(driver_result, hMetric); } } // namespace validation_layer diff --git a/source/utils/CMakeLists.txt b/source/utils/CMakeLists.txt index b77f2641..7e78d884 100644 --- a/source/utils/CMakeLists.txt +++ b/source/utils/CMakeLists.txt @@ -1,7 +1,7 @@ # Copyright (C) 2024 Intel Corporation # SPDX-License-Identifier: MIT -set(logging_files logging.h logging.cpp) +set(logging_files logging.h logging.cpp ze_to_string.h zes_to_string.h zet_to_string.h zer_to_string.h) add_library(level_zero_utils STATIC ${logging_files}) if(SYSTEM_SPDLOG) diff --git a/source/utils/ze_to_string.h b/source/utils/ze_to_string.h new file mode 100644 index 00000000..a8068d26 --- /dev/null +++ b/source/utils/ze_to_string.h @@ -0,0 +1,2685 @@ +/* + * ***THIS FILE IS GENERATED. *** + * See to_string.h.mako for modifications + * + * Copyright (C) 2025 Intel Corporation + * + * SPDX-License-Identifier: MIT + * + * @file ze_to_string.h + * + * to_string functions for Level Zero types + */ + +#ifndef _ZE_TO_STRING_H +#define _ZE_TO_STRING_H + +#include "ze_api.h" +#include +#include +#include + +namespace loader { + +// Forward declarations +std::string to_string(const ze_result_t result); + +// Pointer to_string +template +inline std::string to_string(const T* ptr) { + if (ptr == nullptr) { + return "nullptr"; + } + std::ostringstream oss; + oss << "0x" << std::hex << reinterpret_cast(ptr); + return oss.str(); +} + +// Handle to_string functions +inline std::string to_string(ze_driver_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_device_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_context_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_command_queue_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_command_list_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_fence_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_event_pool_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_event_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_image_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_module_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_module_build_log_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_kernel_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_sampler_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_physical_mem_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_fabric_vertex_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_fabric_edge_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_external_semaphore_ext_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_rtas_builder_ext_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_rtas_parallel_operation_ext_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_rtas_builder_exp_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +inline std::string to_string(ze_rtas_parallel_operation_exp_handle_t handle) { + return to_string(reinterpret_cast(handle)); +} + +// For primitive types and Level Zero typedef'd types +// Since most Level Zero types are typedef'd to uint32_t, we can't distinguish them by type +inline std::string to_string(uint32_t value) { return std::to_string(value); } +inline std::string to_string(uint64_t value) { return std::to_string(value); } +inline std::string to_string(uint8_t value) { return std::to_string(static_cast(value)); } +inline std::string to_string(uint16_t value) { return std::to_string(value); } +inline std::string to_string(int32_t value) { return std::to_string(value); } +inline std::string to_string(int64_t value) { return std::to_string(value); } +#if SIZE_MAX != UINT64_MAX +inline std::string to_string(size_t value) { return std::to_string(value); } +#endif +inline std::string to_string(double value) { return std::to_string(value); } +inline std::string to_string(const char* str) { + if (!str) return "nullptr"; + return std::string("\"") + str + "\""; +} + +// Pointer to primitive types - dereference and print value +inline std::string to_string(const uint32_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint64_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint8_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const uint16_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const int32_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +inline std::string to_string(const int64_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +#if SIZE_MAX != UINT64_MAX +inline std::string to_string(const size_t* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} +#endif +inline std::string to_string(const double* ptr) { + if (!ptr) return "nullptr"; + return to_string(*ptr); +} + +// Struct to_string functions +inline std::string to_string(const ze_ipc_mem_handle_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "data=" << to_string(desc->data); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_ipc_mem_handle_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_ipc_event_pool_handle_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "data=" << to_string(desc->data); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_ipc_event_pool_handle_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_base_cb_params_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_base_cb_params_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_base_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_base_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_base_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_base_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_init_driver_type_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_init_driver_type_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", driverVersion=" << to_string(desc->driverVersion); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_ipc_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_ipc_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_extension_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "name=" << to_string(desc->name); + oss << ", version=" << to_string(desc->version); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_extension_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", vendorId=" << to_string(desc->vendorId); + oss << ", deviceId=" << to_string(desc->deviceId); + oss << ", flags=" << to_string(&desc->flags); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", coreClockRate=" << to_string(desc->coreClockRate); + oss << ", maxMemAllocSize=" << to_string(desc->maxMemAllocSize); + oss << ", maxHardwareContexts=" << to_string(desc->maxHardwareContexts); + oss << ", maxCommandQueuePriority=" << to_string(desc->maxCommandQueuePriority); + oss << ", numThreadsPerEU=" << to_string(desc->numThreadsPerEU); + oss << ", physicalEUSimdWidth=" << to_string(desc->physicalEUSimdWidth); + oss << ", numEUsPerSubslice=" << to_string(desc->numEUsPerSubslice); + oss << ", numSubslicesPerSlice=" << to_string(desc->numSubslicesPerSlice); + oss << ", numSlices=" << to_string(desc->numSlices); + oss << ", timerResolution=" << to_string(desc->timerResolution); + oss << ", timestampValidBits=" << to_string(desc->timestampValidBits); + oss << ", kernelTimestampValidBits=" << to_string(desc->kernelTimestampValidBits); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", name=" << to_string(desc->name); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_thread_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "slice=" << to_string(desc->slice); + oss << ", subslice=" << to_string(desc->subslice); + oss << ", eu=" << to_string(desc->eu); + oss << ", thread=" << to_string(desc->thread); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_thread_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_compute_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", maxTotalGroupSize=" << to_string(desc->maxTotalGroupSize); + oss << ", maxGroupSizeX=" << to_string(desc->maxGroupSizeX); + oss << ", maxGroupSizeY=" << to_string(desc->maxGroupSizeY); + oss << ", maxGroupSizeZ=" << to_string(desc->maxGroupSizeZ); + oss << ", maxGroupCountX=" << to_string(desc->maxGroupCountX); + oss << ", maxGroupCountY=" << to_string(desc->maxGroupCountY); + oss << ", maxGroupCountZ=" << to_string(desc->maxGroupCountZ); + oss << ", maxSharedLocalMemory=" << to_string(desc->maxSharedLocalMemory); + oss << ", numSubGroupSizes=" << to_string(desc->numSubGroupSizes); + oss << ", subGroupSizes=" << to_string(desc->subGroupSizes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_compute_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_native_kernel_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_native_kernel_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_module_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", spirvVersionSupported=" << to_string(desc->spirvVersionSupported); + oss << ", flags=" << to_string(&desc->flags); + oss << ", fp16flags=" << to_string(&desc->fp16flags); + oss << ", fp32flags=" << to_string(&desc->fp32flags); + oss << ", fp64flags=" << to_string(&desc->fp64flags); + oss << ", maxArgumentsSize=" << to_string(desc->maxArgumentsSize); + oss << ", printfBufferSize=" << to_string(desc->printfBufferSize); + oss << ", nativeKernelSupported=" << to_string(&desc->nativeKernelSupported); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_module_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_command_queue_group_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", maxMemoryFillPatternSize=" << to_string(desc->maxMemoryFillPatternSize); + oss << ", numQueues=" << to_string(desc->numQueues); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_command_queue_group_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_memory_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", maxClockRate=" << to_string(desc->maxClockRate); + oss << ", maxBusWidth=" << to_string(desc->maxBusWidth); + oss << ", totalSize=" << to_string(desc->totalSize); + oss << ", name=" << to_string(desc->name); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_memory_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_memory_access_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", hostAllocCapabilities=" << to_string(&desc->hostAllocCapabilities); + oss << ", deviceAllocCapabilities=" << to_string(&desc->deviceAllocCapabilities); + oss << ", sharedSingleDeviceAllocCapabilities=" << to_string(&desc->sharedSingleDeviceAllocCapabilities); + oss << ", sharedCrossDeviceAllocCapabilities=" << to_string(&desc->sharedCrossDeviceAllocCapabilities); + oss << ", sharedSystemAllocCapabilities=" << to_string(&desc->sharedSystemAllocCapabilities); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_memory_access_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_cache_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", cacheSize=" << to_string(desc->cacheSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_cache_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_image_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", maxImageDims1D=" << to_string(desc->maxImageDims1D); + oss << ", maxImageDims2D=" << to_string(desc->maxImageDims2D); + oss << ", maxImageDims3D=" << to_string(desc->maxImageDims3D); + oss << ", maxImageBufferSize=" << to_string(desc->maxImageBufferSize); + oss << ", maxImageArraySlices=" << to_string(desc->maxImageArraySlices); + oss << ", maxSamplers=" << to_string(desc->maxSamplers); + oss << ", maxReadImageArgs=" << to_string(desc->maxReadImageArgs); + oss << ", maxWriteImageArgs=" << to_string(desc->maxWriteImageArgs); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_image_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_external_memory_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", memoryAllocationImportTypes=" << to_string(&desc->memoryAllocationImportTypes); + oss << ", memoryAllocationExportTypes=" << to_string(&desc->memoryAllocationExportTypes); + oss << ", imageImportTypes=" << to_string(&desc->imageImportTypes); + oss << ", imageExportTypes=" << to_string(&desc->imageExportTypes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_external_memory_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_p2p_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_p2p_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_context_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_context_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_command_queue_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", ordinal=" << to_string(desc->ordinal); + oss << ", index=" << to_string(desc->index); + oss << ", flags=" << to_string(&desc->flags); + oss << ", mode=" << to_string(&desc->mode); + oss << ", priority=" << to_string(&desc->priority); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_command_queue_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_command_list_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandQueueGroupOrdinal=" << to_string(desc->commandQueueGroupOrdinal); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_command_list_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_copy_region_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "originX=" << to_string(desc->originX); + oss << ", originY=" << to_string(desc->originY); + oss << ", originZ=" << to_string(desc->originZ); + oss << ", width=" << to_string(desc->width); + oss << ", height=" << to_string(desc->height); + oss << ", depth=" << to_string(desc->depth); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_copy_region_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_region_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "originX=" << to_string(desc->originX); + oss << ", originY=" << to_string(desc->originY); + oss << ", originZ=" << to_string(desc->originZ); + oss << ", width=" << to_string(desc->width); + oss << ", height=" << to_string(desc->height); + oss << ", depth=" << to_string(desc->depth); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_region_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_event_pool_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", count=" << to_string(desc->count); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_event_pool_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_event_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", index=" << to_string(desc->index); + oss << ", signal=" << to_string(&desc->signal); + oss << ", wait=" << to_string(&desc->wait); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_event_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_timestamp_data_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "kernelStart=" << to_string(desc->kernelStart); + oss << ", kernelEnd=" << to_string(desc->kernelEnd); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_timestamp_data_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_timestamp_result_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "global=" << to_string(&desc->global); + oss << ", context=" << to_string(&desc->context); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_timestamp_result_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_fence_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_fence_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_format_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "layout=" << to_string(&desc->layout); + oss << ", type=" << to_string(&desc->type); + oss << ", x=" << to_string(&desc->x); + oss << ", y=" << to_string(&desc->y); + oss << ", z=" << to_string(&desc->z); + oss << ", w=" << to_string(&desc->w); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_format_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", type=" << to_string(&desc->type); + oss << ", format=" << to_string(&desc->format); + oss << ", width=" << to_string(desc->width); + oss << ", height=" << to_string(desc->height); + oss << ", depth=" << to_string(desc->depth); + oss << ", arraylevels=" << to_string(desc->arraylevels); + oss << ", miplevels=" << to_string(desc->miplevels); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", samplerFilterFlags=" << to_string(&desc->samplerFilterFlags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_mem_alloc_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", ordinal=" << to_string(desc->ordinal); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_mem_alloc_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_host_mem_alloc_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_host_mem_alloc_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_memory_allocation_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", id=" << to_string(desc->id); + oss << ", pageSize=" << to_string(desc->pageSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_memory_allocation_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memory_export_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memory_export_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memory_import_fd_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", fd=" << to_string(desc->fd); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memory_import_fd_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memory_export_fd_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", fd=" << to_string(desc->fd); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memory_export_fd_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memory_import_win32_handle_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", handle=" << to_string(desc->handle); + oss << ", name=" << to_string(desc->name); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memory_import_win32_handle_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memory_export_win32_handle_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", handle=" << to_string(desc->handle); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memory_export_win32_handle_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_module_constants_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "numConstants=" << to_string(desc->numConstants); + oss << ", pConstantIds=" << to_string(desc->pConstantIds); + oss << ", pConstantValues=" << to_string(desc->pConstantValues); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_module_constants_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_module_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", format=" << to_string(&desc->format); + oss << ", inputSize=" << to_string(desc->inputSize); + oss << ", pInputModule=" << to_string(desc->pInputModule); + oss << ", pBuildFlags=" << to_string(desc->pBuildFlags); + oss << ", pConstants=" << to_string(desc->pConstants); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_module_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_command_list_append_launch_kernel_param_cooperative_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", isCooperative=" << to_string(&desc->isCooperative); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_command_list_append_launch_kernel_param_cooperative_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_module_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_module_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", pKernelName=" << to_string(desc->pKernelName); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "kid=" << to_string(desc->kid); + oss << ", mid=" << to_string(desc->mid); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", numKernelArgs=" << to_string(desc->numKernelArgs); + oss << ", requiredGroupSizeX=" << to_string(desc->requiredGroupSizeX); + oss << ", requiredGroupSizeY=" << to_string(desc->requiredGroupSizeY); + oss << ", requiredGroupSizeZ=" << to_string(desc->requiredGroupSizeZ); + oss << ", requiredNumSubGroups=" << to_string(desc->requiredNumSubGroups); + oss << ", requiredSubgroupSize=" << to_string(desc->requiredSubgroupSize); + oss << ", maxSubgroupSize=" << to_string(desc->maxSubgroupSize); + oss << ", maxNumSubgroups=" << to_string(desc->maxNumSubgroups); + oss << ", localMemSize=" << to_string(desc->localMemSize); + oss << ", privateMemSize=" << to_string(desc->privateMemSize); + oss << ", spillMemSize=" << to_string(desc->spillMemSize); + oss << ", uuid=" << to_string(&desc->uuid); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_preferred_group_size_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", preferredMultiple=" << to_string(desc->preferredMultiple); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_preferred_group_size_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_group_count_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "groupCountX=" << to_string(desc->groupCountX); + oss << ", groupCountY=" << to_string(desc->groupCountY); + oss << ", groupCountZ=" << to_string(desc->groupCountZ); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_group_count_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_group_size_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "groupSizeX=" << to_string(desc->groupSizeX); + oss << ", groupSizeY=" << to_string(desc->groupSizeY); + oss << ", groupSizeZ=" << to_string(desc->groupSizeZ); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_group_size_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_module_program_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", count=" << to_string(desc->count); + oss << ", inputSizes=" << to_string(desc->inputSizes); + oss << ", pInputModules=" << to_string(desc->pInputModules); + oss << ", pBuildFlags=" << to_string(desc->pBuildFlags); + oss << ", pConstants=" << to_string(desc->pConstants); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_module_program_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_raytracing_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", maxBVHLevels=" << to_string(desc->maxBVHLevels); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_raytracing_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_raytracing_mem_alloc_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_raytracing_mem_alloc_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_sampler_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", addressMode=" << to_string(&desc->addressMode); + oss << ", filterMode=" << to_string(&desc->filterMode); + oss << ", isNormalized=" << to_string(&desc->isNormalized); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_sampler_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_physical_mem_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_physical_mem_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_float_atomic_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", fp16Flags=" << to_string(&desc->fp16Flags); + oss << ", fp32Flags=" << to_string(&desc->fp32Flags); + oss << ", fp64Flags=" << to_string(&desc->fp64Flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_float_atomic_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_relaxed_allocation_limits_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_relaxed_allocation_limits_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_ddi_handles_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_ddi_handles_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_semaphore_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_semaphore_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_semaphore_win32_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", handle=" << to_string(desc->handle); + oss << ", name=" << to_string(desc->name); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_semaphore_win32_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_semaphore_fd_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", fd=" << to_string(desc->fd); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_semaphore_fd_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_semaphore_signal_params_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", value=" << to_string(desc->value); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_semaphore_signal_params_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_semaphore_wait_params_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", value=" << to_string(desc->value); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_semaphore_wait_params_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_cache_line_size_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", cacheLineSize=" << to_string(desc->cacheLineSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_cache_line_size_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", builderVersion=" << to_string(&desc->builderVersion); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", rtasBufferSizeBytesExpected=" << to_string(desc->rtasBufferSizeBytesExpected); + oss << ", rtasBufferSizeBytesMaxRequired=" << to_string(desc->rtasBufferSizeBytesMaxRequired); + oss << ", scratchBufferSizeBytes=" << to_string(desc->scratchBufferSizeBytes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_parallel_operation_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", maxConcurrency=" << to_string(desc->maxConcurrency); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_parallel_operation_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_device_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", rtasFormat=" << to_string(&desc->rtasFormat); + oss << ", rtasBufferAlignment=" << to_string(desc->rtasBufferAlignment); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_device_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_float3_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "x=" << to_string(desc->x); + oss << ", y=" << to_string(desc->y); + oss << ", z=" << to_string(desc->z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_float3_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_column_major_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", p_z=" << to_string(desc->p_z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_column_major_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_aligned_column_major_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", pad0=" << to_string(desc->pad0); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", pad1=" << to_string(desc->pad1); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", pad2=" << to_string(desc->pad2); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", p_z=" << to_string(desc->p_z); + oss << ", pad3=" << to_string(desc->pad3); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_aligned_column_major_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_row_major_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", p_z=" << to_string(desc->p_z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_row_major_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_aabb_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "lower=" << to_string(&desc->lower); + oss << ", upper=" << to_string(&desc->upper); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_aabb_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_triangle_indices_uint32_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "v0=" << to_string(desc->v0); + oss << ", v1=" << to_string(desc->v1); + oss << ", v2=" << to_string(desc->v2); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_triangle_indices_uint32_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_quad_indices_uint32_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "v0=" << to_string(desc->v0); + oss << ", v1=" << to_string(desc->v1); + oss << ", v2=" << to_string(desc->v2); + oss << ", v3=" << to_string(desc->v3); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_quad_indices_uint32_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_geometry_info_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_geometry_info_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_triangles_geometry_info_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", triangleFormat=" << to_string(&desc->triangleFormat); + oss << ", vertexFormat=" << to_string(&desc->vertexFormat); + oss << ", triangleCount=" << to_string(desc->triangleCount); + oss << ", vertexCount=" << to_string(desc->vertexCount); + oss << ", triangleStride=" << to_string(desc->triangleStride); + oss << ", vertexStride=" << to_string(desc->vertexStride); + oss << ", pTriangleBuffer=" << to_string(desc->pTriangleBuffer); + oss << ", pVertexBuffer=" << to_string(desc->pVertexBuffer); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_triangles_geometry_info_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_quads_geometry_info_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", quadFormat=" << to_string(&desc->quadFormat); + oss << ", vertexFormat=" << to_string(&desc->vertexFormat); + oss << ", quadCount=" << to_string(desc->quadCount); + oss << ", vertexCount=" << to_string(desc->vertexCount); + oss << ", quadStride=" << to_string(desc->quadStride); + oss << ", vertexStride=" << to_string(desc->vertexStride); + oss << ", pQuadBuffer=" << to_string(desc->pQuadBuffer); + oss << ", pVertexBuffer=" << to_string(desc->pVertexBuffer); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_quads_geometry_info_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_geometry_aabbs_ext_cb_params_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", primID=" << to_string(desc->primID); + oss << ", primIDCount=" << to_string(desc->primIDCount); + oss << ", pGeomUserPtr=" << to_string(desc->pGeomUserPtr); + oss << ", pBuildUserPtr=" << to_string(desc->pBuildUserPtr); + oss << ", pBoundsOut=" << to_string(desc->pBoundsOut); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_geometry_aabbs_ext_cb_params_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_procedural_geometry_info_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", reserved=" << to_string(desc->reserved); + oss << ", primCount=" << to_string(desc->primCount); + oss << ", pfnGetBoundsCb=" << to_string(&desc->pfnGetBoundsCb); + oss << ", pGeomUserPtr=" << to_string(desc->pGeomUserPtr); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_procedural_geometry_info_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_instance_geometry_info_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", instanceFlags=" << to_string(&desc->instanceFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", transformFormat=" << to_string(&desc->transformFormat); + oss << ", instanceUserID=" << to_string(desc->instanceUserID); + oss << ", pTransform=" << to_string(desc->pTransform); + oss << ", pBounds=" << to_string(desc->pBounds); + oss << ", pAccelerationStructure=" << to_string(desc->pAccelerationStructure); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_instance_geometry_info_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_build_op_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", rtasFormat=" << to_string(&desc->rtasFormat); + oss << ", buildQuality=" << to_string(desc->buildQuality); + oss << ", buildFlags=" << to_string(&desc->buildFlags); + oss << ", ppGeometries=" << to_string(desc->ppGeometries); + oss << ", numGeometries=" << to_string(desc->numGeometries); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_build_op_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_vector_width_properties_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", vector_width_size=" << to_string(desc->vector_width_size); + oss << ", preferred_vector_width_char=" << to_string(desc->preferred_vector_width_char); + oss << ", preferred_vector_width_short=" << to_string(desc->preferred_vector_width_short); + oss << ", preferred_vector_width_int=" << to_string(desc->preferred_vector_width_int); + oss << ", preferred_vector_width_long=" << to_string(desc->preferred_vector_width_long); + oss << ", preferred_vector_width_float=" << to_string(desc->preferred_vector_width_float); + oss << ", preferred_vector_width_double=" << to_string(desc->preferred_vector_width_double); + oss << ", preferred_vector_width_half=" << to_string(desc->preferred_vector_width_half); + oss << ", native_vector_width_char=" << to_string(desc->native_vector_width_char); + oss << ", native_vector_width_short=" << to_string(desc->native_vector_width_short); + oss << ", native_vector_width_int=" << to_string(desc->native_vector_width_int); + oss << ", native_vector_width_long=" << to_string(desc->native_vector_width_long); + oss << ", native_vector_width_float=" << to_string(desc->native_vector_width_float); + oss << ", native_vector_width_double=" << to_string(desc->native_vector_width_double); + oss << ", native_vector_width_half=" << to_string(desc->native_vector_width_half); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_vector_width_properties_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_external_memmap_sysmem_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", pSystemMemory=" << to_string(desc->pSystemMemory); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_external_memmap_sysmem_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_allocation_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", base=" << to_string(desc->base); + oss << ", size=" << to_string(desc->size); + oss << ", type=" << to_string(&desc->type); + oss << ", argIndex=" << to_string(desc->argIndex); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_allocation_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_cache_reservation_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", maxCacheReservationSize=" << to_string(desc->maxCacheReservationSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_cache_reservation_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_memory_properties_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", size=" << to_string(desc->size); + oss << ", rowPitch=" << to_string(desc->rowPitch); + oss << ", slicePitch=" << to_string(desc->slicePitch); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_memory_properties_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_view_planar_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", planeIndex=" << to_string(desc->planeIndex); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_view_planar_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_view_planar_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", planeIndex=" << to_string(desc->planeIndex); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_view_planar_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_scheduling_hint_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", schedulingHintFlags=" << to_string(desc->schedulingHintFlags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_scheduling_hint_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_scheduling_hint_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_scheduling_hint_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_context_power_saving_hint_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", hint=" << to_string(desc->hint); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_context_power_saving_hint_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_eu_count_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", numTotalEUs=" << to_string(desc->numTotalEUs); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_eu_count_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_pci_address_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "domain=" << to_string(desc->domain); + oss << ", bus=" << to_string(desc->bus); + oss << ", device=" << to_string(desc->device); + oss << ", function=" << to_string(desc->function); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_pci_address_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_pci_speed_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "genVersion=" << to_string(desc->genVersion); + oss << ", width=" << to_string(desc->width); + oss << ", maxBandwidth=" << to_string(desc->maxBandwidth); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_pci_speed_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_pci_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", address=" << to_string(&desc->address); + oss << ", maxSpeed=" << to_string(&desc->maxSpeed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_pci_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_srgb_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", sRGB=" << to_string(&desc->sRGB); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_srgb_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_allocation_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_allocation_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_linkage_inspection_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_linkage_inspection_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_memory_compression_hints_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_memory_compression_hints_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_driver_memory_free_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", freePolicies=" << to_string(&desc->freePolicies); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_driver_memory_free_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_memory_free_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", freePolicy=" << to_string(&desc->freePolicy); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_memory_free_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_p2p_bandwidth_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", logicalBandwidth=" << to_string(desc->logicalBandwidth); + oss << ", physicalBandwidth=" << to_string(desc->physicalBandwidth); + oss << ", bandwidthUnit=" << to_string(&desc->bandwidthUnit); + oss << ", logicalLatency=" << to_string(desc->logicalLatency); + oss << ", physicalLatency=" << to_string(desc->physicalLatency); + oss << ", latencyUnit=" << to_string(&desc->latencyUnit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_p2p_bandwidth_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_copy_bandwidth_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", copyBandwidth=" << to_string(desc->copyBandwidth); + oss << ", copyBandwidthUnit=" << to_string(&desc->copyBandwidthUnit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_copy_bandwidth_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_luid_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_luid_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_luid_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", luid=" << to_string(&desc->luid); + oss << ", nodeMask=" << to_string(desc->nodeMask); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_luid_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_fabric_vertex_pci_exp_address_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "domain=" << to_string(desc->domain); + oss << ", bus=" << to_string(desc->bus); + oss << ", device=" << to_string(desc->device); + oss << ", function=" << to_string(desc->function); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_fabric_vertex_pci_exp_address_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_fabric_vertex_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", type=" << to_string(&desc->type); + oss << ", remote=" << to_string(&desc->remote); + oss << ", address=" << to_string(&desc->address); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_fabric_vertex_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_fabric_edge_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", model=" << to_string(desc->model); + oss << ", bandwidth=" << to_string(desc->bandwidth); + oss << ", bandwidthUnit=" << to_string(&desc->bandwidthUnit); + oss << ", latency=" << to_string(desc->latency); + oss << ", latencyUnit=" << to_string(&desc->latencyUnit); + oss << ", duplexity=" << to_string(&desc->duplexity); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_fabric_edge_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_memory_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", physicalSize=" << to_string(desc->physicalSize); + oss << ", readBandwidth=" << to_string(desc->readBandwidth); + oss << ", writeBandwidth=" << to_string(desc->writeBandwidth); + oss << ", bandwidthUnit=" << to_string(&desc->bandwidthUnit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_memory_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_ip_version_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", ipVersion=" << to_string(desc->ipVersion); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_ip_version_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_kernel_max_group_size_properties_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", maxGroupSize=" << to_string(desc->maxGroupSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_kernel_max_group_size_properties_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_sub_allocation_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "base=" << to_string(desc->base); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_sub_allocation_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_memory_sub_allocations_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", pCount=" << to_string(desc->pCount); + oss << ", pSubAllocations=" << to_string(desc->pSubAllocations); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_memory_sub_allocations_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_event_query_kernel_timestamps_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_event_query_kernel_timestamps_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_synchronized_timestamp_data_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "kernelStart=" << to_string(desc->kernelStart); + oss << ", kernelEnd=" << to_string(desc->kernelEnd); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_synchronized_timestamp_data_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_synchronized_timestamp_result_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "global=" << to_string(&desc->global); + oss << ", context=" << to_string(&desc->context); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_synchronized_timestamp_result_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_event_query_kernel_timestamps_results_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", pKernelTimestampsBuffer=" << to_string(desc->pKernelTimestampsBuffer); + oss << ", pSynchronizedTimestampsBuffer=" << to_string(desc->pSynchronizedTimestampsBuffer); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_event_query_kernel_timestamps_results_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", builderVersion=" << to_string(&desc->builderVersion); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", rtasBufferSizeBytesExpected=" << to_string(desc->rtasBufferSizeBytesExpected); + oss << ", rtasBufferSizeBytesMaxRequired=" << to_string(desc->rtasBufferSizeBytesMaxRequired); + oss << ", scratchBufferSizeBytes=" << to_string(desc->scratchBufferSizeBytes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_parallel_operation_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", maxConcurrency=" << to_string(desc->maxConcurrency); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_parallel_operation_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_device_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", rtasFormat=" << to_string(&desc->rtasFormat); + oss << ", rtasBufferAlignment=" << to_string(desc->rtasBufferAlignment); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_device_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_float3_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "x=" << to_string(desc->x); + oss << ", y=" << to_string(desc->y); + oss << ", z=" << to_string(desc->z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_float3_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_column_major_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", p_z=" << to_string(desc->p_z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_column_major_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_aligned_column_major_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", pad0=" << to_string(desc->pad0); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", pad1=" << to_string(desc->pad1); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", pad2=" << to_string(desc->pad2); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", p_z=" << to_string(desc->p_z); + oss << ", pad3=" << to_string(desc->pad3); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_aligned_column_major_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_row_major_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "vx_x=" << to_string(desc->vx_x); + oss << ", vy_x=" << to_string(desc->vy_x); + oss << ", vz_x=" << to_string(desc->vz_x); + oss << ", p_x=" << to_string(desc->p_x); + oss << ", vx_y=" << to_string(desc->vx_y); + oss << ", vy_y=" << to_string(desc->vy_y); + oss << ", vz_y=" << to_string(desc->vz_y); + oss << ", p_y=" << to_string(desc->p_y); + oss << ", vx_z=" << to_string(desc->vx_z); + oss << ", vy_z=" << to_string(desc->vy_z); + oss << ", vz_z=" << to_string(desc->vz_z); + oss << ", p_z=" << to_string(desc->p_z); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_transform_float3x4_row_major_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_aabb_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "lower=" << to_string(&desc->lower); + oss << ", upper=" << to_string(&desc->upper); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_aabb_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_triangle_indices_uint32_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "v0=" << to_string(desc->v0); + oss << ", v1=" << to_string(desc->v1); + oss << ", v2=" << to_string(desc->v2); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_triangle_indices_uint32_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_quad_indices_uint32_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "v0=" << to_string(desc->v0); + oss << ", v1=" << to_string(desc->v1); + oss << ", v2=" << to_string(desc->v2); + oss << ", v3=" << to_string(desc->v3); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_quad_indices_uint32_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_geometry_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_geometry_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_triangles_geometry_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", triangleFormat=" << to_string(&desc->triangleFormat); + oss << ", vertexFormat=" << to_string(&desc->vertexFormat); + oss << ", triangleCount=" << to_string(desc->triangleCount); + oss << ", vertexCount=" << to_string(desc->vertexCount); + oss << ", triangleStride=" << to_string(desc->triangleStride); + oss << ", vertexStride=" << to_string(desc->vertexStride); + oss << ", pTriangleBuffer=" << to_string(desc->pTriangleBuffer); + oss << ", pVertexBuffer=" << to_string(desc->pVertexBuffer); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_triangles_geometry_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_quads_geometry_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", quadFormat=" << to_string(&desc->quadFormat); + oss << ", vertexFormat=" << to_string(&desc->vertexFormat); + oss << ", quadCount=" << to_string(desc->quadCount); + oss << ", vertexCount=" << to_string(desc->vertexCount); + oss << ", quadStride=" << to_string(desc->quadStride); + oss << ", vertexStride=" << to_string(desc->vertexStride); + oss << ", pQuadBuffer=" << to_string(desc->pQuadBuffer); + oss << ", pVertexBuffer=" << to_string(desc->pVertexBuffer); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_quads_geometry_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_geometry_aabbs_exp_cb_params_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", primID=" << to_string(desc->primID); + oss << ", primIDCount=" << to_string(desc->primIDCount); + oss << ", pGeomUserPtr=" << to_string(desc->pGeomUserPtr); + oss << ", pBuildUserPtr=" << to_string(desc->pBuildUserPtr); + oss << ", pBoundsOut=" << to_string(desc->pBoundsOut); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_geometry_aabbs_exp_cb_params_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_procedural_geometry_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", geometryFlags=" << to_string(&desc->geometryFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", reserved=" << to_string(desc->reserved); + oss << ", primCount=" << to_string(desc->primCount); + oss << ", pfnGetBoundsCb=" << to_string(&desc->pfnGetBoundsCb); + oss << ", pGeomUserPtr=" << to_string(desc->pGeomUserPtr); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_procedural_geometry_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_instance_geometry_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "geometryType=" << to_string(&desc->geometryType); + oss << ", instanceFlags=" << to_string(&desc->instanceFlags); + oss << ", geometryMask=" << to_string(desc->geometryMask); + oss << ", transformFormat=" << to_string(&desc->transformFormat); + oss << ", instanceUserID=" << to_string(desc->instanceUserID); + oss << ", pTransform=" << to_string(desc->pTransform); + oss << ", pBounds=" << to_string(desc->pBounds); + oss << ", pAccelerationStructure=" << to_string(desc->pAccelerationStructure); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_instance_geometry_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_rtas_builder_build_op_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", rtasFormat=" << to_string(&desc->rtasFormat); + oss << ", buildQuality=" << to_string(desc->buildQuality); + oss << ", buildFlags=" << to_string(&desc->buildFlags); + oss << ", ppGeometries=" << to_string(desc->ppGeometries); + oss << ", numGeometries=" << to_string(desc->numGeometries); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_rtas_builder_build_op_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_event_pool_counter_based_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_event_pool_counter_based_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_bindless_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_bindless_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_image_pitched_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", ptr=" << to_string(desc->ptr); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_image_pitched_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_device_pitched_alloc_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", maxImageLinearWidth=" << to_string(desc->maxImageLinearWidth); + oss << ", maxImageLinearHeight=" << to_string(desc->maxImageLinearHeight); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_device_pitched_alloc_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_pitched_alloc_2dimage_linear_pitch_exp_info_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", pitchAlign=" << to_string(desc->pitchAlign); + oss << ", maxSupportedPitch=" << to_string(desc->maxSupportedPitch); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_pitched_alloc_2dimage_linear_pitch_exp_info_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_command_id_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_command_id_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_command_list_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", mutableCommandListFlags=" << to_string(&desc->mutableCommandListFlags); + oss << ", mutableCommandFlags=" << to_string(&desc->mutableCommandFlags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_command_list_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_command_list_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_command_list_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_commands_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_commands_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_kernel_argument_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandId=" << to_string(desc->commandId); + oss << ", argIndex=" << to_string(desc->argIndex); + oss << ", argSize=" << to_string(desc->argSize); + oss << ", pArgValue=" << to_string(desc->pArgValue); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_kernel_argument_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_group_count_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandId=" << to_string(desc->commandId); + oss << ", pGroupCount=" << to_string(desc->pGroupCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_group_count_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_group_size_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandId=" << to_string(desc->commandId); + oss << ", groupSizeX=" << to_string(desc->groupSizeX); + oss << ", groupSizeY=" << to_string(desc->groupSizeY); + oss << ", groupSizeZ=" << to_string(desc->groupSizeZ); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_group_size_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_global_offset_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandId=" << to_string(desc->commandId); + oss << ", offsetX=" << to_string(desc->offsetX); + oss << ", offsetY=" << to_string(desc->offsetY); + oss << ", offsetZ=" << to_string(desc->offsetZ); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_global_offset_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const ze_mutable_graph_argument_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", commandId=" << to_string(desc->commandId); + oss << ", argIndex=" << to_string(desc->argIndex); + oss << ", pArgValue=" << to_string(desc->pArgValue); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const ze_mutable_graph_argument_exp_desc_t& desc) { + return to_string(&desc); +} + +} // namespace loader + +#endif // _ZE_TO_STRING_H diff --git a/source/utils/zer_to_string.h b/source/utils/zer_to_string.h new file mode 100644 index 00000000..f4aac7d1 --- /dev/null +++ b/source/utils/zer_to_string.h @@ -0,0 +1,29 @@ +/* + * ***THIS FILE IS GENERATED. *** + * See to_string.h.mako for modifications + * + * Copyright (C) 2025 Intel Corporation + * + * SPDX-License-Identifier: MIT + * + * @file zer_to_string.h + * + * to_string functions for Level Zero types + */ + +#ifndef _ZER_TO_STRING_H +#define _ZER_TO_STRING_H + +#include "ze_api.h" +#include +#include +#include + +// Include ze_to_string.h for common definitions +#include "ze_to_string.h" + +namespace loader { +// Struct to_string functions +} // namespace loader + +#endif // _ZER_TO_STRING_H diff --git a/source/utils/zes_to_string.h b/source/utils/zes_to_string.h new file mode 100644 index 00000000..0a1bea89 --- /dev/null +++ b/source/utils/zes_to_string.h @@ -0,0 +1,1447 @@ +/* + * ***THIS FILE IS GENERATED. *** + * See to_string.h.mako for modifications + * + * Copyright (C) 2025 Intel Corporation + * + * SPDX-License-Identifier: MIT + * + * @file zes_to_string.h + * + * to_string functions for Level Zero types + */ + +#ifndef _ZES_TO_STRING_H +#define _ZES_TO_STRING_H + +#include "ze_api.h" +#include +#include +#include + +// Include ze_to_string.h for common definitions +#include "ze_to_string.h" + +namespace loader { +// Struct to_string functions +inline std::string to_string(const zes_base_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_base_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_base_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_base_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_base_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_base_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_base_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_base_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_base_capability_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_base_capability_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_driver_extension_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "name=" << to_string(desc->name); + oss << ", version=" << to_string(desc->version); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_driver_extension_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", reset=" << to_string(&desc->reset); + oss << ", repaired=" << to_string(&desc->repaired); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_reset_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", force=" << to_string(&desc->force); + oss << ", resetType=" << to_string(&desc->resetType); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_reset_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_uuid_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "id=" << to_string(desc->id); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_uuid_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", core=" << to_string(&desc->core); + oss << ", numSubdevices=" << to_string(desc->numSubdevices); + oss << ", serialNumber=" << to_string(desc->serialNumber); + oss << ", boardNumber=" << to_string(desc->boardNumber); + oss << ", brandName=" << to_string(desc->brandName); + oss << ", modelName=" << to_string(desc->modelName); + oss << ", vendorName=" << to_string(desc->vendorName); + oss << ", driverVersion=" << to_string(desc->driverVersion); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", type=" << to_string(&desc->type); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_process_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", processId=" << to_string(desc->processId); + oss << ", memSize=" << to_string(desc->memSize); + oss << ", sharedSize=" << to_string(desc->sharedSize); + oss << ", engines=" << to_string(&desc->engines); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_process_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_address_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "domain=" << to_string(desc->domain); + oss << ", bus=" << to_string(desc->bus); + oss << ", device=" << to_string(desc->device); + oss << ", function=" << to_string(desc->function); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_address_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_speed_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "gen=" << to_string(desc->gen); + oss << ", width=" << to_string(desc->width); + oss << ", maxBandwidth=" << to_string(desc->maxBandwidth); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_speed_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", address=" << to_string(&desc->address); + oss << ", maxSpeed=" << to_string(&desc->maxSpeed); + oss << ", haveBandwidthCounters=" << to_string(&desc->haveBandwidthCounters); + oss << ", havePacketCounters=" << to_string(&desc->havePacketCounters); + oss << ", haveReplayCounters=" << to_string(&desc->haveReplayCounters); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", status=" << to_string(&desc->status); + oss << ", qualityIssues=" << to_string(&desc->qualityIssues); + oss << ", stabilityIssues=" << to_string(&desc->stabilityIssues); + oss << ", speed=" << to_string(&desc->speed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_bar_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", index=" << to_string(desc->index); + oss << ", base=" << to_string(desc->base); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_bar_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_bar_properties_1_2_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", index=" << to_string(desc->index); + oss << ", base=" << to_string(desc->base); + oss << ", size=" << to_string(desc->size); + oss << ", resizableBarSupported=" << to_string(&desc->resizableBarSupported); + oss << ", resizableBarEnabled=" << to_string(&desc->resizableBarEnabled); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_bar_properties_1_2_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_pci_stats_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "timestamp=" << to_string(desc->timestamp); + oss << ", replayCounter=" << to_string(desc->replayCounter); + oss << ", packetCounter=" << to_string(desc->packetCounter); + oss << ", rxCounter=" << to_string(desc->rxCounter); + oss << ", txCounter=" << to_string(desc->txCounter); + oss << ", speed=" << to_string(&desc->speed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_pci_stats_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_overclock_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", domainType=" << to_string(&desc->domainType); + oss << ", AvailableControls=" << to_string(desc->AvailableControls); + oss << ", VFProgramType=" << to_string(&desc->VFProgramType); + oss << ", NumberOfVFPoints=" << to_string(desc->NumberOfVFPoints); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_overclock_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_control_property_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "MinValue=" << to_string(desc->MinValue); + oss << ", MaxValue=" << to_string(desc->MaxValue); + oss << ", StepValue=" << to_string(desc->StepValue); + oss << ", RefValue=" << to_string(desc->RefValue); + oss << ", DefaultValue=" << to_string(desc->DefaultValue); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_control_property_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_property_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "MinFreq=" << to_string(desc->MinFreq); + oss << ", MaxFreq=" << to_string(desc->MaxFreq); + oss << ", StepFreq=" << to_string(desc->StepFreq); + oss << ", MinVolt=" << to_string(desc->MinVolt); + oss << ", MaxVolt=" << to_string(desc->MaxVolt); + oss << ", StepVolt=" << to_string(desc->StepVolt); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_property_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_diag_test_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "index=" << to_string(desc->index); + oss << ", name=" << to_string(desc->name); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_diag_test_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_diag_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", name=" << to_string(desc->name); + oss << ", haveTests=" << to_string(&desc->haveTests); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_diag_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_ecc_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", state=" << to_string(&desc->state); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_ecc_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_ecc_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", currentState=" << to_string(&desc->currentState); + oss << ", pendingState=" << to_string(&desc->pendingState); + oss << ", pendingAction=" << to_string(&desc->pendingAction); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_ecc_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_engine_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_engine_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_engine_stats_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "activeTime=" << to_string(desc->activeTime); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_engine_stats_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_id_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "fabricId=" << to_string(desc->fabricId); + oss << ", attachId=" << to_string(desc->attachId); + oss << ", portNumber=" << to_string(desc->portNumber); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_id_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_speed_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "bitRate=" << to_string(desc->bitRate); + oss << ", width=" << to_string(desc->width); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_speed_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", model=" << to_string(desc->model); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", portId=" << to_string(&desc->portId); + oss << ", maxRxSpeed=" << to_string(&desc->maxRxSpeed); + oss << ", maxTxSpeed=" << to_string(&desc->maxTxSpeed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_link_type_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "desc=" << to_string(desc->desc); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_link_type_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", enabled=" << to_string(&desc->enabled); + oss << ", beaconing=" << to_string(&desc->beaconing); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", status=" << to_string(&desc->status); + oss << ", qualityIssues=" << to_string(&desc->qualityIssues); + oss << ", failureReasons=" << to_string(&desc->failureReasons); + oss << ", remotePortId=" << to_string(&desc->remotePortId); + oss << ", rxSpeed=" << to_string(&desc->rxSpeed); + oss << ", txSpeed=" << to_string(&desc->txSpeed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_throughput_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "timestamp=" << to_string(desc->timestamp); + oss << ", rxCounter=" << to_string(desc->rxCounter); + oss << ", txCounter=" << to_string(desc->txCounter); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_throughput_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fabric_port_error_counters_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", linkFailureCount=" << to_string(desc->linkFailureCount); + oss << ", fwCommErrorCount=" << to_string(desc->fwCommErrorCount); + oss << ", fwErrorCount=" << to_string(desc->fwErrorCount); + oss << ", linkDegradeCount=" << to_string(desc->linkDegradeCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fabric_port_error_counters_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fan_speed_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "speed=" << to_string(desc->speed); + oss << ", units=" << to_string(&desc->units); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fan_speed_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fan_temp_speed_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "temperature=" << to_string(desc->temperature); + oss << ", speed=" << to_string(&desc->speed); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fan_temp_speed_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fan_speed_table_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "numPoints=" << to_string(desc->numPoints); + oss << ", table=" << to_string(desc->table); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fan_speed_table_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fan_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", supportedModes=" << to_string(desc->supportedModes); + oss << ", supportedUnits=" << to_string(desc->supportedUnits); + oss << ", maxRPM=" << to_string(desc->maxRPM); + oss << ", maxPoints=" << to_string(desc->maxPoints); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fan_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_fan_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", mode=" << to_string(&desc->mode); + oss << ", speedFixed=" << to_string(&desc->speedFixed); + oss << ", speedTable=" << to_string(&desc->speedTable); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_fan_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_firmware_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", name=" << to_string(desc->name); + oss << ", version=" << to_string(desc->version); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_firmware_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_freq_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", isThrottleEventSupported=" << to_string(&desc->isThrottleEventSupported); + oss << ", min=" << to_string(desc->min); + oss << ", max=" << to_string(desc->max); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_freq_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_freq_range_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "min=" << to_string(desc->min); + oss << ", max=" << to_string(desc->max); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_freq_range_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_freq_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", currentVoltage=" << to_string(desc->currentVoltage); + oss << ", request=" << to_string(desc->request); + oss << ", tdp=" << to_string(desc->tdp); + oss << ", efficient=" << to_string(desc->efficient); + oss << ", actual=" << to_string(desc->actual); + oss << ", throttleReasons=" << to_string(&desc->throttleReasons); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_freq_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_freq_throttle_time_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "throttleTime=" << to_string(desc->throttleTime); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_freq_throttle_time_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_oc_capabilities_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", isOcSupported=" << to_string(&desc->isOcSupported); + oss << ", maxFactoryDefaultFrequency=" << to_string(desc->maxFactoryDefaultFrequency); + oss << ", maxFactoryDefaultVoltage=" << to_string(desc->maxFactoryDefaultVoltage); + oss << ", maxOcFrequency=" << to_string(desc->maxOcFrequency); + oss << ", minOcVoltageOffset=" << to_string(desc->minOcVoltageOffset); + oss << ", maxOcVoltageOffset=" << to_string(desc->maxOcVoltageOffset); + oss << ", maxOcVoltage=" << to_string(desc->maxOcVoltage); + oss << ", isTjMaxSupported=" << to_string(&desc->isTjMaxSupported); + oss << ", isIccMaxSupported=" << to_string(&desc->isIccMaxSupported); + oss << ", isHighVoltModeCapable=" << to_string(&desc->isHighVoltModeCapable); + oss << ", isHighVoltModeEnabled=" << to_string(&desc->isHighVoltModeEnabled); + oss << ", isExtendedModeSupported=" << to_string(&desc->isExtendedModeSupported); + oss << ", isFixedModeSupported=" << to_string(&desc->isFixedModeSupported); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_oc_capabilities_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_led_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", haveRGB=" << to_string(&desc->haveRGB); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_led_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_led_color_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "red=" << to_string(desc->red); + oss << ", green=" << to_string(desc->green); + oss << ", blue=" << to_string(desc->blue); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_led_color_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_led_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", isOn=" << to_string(&desc->isOn); + oss << ", color=" << to_string(&desc->color); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_led_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", location=" << to_string(&desc->location); + oss << ", physicalSize=" << to_string(desc->physicalSize); + oss << ", busWidth=" << to_string(desc->busWidth); + oss << ", numChannels=" << to_string(desc->numChannels); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", health=" << to_string(&desc->health); + oss << ", free=" << to_string(desc->free); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_bandwidth_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "readCounter=" << to_string(desc->readCounter); + oss << ", writeCounter=" << to_string(desc->writeCounter); + oss << ", maxBandwidth=" << to_string(desc->maxBandwidth); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_bandwidth_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_ext_bandwidth_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "memoryTimestampValidBits=" << to_string(desc->memoryTimestampValidBits); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_ext_bandwidth_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_perf_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", engines=" << to_string(&desc->engines); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_perf_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", isEnergyThresholdSupported=" << to_string(&desc->isEnergyThresholdSupported); + oss << ", defaultLimit=" << to_string(desc->defaultLimit); + oss << ", minLimit=" << to_string(desc->minLimit); + oss << ", maxLimit=" << to_string(desc->maxLimit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_energy_counter_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "energy=" << to_string(desc->energy); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_energy_counter_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_sustained_limit_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "enabled=" << to_string(&desc->enabled); + oss << ", power=" << to_string(desc->power); + oss << ", interval=" << to_string(desc->interval); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_sustained_limit_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_burst_limit_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "enabled=" << to_string(&desc->enabled); + oss << ", power=" << to_string(desc->power); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_burst_limit_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_peak_limit_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "powerAC=" << to_string(desc->powerAC); + oss << ", powerDC=" << to_string(desc->powerDC); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_peak_limit_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_energy_threshold_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "enable=" << to_string(&desc->enable); + oss << ", threshold=" << to_string(desc->threshold); + oss << ", processId=" << to_string(desc->processId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_energy_threshold_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_psu_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", haveFan=" << to_string(&desc->haveFan); + oss << ", ampLimit=" << to_string(desc->ampLimit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_psu_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_psu_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", voltStatus=" << to_string(&desc->voltStatus); + oss << ", fanFailed=" << to_string(&desc->fanFailed); + oss << ", temperature=" << to_string(desc->temperature); + oss << ", current=" << to_string(desc->current); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_psu_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_ras_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_ras_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_ras_state_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", category=" << to_string(desc->category); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_ras_state_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_ras_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", totalThreshold=" << to_string(desc->totalThreshold); + oss << ", detailedThresholds=" << to_string(&desc->detailedThresholds); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_ras_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_sched_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", canControl=" << to_string(&desc->canControl); + oss << ", engines=" << to_string(&desc->engines); + oss << ", supportedModes=" << to_string(desc->supportedModes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_sched_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_sched_timeout_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", watchdogTimeout=" << to_string(desc->watchdogTimeout); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_sched_timeout_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_sched_timeslice_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", interval=" << to_string(desc->interval); + oss << ", yieldTimeout=" << to_string(desc->yieldTimeout); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_sched_timeslice_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_standby_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_standby_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_temp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", maxTemperature=" << to_string(desc->maxTemperature); + oss << ", isCriticalTempSupported=" << to_string(&desc->isCriticalTempSupported); + oss << ", isThreshold1Supported=" << to_string(&desc->isThreshold1Supported); + oss << ", isThreshold2Supported=" << to_string(&desc->isThreshold2Supported); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_temp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_temp_threshold_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "enableLowToHigh=" << to_string(&desc->enableLowToHigh); + oss << ", enableHighToLow=" << to_string(&desc->enableHighToLow); + oss << ", threshold=" << to_string(desc->threshold); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_temp_threshold_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_temp_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", enableCritical=" << to_string(&desc->enableCritical); + oss << ", threshold1=" << to_string(&desc->threshold1); + oss << ", threshold2=" << to_string(&desc->threshold2); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_temp_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_device_ecc_default_properties_ext_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", defaultState=" << to_string(&desc->defaultState); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_device_ecc_default_properties_ext_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_limit_ext_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", level=" << to_string(&desc->level); + oss << ", source=" << to_string(&desc->source); + oss << ", limitUnit=" << to_string(&desc->limitUnit); + oss << ", enabledStateLocked=" << to_string(&desc->enabledStateLocked); + oss << ", enabled=" << to_string(&desc->enabled); + oss << ", intervalValueLocked=" << to_string(&desc->intervalValueLocked); + oss << ", interval=" << to_string(desc->interval); + oss << ", limitValueLocked=" << to_string(&desc->limitValueLocked); + oss << ", limit=" << to_string(desc->limit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_limit_ext_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", domain=" << to_string(&desc->domain); + oss << ", defaultLimit=" << to_string(desc->defaultLimit); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_engine_ext_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", countOfVirtualFunctionInstance=" << to_string(desc->countOfVirtualFunctionInstance); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_engine_ext_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_ras_state_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "category=" << to_string(&desc->category); + oss << ", errorCounter=" << to_string(desc->errorCounter); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_ras_state_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_page_offline_state_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", memoryPageOffline=" << to_string(desc->memoryPageOffline); + oss << ", maxMemoryPageOffline=" << to_string(desc->maxMemoryPageOffline); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_page_offline_state_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_mem_bandwidth_counter_bits_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", validBitsCount=" << to_string(desc->validBitsCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_mem_bandwidth_counter_bits_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_power_domain_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", powerDomain=" << to_string(&desc->powerDomain); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_power_domain_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_subdevice_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << ", uuid=" << to_string(&desc->uuid); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_subdevice_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", address=" << to_string(&desc->address); + oss << ", uuid=" << to_string(&desc->uuid); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_util_mem_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", memTypeFlags=" << to_string(&desc->memTypeFlags); + oss << ", free=" << to_string(desc->free); + oss << ", size=" << to_string(desc->size); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_util_mem_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_util_engine_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", activeCounterValue=" << to_string(desc->activeCounterValue); + oss << ", samplingCounterValue=" << to_string(desc->samplingCounterValue); + oss << ", timestamp=" << to_string(desc->timestamp); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_util_engine_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_exp_capabilities_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", address=" << to_string(&desc->address); + oss << ", vfDeviceMemSize=" << to_string(desc->vfDeviceMemSize); + oss << ", vfID=" << to_string(desc->vfID); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_exp_capabilities_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_exp2_capabilities_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", address=" << to_string(&desc->address); + oss << ", vfDeviceMemSize=" << to_string(desc->vfDeviceMemSize); + oss << ", vfID=" << to_string(desc->vfID); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_exp2_capabilities_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_util_mem_exp2_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", vfMemLocation=" << to_string(&desc->vfMemLocation); + oss << ", vfMemUtilized=" << to_string(desc->vfMemUtilized); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_util_mem_exp2_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zes_vf_util_engine_exp2_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", vfEngineType=" << to_string(&desc->vfEngineType); + oss << ", activeCounterValue=" << to_string(desc->activeCounterValue); + oss << ", samplingCounterValue=" << to_string(desc->samplingCounterValue); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zes_vf_util_engine_exp2_t& desc) { + return to_string(&desc); +} + +} // namespace loader + +#endif // _ZES_TO_STRING_H diff --git a/source/utils/zet_to_string.h b/source/utils/zet_to_string.h new file mode 100644 index 00000000..469239e7 --- /dev/null +++ b/source/utils/zet_to_string.h @@ -0,0 +1,527 @@ +/* + * ***THIS FILE IS GENERATED. *** + * See to_string.h.mako for modifications + * + * Copyright (C) 2025 Intel Corporation + * + * SPDX-License-Identifier: MIT + * + * @file zet_to_string.h + * + * to_string functions for Level Zero types + */ + +#ifndef _ZET_TO_STRING_H +#define _ZET_TO_STRING_H + +#include "ze_api.h" +#include +#include +#include + +// Include ze_to_string.h for common definitions +#include "ze_to_string.h" + +namespace loader { +// Struct to_string functions +inline std::string to_string(const zet_base_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_base_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_base_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_base_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_typed_value_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "type=" << to_string(&desc->type); + oss << ", value=" << to_string(&desc->value); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_typed_value_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_device_debug_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_device_debug_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_config_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "pid=" << to_string(desc->pid); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_config_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_event_info_detached_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "reason=" << to_string(&desc->reason); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_event_info_detached_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_event_info_module_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "format=" << to_string(&desc->format); + oss << ", moduleBegin=" << to_string(desc->moduleBegin); + oss << ", moduleEnd=" << to_string(desc->moduleEnd); + oss << ", load=" << to_string(desc->load); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_event_info_module_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_event_info_thread_stopped_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "thread=" << to_string(&desc->thread); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_event_info_thread_stopped_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_event_info_page_fault_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "address=" << to_string(desc->address); + oss << ", mask=" << to_string(desc->mask); + oss << ", reason=" << to_string(&desc->reason); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_event_info_page_fault_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_event_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "type=" << to_string(&desc->type); + oss << ", flags=" << to_string(&desc->flags); + oss << ", info=" << to_string(&desc->info); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_event_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_memory_space_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", address=" << to_string(desc->address); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_memory_space_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_debug_regset_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(desc->type); + oss << ", version=" << to_string(desc->version); + oss << ", generalFlags=" << to_string(&desc->generalFlags); + oss << ", deviceFlags=" << to_string(desc->deviceFlags); + oss << ", count=" << to_string(desc->count); + oss << ", bitSize=" << to_string(desc->bitSize); + oss << ", byteSize=" << to_string(desc->byteSize); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_debug_regset_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_group_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", name=" << to_string(desc->name); + oss << ", description=" << to_string(desc->description); + oss << ", samplingType=" << to_string(&desc->samplingType); + oss << ", domain=" << to_string(desc->domain); + oss << ", metricCount=" << to_string(desc->metricCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_group_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", name=" << to_string(desc->name); + oss << ", description=" << to_string(desc->description); + oss << ", component=" << to_string(desc->component); + oss << ", tierNumber=" << to_string(desc->tierNumber); + oss << ", metricType=" << to_string(&desc->metricType); + oss << ", resultType=" << to_string(&desc->resultType); + oss << ", resultUnits=" << to_string(desc->resultUnits); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_streamer_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", notifyEveryNReports=" << to_string(desc->notifyEveryNReports); + oss << ", samplingPeriod=" << to_string(desc->samplingPeriod); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_streamer_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_query_pool_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", count=" << to_string(desc->count); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_query_pool_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_profile_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", flags=" << to_string(&desc->flags); + oss << ", numTokens=" << to_string(desc->numTokens); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_profile_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_profile_free_register_token_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "type=" << to_string(&desc->type); + oss << ", size=" << to_string(desc->size); + oss << ", count=" << to_string(desc->count); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_profile_free_register_token_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_profile_register_sequence_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "start=" << to_string(desc->start); + oss << ", count=" << to_string(desc->count); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_profile_register_sequence_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_tracer_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", pUserData=" << to_string(desc->pUserData); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_tracer_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_tracer_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", notifyEveryNBytes=" << to_string(desc->notifyEveryNBytes); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_tracer_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_entry_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "value=" << to_string(&desc->value); + oss << ", timeStamp=" << to_string(desc->timeStamp); + oss << ", metricIndex=" << to_string(desc->metricIndex); + oss << ", onSubdevice=" << to_string(&desc->onSubdevice); + oss << ", subdeviceId=" << to_string(desc->subdeviceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_entry_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_group_type_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_group_type_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_export_dma_buf_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", fd=" << to_string(desc->fd); + oss << ", size=" << to_string(desc->size); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_export_dma_buf_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_source_id_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", sourceId=" << to_string(desc->sourceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_source_id_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_global_timestamps_resolution_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", timerResolution=" << to_string(desc->timerResolution); + oss << ", timestampValidBits=" << to_string(desc->timestampValidBits); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_global_timestamps_resolution_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_calculate_exp_desc_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", rawReportSkipCount=" << to_string(desc->rawReportSkipCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_calculate_exp_desc_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_programmable_exp_properties_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", name=" << to_string(desc->name); + oss << ", description=" << to_string(desc->description); + oss << ", component=" << to_string(desc->component); + oss << ", tierNumber=" << to_string(desc->tierNumber); + oss << ", domain=" << to_string(desc->domain); + oss << ", parameterCount=" << to_string(desc->parameterCount); + oss << ", samplingType=" << to_string(&desc->samplingType); + oss << ", sourceId=" << to_string(desc->sourceId); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_programmable_exp_properties_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_value_uint64_range_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "ui64Min=" << to_string(desc->ui64Min); + oss << ", ui64Max=" << to_string(desc->ui64Max); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_value_uint64_range_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_value_fp64_range_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "fp64Min=" << to_string(desc->fp64Min); + oss << ", fp64Max=" << to_string(desc->fp64Max); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_value_fp64_range_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_programmable_param_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", type=" << to_string(&desc->type); + oss << ", name=" << to_string(desc->name); + oss << ", valueInfoType=" << to_string(&desc->valueInfoType); + oss << ", defaultValue=" << to_string(&desc->defaultValue); + oss << ", valueInfoCount=" << to_string(desc->valueInfoCount); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_programmable_param_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_programmable_param_value_info_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "stype=" << to_string(&desc->stype); + oss << ", valueInfo=" << to_string(&desc->valueInfo); + oss << ", description=" << to_string(desc->description); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_programmable_param_value_info_exp_t& desc) { + return to_string(&desc); +} + +inline std::string to_string(const zet_metric_programmable_param_value_exp_t* desc) { + if (!desc) return "nullptr"; + std::ostringstream oss; + oss << "{"; + oss << "value=" << to_string(&desc->value); + oss << "}"; + return oss.str(); +} + +inline std::string to_string(const zet_metric_programmable_param_value_exp_t& desc) { + return to_string(&desc); +} + +} // namespace loader + +#endif // _ZET_TO_STRING_H