370a86830b
* 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]
57 lines
1.9 KiB
CMake
57 lines
1.9 KiB
CMake
#
|
|
#
|
|
#
|
|
rocprofiler_deactivate_clang_tidy()
|
|
|
|
include(GoogleTest)
|
|
|
|
# -------------------------------------------------------------------------------------- #
|
|
#
|
|
# Link to static rocprofiler library
|
|
#
|
|
# -------------------------------------------------------------------------------------- #
|
|
|
|
set(rocprofiler_lib_sources agent.cpp buffer.cpp timestamp.cpp version.cpp)
|
|
|
|
add_executable(rocprofiler-lib-tests)
|
|
target_sources(rocprofiler-lib-tests PRIVATE ${rocprofiler_lib_sources} details/agent.cpp)
|
|
target_link_libraries(
|
|
rocprofiler-lib-tests
|
|
PRIVATE rocprofiler::rocprofiler-static-library
|
|
rocprofiler::rocprofiler-common-library GTest::gtest GTest::gtest_main)
|
|
|
|
gtest_add_tests(
|
|
TARGET rocprofiler-lib-tests
|
|
SOURCES ${rocprofiler_lib_sources}
|
|
TEST_LIST lib_TESTS
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
|
|
|
set_tests_properties(${lib_TESTS} PROPERTIES TIMEOUT 45 LABELS "unittests")
|
|
|
|
# -------------------------------------------------------------------------------------- #
|
|
#
|
|
# Link to shared rocprofiler library
|
|
#
|
|
# -------------------------------------------------------------------------------------- #
|
|
|
|
set(rocprofiler_shared_lib_sources external_correlation.cpp intercept_table.cpp
|
|
registration.cpp status.cpp)
|
|
|
|
add_executable(rocprofiler-lib-tests-shared)
|
|
target_sources(rocprofiler-lib-tests-shared PRIVATE ${rocprofiler_shared_lib_sources})
|
|
target_link_libraries(
|
|
rocprofiler-lib-tests-shared
|
|
PRIVATE rocprofiler::rocprofiler-shared-library
|
|
rocprofiler::rocprofiler-common-library GTest::gtest GTest::gtest_main)
|
|
|
|
gtest_add_tests(
|
|
TARGET rocprofiler-lib-tests-shared
|
|
SOURCES ${rocprofiler_shared_lib_sources}
|
|
TEST_LIST shared_lib_TESTS
|
|
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR})
|
|
|
|
set_tests_properties(
|
|
${shared_lib_TESTS}
|
|
PROPERTIES TIMEOUT 360 LABELS "unittests" ENVIRONMENT
|
|
"HSA_TOOLS_LIB=$<TARGET_FILE:rocprofiler-shared-library>")
|