diff --git a/source/include/rocprofiler-sdk/cxx/enum_string.hpp b/source/include/rocprofiler-sdk/cxx/enum_string.hpp index bab2eba517..004fd7a0a8 100644 --- a/source/include/rocprofiler-sdk/cxx/enum_string.hpp +++ b/source/include/rocprofiler-sdk/cxx/enum_string.hpp @@ -350,6 +350,12 @@ ROCPROFILER_ENUM_LABEL(ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_enable_logging); # if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x05 ROCPROFILER_ENUM_LABEL(ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_signal_wait_all); # endif +# if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x06 +ROCPROFILER_ENUM_LABEL(ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_memory_get_preferred_copy_engine); +# endif +# if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x07 +ROCPROFILER_ENUM_LABEL(ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_portable_export_dmabuf_v2); +# endif #endif #if HSA_AMD_EXT_API_TABLE_MAJOR_VERSION == 0x01 @@ -369,6 +375,8 @@ static_assert(ROCPROFILER_HSA_AMD_EXT_API_ID_LAST == 71); static_assert(ROCPROFILER_HSA_AMD_EXT_API_ID_LAST == 72); # elif HSA_AMD_EXT_API_TABLE_STEP_VERSION == 0x06 static_assert(ROCPROFILER_HSA_AMD_EXT_API_ID_LAST == 73); +# elif HSA_AMD_EXT_API_TABLE_STEP_VERSION == 0x07 +static_assert(ROCPROFILER_HSA_AMD_EXT_API_ID_LAST == 74); # else # if !defined(ROCPROFILER_UNSAFE_NO_VERSION_CHECK) && \ (defined(ROCPROFILER_CI) && ROCPROFILER_CI > 0) diff --git a/source/include/rocprofiler-sdk/hsa/amd_ext_api_id.h b/source/include/rocprofiler-sdk/hsa/amd_ext_api_id.h index e2febb03e7..18f9e87d60 100644 --- a/source/include/rocprofiler-sdk/hsa/amd_ext_api_id.h +++ b/source/include/rocprofiler-sdk/hsa/amd_ext_api_id.h @@ -118,6 +118,9 @@ typedef enum rocprofiler_hsa_amd_ext_api_id_t // NOLINT(performance-enum-size) # if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x06 ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_memory_get_preferred_copy_engine, # endif +# if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x07 + ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_portable_export_dmabuf_v2, +# endif #endif ROCPROFILER_HSA_AMD_EXT_API_ID_LAST, diff --git a/source/include/rocprofiler-sdk/hsa/api_args.h b/source/include/rocprofiler-sdk/hsa/api_args.h index 62bffba3ff..379eab6bd8 100644 --- a/source/include/rocprofiler-sdk/hsa/api_args.h +++ b/source/include/rocprofiler-sdk/hsa/api_args.h @@ -1434,6 +1434,16 @@ typedef union rocprofiler_hsa_api_args_t uint32_t* recommended_ids_mask; } hsa_amd_memory_get_preferred_copy_engine; # endif +# if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x07 + struct + { + const void* ptr; + size_t size; + int* dmabuf; + uint64_t* offset; + uint64_t flags; + } hsa_amd_portable_export_dmabuf_v2; +# endif #endif } rocprofiler_hsa_api_args_t; diff --git a/source/lib/rocprofiler-sdk/hsa/abi.cpp b/source/lib/rocprofiler-sdk/hsa/abi.cpp index d9da99bbfa..2a5db235c5 100644 --- a/source/lib/rocprofiler-sdk/hsa/abi.cpp +++ b/source/lib/rocprofiler-sdk/hsa/abi.cpp @@ -55,6 +55,8 @@ ROCP_SDK_ENFORCE_ABI_VERSIONING(::AmdExtTable, 72); ROCP_SDK_ENFORCE_ABI_VERSIONING(::AmdExtTable, 73); #elif HSA_AMD_EXT_API_TABLE_STEP_VERSION == 0x06 ROCP_SDK_ENFORCE_ABI_VERSIONING(::AmdExtTable, 74); +#elif HSA_AMD_EXT_API_TABLE_STEP_VERSION == 0x07 +ROCP_SDK_ENFORCE_ABI_VERSIONING(::AmdExtTable, 75); #else INTERNAL_CI_ROCP_SDK_ENFORCE_ABI_VERSIONING(::AmdExtTable, 0); #endif @@ -288,6 +290,9 @@ ROCP_SDK_ENFORCE_ABI(::AmdExtTable, hsa_amd_signal_wait_all_fn, 72); #if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x06 ROCP_SDK_ENFORCE_ABI(::AmdExtTable, hsa_amd_memory_get_preferred_copy_engine_fn, 73); #endif +#if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x07 +ROCP_SDK_ENFORCE_ABI(::AmdExtTable, hsa_amd_portable_export_dmabuf_v2_fn, 74); +#endif ROCP_SDK_ENFORCE_ABI(::ImageExtTable, hsa_ext_image_get_capability_fn, 1); ROCP_SDK_ENFORCE_ABI(::ImageExtTable, hsa_ext_image_data_get_info_fn, 2); diff --git a/source/lib/rocprofiler-sdk/hsa/hsa.def.cpp b/source/lib/rocprofiler-sdk/hsa/hsa.def.cpp index 4f09d0eda4..aa839a5c28 100644 --- a/source/lib/rocprofiler-sdk/hsa/hsa.def.cpp +++ b/source/lib/rocprofiler-sdk/hsa/hsa.def.cpp @@ -485,6 +485,17 @@ HSA_API_INFO_DEFINITION_V(ROCPROFILER_HSA_TABLE_ID_AmdExt, src_agent, recommended_ids_mask) # endif +# if HSA_AMD_EXT_API_TABLE_STEP_VERSION >= 0x07 +HSA_API_INFO_DEFINITION_V(ROCPROFILER_HSA_TABLE_ID_AmdExt, + ROCPROFILER_HSA_AMD_EXT_API_ID_hsa_amd_portable_export_dmabuf_v2, + hsa_amd_portable_export_dmabuf_v2, + hsa_amd_portable_export_dmabuf_v2_fn, + ptr, + size, + dmabuf, + offset, + flags) +# endif # endif #elif defined(ROCPROFILER_LIB_ROCPROFILER_HSA_ASYNC_COPY_CPP_IMPL) && \