2f9b1767e9
* Handle hsa_queue_destroy after finalization
- fixes issue where hsa_queue_destroy(...) is invoked after rocprofiler-sdk has finalized
- hsa::get_queue_controller() returns pointer
- if queue controller is a null pointer, skip invoking QueueController::destroy_queue
* Update HIP/HSA/marker update_table logging
* Update rocprofv3 tests
- remove HSA_TOOLS_LIB env variable
- remove setting ROCPROFILER_LOG_LEVEL env variable
- add timeouts to tests which are missing them
* Disable thread sanitizer deadlock detection
* Update CI workflow
- rename vega20-ubuntu job to core-ci
- enable navi32 in core-ci and sanitizers
* Update run-ci.py
- set gcovr html medium and high threshold
* Update lib/rocprofiler-sdk/hsa/queue_controller.cpp
- remove this capture from enable/disable serialization
* Update lib/rocprofiler-sdk/hsa/{hsa_barrier,profile_serializer}.*
- hsa_barrier::set_barrier accepts const-ref to queue map
- profile_serializer::enable and profile_serializer::disable accept const-ref to queue map
* Logging for HIP/HSA/marker/profile_serializer
* Logging for HIP/HSA/marker/queue_controller
* Improve test_retired_correlation_ids asserts
* Fix tests/counter-collection/validate.py
- scale expected SQ_WAVES counter value based on warp size of GPU
* Tweak github comment for code coverage
* Remove gcovr html high/medium threshold args
* Fix tests/counter-collection/validate.py
- round before casting to int in test_counter_values
* operator bool for profile_serializer
- only wait on CV if profile_serializer is used
* Logging updates (profile_serializer + code_object)
* Update counter-collection validate.py
* QueueController does not wait on CV if finalizing/finalized
* Update CI workflow
- remove navi32 from core job
* Improve HIP/HSA/marker tracing get_functor/functor
- remove lambda wrapper around functor
* Update lib/rocprofiler-sdk/hsa/queue_controller.cpp
- do not acquire cvmutex lock during finalization
* Update lib/rocprofiler-sdk/hsa/hsa_barrier.*
- move ctor and dtor to implementation
- skip signal store screlease and destroy if already finalized
* Update CI workflow
- remove navi32 runners
* bwelton fixes for hangs
* CMake improvements + simplified demangle
- remove amd-comgr from common target (and thus removed from roctx DT_NEEDED)
---------
Co-authored-by: Benjamin Welton <bewelton@amd.com>
134 строки
4.5 KiB
CMake
134 строки
4.5 KiB
CMake
#
|
|
# rocprofv3 tool test
|
|
#
|
|
cmake_minimum_required(VERSION 3.21.0 FATAL_ERROR)
|
|
|
|
project(
|
|
rocprofiler-tests-rocprofv3-tracing
|
|
LANGUAGES CXX
|
|
VERSION 0.0.0)
|
|
|
|
find_package(rocprofiler-sdk REQUIRED)
|
|
|
|
add_test(
|
|
NAME rocprofv3-test-trace-execute
|
|
COMMAND
|
|
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -M --hsa-trace --kernel-trace
|
|
--memory-copy-trace --marker-trace -d ${CMAKE_CURRENT_BINARY_DIR}/%argt%-trace -o
|
|
out $<TARGET_FILE:simple-transpose>)
|
|
|
|
string(REPLACE "LD_PRELOAD=" "ROCPROF_PRELOAD=" PRELOAD_ENV
|
|
"${ROCPROFILER_MEMCHECK_PRELOAD_ENV}")
|
|
|
|
if(ROCPROFILER_MEMCHECK STREQUAL "LeakSanitizer")
|
|
set(LOG_LEVEL "warning") # info produces memory leak
|
|
else()
|
|
set(LOG_LEVEL "info")
|
|
endif()
|
|
|
|
set(tracing-env "${PRELOAD_ENV}" "ROCPROF_LOG_LEVEL=${LOG_LEVEL}")
|
|
|
|
set_tests_properties(
|
|
rocprofv3-test-trace-execute
|
|
PROPERTIES
|
|
TIMEOUT
|
|
45
|
|
LABELS
|
|
"integration-tests"
|
|
ENVIRONMENT
|
|
"${tracing-env}"
|
|
FAIL_REGULAR_EXPRESSION
|
|
"HSA_API|HIP_API|HIP_COMPILER_API|MARKER_CORE_API|MARKER_CONTROL_API|MARKER_NAME_API|KERNEL_DISPATCH|CODE_OBJECT"
|
|
)
|
|
|
|
foreach(FILENAME validate.py conftest.py)
|
|
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/${FILENAME}
|
|
${CMAKE_CURRENT_BINARY_DIR}/${FILENAME} COPYONLY)
|
|
endforeach()
|
|
|
|
add_test(
|
|
NAME rocprofv3-test-trace-validate
|
|
COMMAND
|
|
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py --hsa-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_hsa_api_trace.csv
|
|
--kernel-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_kernel_trace.csv
|
|
--memory-copy-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_memory_copy_trace.csv
|
|
--marker-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_marker_api_trace.csv)
|
|
|
|
set(VALIDATION_FILES
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_memory_copy_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_hsa_api_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_kernel_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-trace/out_marker_api_trace.csv)
|
|
|
|
set_tests_properties(
|
|
rocprofv3-test-trace-validate
|
|
PROPERTIES TIMEOUT
|
|
45
|
|
LABELS
|
|
"integration-tests"
|
|
DEPENDS
|
|
rocprofv3-test-trace-execute
|
|
FAIL_REGULAR_EXPRESSION
|
|
"AssertionError"
|
|
ATTACHED_FILES_ON_FAIL
|
|
"${VALIDATION_FILES}")
|
|
|
|
# sys-trace test: tests --sys-trace command with mangled kernel names and validates
|
|
# generated files
|
|
|
|
add_test(
|
|
NAME rocprofv3-test-systrace-execute
|
|
COMMAND
|
|
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> --sys-trace -d
|
|
${CMAKE_CURRENT_BINARY_DIR}/%argt%-systrace -o out
|
|
$<TARGET_FILE:simple-transpose>)
|
|
|
|
set_tests_properties(
|
|
rocprofv3-test-systrace-execute
|
|
PROPERTIES
|
|
TIMEOUT
|
|
45
|
|
LABELS
|
|
"integration-tests"
|
|
ENVIRONMENT
|
|
"${tracing-env}"
|
|
FAIL_REGULAR_EXPRESSION
|
|
"HSA_API|HIP_API|HIP_COMPILER_API|MARKER_CORE_API|MARKER_CONTROL_API|MARKER_NAME_API|KERNEL_DISPATCH|CODE_OBJECT"
|
|
)
|
|
|
|
add_test(
|
|
NAME rocprofv3-test-systrace-validate
|
|
COMMAND
|
|
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py -k
|
|
"not test_hsa_api_trace" --hsa-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_hsa_api_trace.csv
|
|
--kernel-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_kernel_trace.csv
|
|
--memory-copy-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_memory_copy_trace.csv
|
|
--marker-input
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_marker_api_trace.csv)
|
|
|
|
set(SYS_VALIDATION_FILES
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_memory_copy_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_hsa_api_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_kernel_trace.csv
|
|
${CMAKE_CURRENT_BINARY_DIR}/simple-transpose-systrace/out_marker_api_trace.csv)
|
|
|
|
set_tests_properties(
|
|
rocprofv3-test-systrace-validate
|
|
PROPERTIES TIMEOUT
|
|
45
|
|
LABELS
|
|
"integration-tests"
|
|
DEPENDS
|
|
rocprofv3-test-systrace-execute
|
|
FAIL_REGULAR_EXPRESSION
|
|
"AssertionError"
|
|
ATTACHED_FILES_ON_FAIL
|
|
"${SYS_VALIDATION_FILES}")
|