diff --git a/src/core/verify.cpp b/src/core/verify.cpp index bb108338..0513a824 100644 --- a/src/core/verify.cpp +++ b/src/core/verify.cpp @@ -6,6 +6,10 @@ #include "strata/core/dma_batch.hpp" #include "strata/core/spec_prob.hpp" #if defined(_WIN32) +#ifndef NOMINMAX +#define NOMINMAX +#endif +#include #include #endif @@ -1878,7 +1882,14 @@ bool Verifier::capture(int T, std::string& err) { if (ty == hipGraphNodeTypeKernel) { hipKernelNodeParams kp{}; if (hipGraphKernelNodeGetParams(nd, &kp) == hipSuccess && kp.func != nullptr) { +#if defined(_WIN32) + using Fn_hipKernelNameRefByPtr = const char* (*)(const void*, hipStream_t); + static auto p_hipKernelNameRefByPtr = reinterpret_cast( + GetProcAddress(GetModuleHandleA("amdhip64_7.dll"), "hipKernelNameRefByPtr")); + const char* fn = p_hipKernelNameRefByPtr ? p_hipKernelNameRefByPtr(kp.func, nullptr) : nullptr; +#else const char* fn = hipKernelNameRefByPtr(kp.func, nullptr); +#endif if (fn != nullptr) name = fn; } } else if (ty == hipGraphNodeTypeMemcpy) name = "memcpy";