diff --git a/projects/rocr-runtime/runtime/hsa-runtime/core/inc/runtime.h b/projects/rocr-runtime/runtime/hsa-runtime/core/inc/runtime.h index e7f856b067..d2d9d48e16 100644 --- a/projects/rocr-runtime/runtime/hsa-runtime/core/inc/runtime.h +++ b/projects/rocr-runtime/runtime/hsa-runtime/core/inc/runtime.h @@ -124,6 +124,7 @@ class Runtime { HsaVersionInfo version; bool supports_exception_debugging; bool supports_event_age; + bool supports_core_dump; }; /// @brief Open connection to kernel driver and increment reference count. @@ -451,8 +452,9 @@ class Runtime { kfd_version.supports_event_age = true; } - void KfdVersion(bool exception_debugging) { + void KfdVersion(bool exception_debugging, bool core_dump) { kfd_version.supports_exception_debugging = exception_debugging; + kfd_version.supports_core_dump = core_dump; } KfdVersion_t KfdVersion() const { return kfd_version; } diff --git a/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/amd_topology.cpp b/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/amd_topology.cpp index fc0d98ca9e..142175c326 100644 --- a/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/amd_topology.cpp +++ b/projects/rocr-runtime/runtime/hsa-runtime/core/runtime/amd_topology.cpp @@ -417,7 +417,10 @@ bool Load() { HSAKMT_STATUS err = hsaKmtRuntimeEnable(&_amdgpu_r_debug, core::Runtime::runtime_singleton_->flag().debug()); if ((err != HSAKMT_STATUS_SUCCESS) && (err != HSAKMT_STATUS_NOT_SUPPORTED)) return false; - core::Runtime::runtime_singleton_->KfdVersion(err != HSAKMT_STATUS_NOT_SUPPORTED); + HSAuint32 caps_mask; + hsaKmtGetRuntimeCapabilities(&caps_mask); + core::Runtime::runtime_singleton_->KfdVersion(err != HSAKMT_STATUS_NOT_SUPPORTED, + !!(caps_mask & HSA_RUNTIME_ENABLE_CAPS_SUPPORTS_CORE_DUMP_MASK)); kfd.Dismiss(); return true;