Support Tool Intercept API Tables (#165)
* Update include/rocprofiler
- intercept_table.h header
- generic rocprofiler_runtime_library_t
- rocprofiler_internal_thread_library_t is not typedef for rocprofiler_runtime_library_t
- rocprofiler_at_runtime_api_registration
* Update lib/rocprofiler
- minor tweaks to context.cpp
- check if none context early
- disallow stop_context when finalizing
- add intercept_table.hpp and intercept_table.cpp
- implement rocprofiler_at_runtime_api_registration
- implement notify_runtime_api_registration
- update registration.cpp
- invoke notify_runtime_api_registration
- tweak to fini status when invoking client finalizer
* Update lib/rocprofiler/tests
- add tests for intercept table
* Add samples/intercept_table
- demonstrate how to install custom API function wrappers instead of relying on HSA callback tracing
* Update lib/rocprofiler/tests/intercept_table.cpp
- remove _SERVICE from ROCPROFILER_SERVICE_
* Update include/rocprofiler/intercept_table.h
- Update doxygen comments
* Update lib/rocprofiler/intercept_table.cpp
- return error config locked if already initialized
* Update lib/rocprofiler/intercept_table.cpp
- remove unnecessary alias
* Apply suggestions from code review
Co-authored-by: Tony Tye <Tony.Tye@amd.com>
* Update doxygen comments
- clarify when rocprofiler_at_runtime_api_registration can be invoked
* Use rocprofiler_runtime_library_t for intercept table and internal threading
- remove rocprofiler_intercept_library_t alias to rocprofiler_runtime_library_t
- remove rocprofiler_internal_thread_library_t alias to rocprofiler_runtime_library_t
- move around documentation with regard to rocprofiler_runtime_library_t enumeration
- added some extra doxygen documentation to internal threading functions
---------
Co-authored-by: Tony Tye <Tony.Tye@amd.com>
[ROCm/rocprofiler-sdk commit: 4f2dc896d3]
This commit is contained in:
committed by
GitHub
parent
1e2a80ef8e
commit
370a86830b
@@ -245,7 +245,7 @@ tool_tracing_callback(rocprofiler_context_id_t context,
|
||||
}
|
||||
|
||||
void
|
||||
thread_precreate(rocprofiler_internal_thread_library_t lib, void* tool_data)
|
||||
thread_precreate(rocprofiler_runtime_library_t lib, void* tool_data)
|
||||
{
|
||||
static_cast<call_stack_t*>(tool_data)->emplace_back(
|
||||
source_location{__FUNCTION__,
|
||||
@@ -256,7 +256,7 @@ thread_precreate(rocprofiler_internal_thread_library_t lib, void* tool_data)
|
||||
}
|
||||
|
||||
void
|
||||
thread_postcreate(rocprofiler_internal_thread_library_t lib, void* tool_data)
|
||||
thread_postcreate(rocprofiler_runtime_library_t lib, void* tool_data)
|
||||
{
|
||||
static_cast<call_stack_t*>(tool_data)->emplace_back(
|
||||
source_location{__FUNCTION__,
|
||||
|
||||
Reference in New Issue
Block a user