CI: Relax timestamp checking (#1189)
* Relax timestamp checking - Prevent recurring CI failures that have no remedy until HSA/driver issues are resolved * Replace "cc" abbreviation in tests with "counter-collection" * Update CODEOWNERS to explicitly include jrmadsen for source/include * Extra logging in rocprofiler tool library * Tweak aborted-app test - remove counter collection as part of the test
Bu işleme şunda yer alıyor:
işlemeyi yapan:
GitHub
ebeveyn
6564419357
işleme
98858b60ec
+1
-2
@@ -6,7 +6,7 @@
|
||||
#
|
||||
source/docs @bgopesh
|
||||
|
||||
source/include @bwelton @ammarwa
|
||||
source/include @jrmadsen @bwelton @ammarwa
|
||||
source/include/rocprofiler-sdk/rccl @MythreyaK
|
||||
source/include/rocprofiler-sdk/cxx/codeobj @ApoKalipse-V
|
||||
|
||||
@@ -23,4 +23,3 @@ source/lib/rocprofiler-sdk/rccl @MythreyaK
|
||||
source/lib/rocprofiler-sdk-tool @SrirakshaNag
|
||||
|
||||
source/lib/rocprofiler-sdk-codeobj @ApoKalipse-V
|
||||
|
||||
|
||||
@@ -922,9 +922,8 @@ get_device_counting_service(rocprofiler_agent_id_t agent_id)
|
||||
name_v = itr.substr(0, pos);
|
||||
auto dev_id_s = itr.substr(pos + device_qualifier.length());
|
||||
|
||||
LOG_IF(FATAL,
|
||||
dev_id_s.empty() ||
|
||||
dev_id_s.find_first_not_of("0123456789") != std::string::npos)
|
||||
ROCP_FATAL_IF(dev_id_s.empty() ||
|
||||
dev_id_s.find_first_not_of("0123456789") != std::string::npos)
|
||||
<< "invalid device qualifier format (':device=N) where N is the GPU id: "
|
||||
<< itr;
|
||||
|
||||
@@ -1203,6 +1202,7 @@ void
|
||||
initialize_rocprofv3()
|
||||
{
|
||||
ROCP_INFO << "initializing rocprofv3...";
|
||||
|
||||
if(int status = 0;
|
||||
rocprofiler_is_initialized(&status) == ROCPROFILER_STATUS_SUCCESS && status == 0)
|
||||
{
|
||||
@@ -1210,21 +1210,26 @@ initialize_rocprofv3()
|
||||
"force configuration");
|
||||
}
|
||||
|
||||
LOG_IF(FATAL, !client_identifier) << "nullptr to client identifier!";
|
||||
LOG_IF(FATAL, !client_finalizer && !tool::get_config().list_metrics)
|
||||
ROCP_FATAL_IF(!client_identifier) << "nullptr to client identifier!";
|
||||
ROCP_FATAL_IF(!client_finalizer && !tool::get_config().list_metrics)
|
||||
<< "nullptr to client finalizer!"; // exception for listing metrics
|
||||
}
|
||||
|
||||
void
|
||||
finalize_rocprofv3()
|
||||
finalize_rocprofv3(std::string_view context)
|
||||
{
|
||||
ROCP_INFO << "finalizing rocprofv3...";
|
||||
ROCP_INFO << "invoked: finalize_rocprofv3";
|
||||
if(client_finalizer && client_identifier)
|
||||
{
|
||||
ROCP_INFO << "finalizing rocprofv3: caller='" << context << "'...";
|
||||
client_finalizer(*client_identifier);
|
||||
client_finalizer = nullptr;
|
||||
client_identifier = nullptr;
|
||||
}
|
||||
else
|
||||
{
|
||||
ROCP_INFO << "finalize_rocprofv3('" << context << "') ignored: already finalized";
|
||||
}
|
||||
}
|
||||
|
||||
timestamps_t*
|
||||
@@ -1820,7 +1825,9 @@ rocprofv3_set_main(main_func_t main_func) ROCPROFV3_INTERNAL_API;
|
||||
void
|
||||
rocprofv3_error_signal_handler(int signo)
|
||||
{
|
||||
finalize_rocprofv3();
|
||||
ROCP_WARNING << __FUNCTION__ << " caught signal " << signo << "...";
|
||||
|
||||
finalize_rocprofv3(__FUNCTION__);
|
||||
// below is for testing purposes. re-raising the signal causes CTest to ignore WILL_FAIL ON
|
||||
if(signal_handler_exit) ::exit(signo);
|
||||
::raise(signo);
|
||||
@@ -1863,7 +1870,7 @@ rocprofiler_configure(uint32_t version,
|
||||
add_destructor(stats_timestamp);
|
||||
|
||||
// in case main wrapper is not used
|
||||
::atexit(finalize_rocprofv3);
|
||||
::atexit([]() { finalize_rocprofv3("atexit"); });
|
||||
|
||||
if(tool::get_config().list_metrics)
|
||||
{
|
||||
@@ -1927,9 +1934,13 @@ rocprofv3_main(int argc, char** argv, char** envp)
|
||||
}
|
||||
}
|
||||
|
||||
ROCP_INFO << "rocprofv3: main function wrapper will be invoked...";
|
||||
|
||||
auto ret = CHECK_NOTNULL(get_main_function())(argc, argv, envp);
|
||||
|
||||
finalize_rocprofv3();
|
||||
ROCP_INFO << "rocprofv3: main function has returned with exit code: " << ret;
|
||||
|
||||
finalize_rocprofv3(__FUNCTION__);
|
||||
|
||||
ROCP_INFO << "rocprofv3 finished. exit code: " << ret;
|
||||
return ret;
|
||||
|
||||
@@ -342,14 +342,20 @@ async_copy_handler(hsa_signal_value_t signal_value, void* arg)
|
||||
{
|
||||
_profile_time = tracing::adjust_profiling_time(
|
||||
"memcpy",
|
||||
"hsa_amd_profiling_get_async_copy_time",
|
||||
_profile_time,
|
||||
tracing::profiling_time{HSA_STATUS_SUCCESS, _data->start_ts, ts});
|
||||
|
||||
// if we encounter this in CI, it will cause test to fail
|
||||
ROCP_CI_LOG_IF(ERROR, _profile_time.end < _profile_time.start)
|
||||
<< "hsa_amd_profiling_get_async_copy_time for returned async times where the end time ("
|
||||
<< _profile_time.end << ") was less than the start time (" << _profile_time.start
|
||||
<< ")";
|
||||
}
|
||||
else
|
||||
{
|
||||
ROCP_CI_LOG(ERROR) << fmt::format(
|
||||
"hsa_amd_profiling_get_async_copy_time for the {} copy operation from agent-{} to "
|
||||
"agent-{} returned status={} :: {}",
|
||||
std::string_view{hsa::async_copy::name_by_id(_data->direction)},
|
||||
CHECK_NOTNULL(agent::get_agent(_data->src_agent))->node_id,
|
||||
CHECK_NOTNULL(agent::get_agent(_data->dst_agent))->node_id,
|
||||
static_cast<int>(copy_time_status),
|
||||
hsa::get_hsa_status_string(copy_time_status));
|
||||
}
|
||||
|
||||
// get the contexts that were active when the signal was created
|
||||
|
||||
@@ -55,27 +55,22 @@ get_dispatch_time(hsa_agent_t _hsa_agent,
|
||||
|
||||
if(_profile_time.status == HSA_STATUS_SUCCESS)
|
||||
{
|
||||
// if we encounter this in CI, it will cause test to fail
|
||||
ROCP_CI_LOG_IF(ERROR, _profile_time.end < _profile_time.start)
|
||||
<< "hsa_amd_profiling_get_dispatch_time for kernel_id=" << _kernel_id
|
||||
<< " on rocprofiler_agent="
|
||||
<< CHECK_NOTNULL(agent::get_rocprofiler_agent(_hsa_agent))->node_id
|
||||
<< " returned dispatch times where the end time (" << _profile_time.end
|
||||
<< ") was less than the start time (" << _profile_time.start << ")";
|
||||
|
||||
_profile_time = tracing::adjust_profiling_time(
|
||||
"dispatch",
|
||||
"hsa_amd_profiling_get_dispatch_time",
|
||||
_profile_time,
|
||||
tracing::profiling_time{
|
||||
HSA_STATUS_SUCCESS, _baseline.value_or(dispatch_time.start), ts});
|
||||
}
|
||||
else
|
||||
{
|
||||
ROCP_CI_LOG(ERROR) << "hsa_amd_profiling_get_dispatch_time for kernel id=" << _kernel_id
|
||||
<< " on rocprofiler_agent="
|
||||
<< CHECK_NOTNULL(agent::get_rocprofiler_agent(_hsa_agent))->id.handle
|
||||
<< " returned status=" << dispatch_time_status
|
||||
<< " :: " << hsa::get_hsa_status_string(dispatch_time_status);
|
||||
ROCP_CI_LOG(ERROR) << fmt::format(
|
||||
"hsa_amd_profiling_get_dispatch_time for kernel id={} on agent-{} returned status={} "
|
||||
":: {}",
|
||||
_kernel_id,
|
||||
CHECK_NOTNULL(agent::get_rocprofiler_agent(_hsa_agent))->node_id,
|
||||
static_cast<int>(dispatch_time_status),
|
||||
hsa::get_hsa_status_string(dispatch_time_status));
|
||||
}
|
||||
|
||||
return _profile_time;
|
||||
|
||||
@@ -72,7 +72,10 @@ struct profiling_time
|
||||
};
|
||||
|
||||
inline profiling_time
|
||||
adjust_profiling_time(std::string_view _label, profiling_time _value, profiling_time&& _bounds)
|
||||
adjust_profiling_time(std::string_view _label,
|
||||
std::string_view _responsible,
|
||||
profiling_time _value,
|
||||
profiling_time&& _bounds)
|
||||
{
|
||||
static auto sysclock_period = hsa::get_hsa_timestamp_period();
|
||||
static auto normalize_env = common::get_env("ROCPROFILER_CI_FREQ_SCALE_TIMESTAMPS", false);
|
||||
@@ -84,19 +87,21 @@ adjust_profiling_time(std::string_view _label, profiling_time _value, profiling_
|
||||
|
||||
if(strict_ts_env)
|
||||
{
|
||||
ROCP_FATAL_IF(ROCPROFILER_UNLIKELY(_value.end < _value.start))
|
||||
<< fmt::format("Invalid {} time value: {} end time ({}) is less than the {} start time "
|
||||
"({}) :: difference={}",
|
||||
ROCP_FATAL_IF(ROCPROFILER_UNLIKELY(_value.start > _value.end))
|
||||
<< fmt::format("{} returned invalid {} time value: {} start time is greater than the "
|
||||
"{} end time ({} > {}) :: difference={}",
|
||||
_responsible,
|
||||
_label,
|
||||
_label,
|
||||
_value.end,
|
||||
_label,
|
||||
_value.start,
|
||||
(_value.end - _value.start));
|
||||
_value.end,
|
||||
(_value.start - _value.end));
|
||||
|
||||
ROCP_FATAL_IF(ROCPROFILER_UNLIKELY(_value.start < _bounds.start))
|
||||
<< fmt::format("Invalid {} time value: {} start time ({}) is less than the enqueue "
|
||||
"time on the CPU ({}) :: difference={}",
|
||||
<< fmt::format("{} returned invalid {} time value: {} start time is before the API "
|
||||
"call enqueuing the operation on the CPU ({} < {}) :: difference={}",
|
||||
_responsible,
|
||||
_label,
|
||||
_label,
|
||||
_value.start,
|
||||
@@ -105,8 +110,9 @@ adjust_profiling_time(std::string_view _label, profiling_time _value, profiling_
|
||||
(_bounds.start - _value.start));
|
||||
|
||||
ROCP_FATAL_IF(ROCPROFILER_UNLIKELY(_value.end > _bounds.end))
|
||||
<< fmt::format("Invalid {} time value: {} end time ({}) is greater than the current "
|
||||
"time on the CPU ({}) :: difference={}",
|
||||
<< fmt::format("{} returned invalid {} time value: {} end time is greater than the "
|
||||
"current time on the CPU ({} > {}) :: difference={}",
|
||||
_responsible,
|
||||
_label,
|
||||
_label,
|
||||
_value.end,
|
||||
@@ -115,6 +121,21 @@ adjust_profiling_time(std::string_view _label, profiling_time _value, profiling_
|
||||
(_value.end - _bounds.end));
|
||||
}
|
||||
|
||||
if(_value.start > _value.end)
|
||||
{
|
||||
ROCP_ERROR << fmt::format(
|
||||
"{} returned {} times where the start time is after end time ({} > {}) :: "
|
||||
"difference={}. Swapping the values. Set the environment variable "
|
||||
"ROCPROFILER_CI_STRICT_TIMESTAMPS=1 to cause a failure instead",
|
||||
_responsible,
|
||||
_label,
|
||||
_value.start,
|
||||
_value.end,
|
||||
(_value.start - _value.end));
|
||||
|
||||
std::swap(_value.start, _value.end);
|
||||
}
|
||||
|
||||
// below are hacks for clock skew issues:
|
||||
//
|
||||
// the timestamp of this handler will always be after when the profiling time ended
|
||||
|
||||
@@ -51,7 +51,7 @@ set_tests_properties(
|
||||
add_test(
|
||||
NAME rocprofv3-test-validate-app-abort
|
||||
COMMAND ${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py --json-input
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out-aborted-app/pass_1/out_results.json)
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out-aborted-app/out_results.json)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-validate-app-abort
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
{
|
||||
"jobs": [
|
||||
{
|
||||
"pmc":["SQ_WAVES"],
|
||||
"kernel_include_regex": "addition",
|
||||
"kernel_exclude_regex": "subtract",
|
||||
"hip_runtime_trace": true,
|
||||
"kernel_trace": true,
|
||||
"output_file": "out",
|
||||
"output_format": [
|
||||
"json"
|
||||
"csv",
|
||||
"json",
|
||||
"pftrace"
|
||||
],
|
||||
"truncate_kernels": true
|
||||
}
|
||||
|
||||
@@ -18,8 +18,9 @@ add_test(
|
||||
NAME rocprofv3-test-counter-collection-txt-pmc1-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.txt -T -d ${CMAKE_CURRENT_BINARY_DIR}/out_cc_1
|
||||
-o pmc1 --output-format csv json -- $<TARGET_FILE:vector-ops>)
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.txt -T -d
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_1 -o pmc1 --output-format csv
|
||||
json -- $<TARGET_FILE:vector-ops>)
|
||||
|
||||
string(REPLACE "LD_PRELOAD=" "ROCPROF_PRELOAD=" PRELOAD_ENV
|
||||
"${ROCPROFILER_MEMCHECK_PRELOAD_ENV}")
|
||||
@@ -35,8 +36,9 @@ add_test(
|
||||
NAME rocprofv3-test-counter-collection-pmc1-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py --input
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_cc_1/pmc_1/pmc1_counter_collection.csv
|
||||
--json-input ${CMAKE_CURRENT_BINARY_DIR}/out_cc_1/pmc_1/pmc1_results.json)
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_1/pmc_1/pmc1_counter_collection.csv
|
||||
--json-input
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_1/pmc_1/pmc1_results.json)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-counter-collection-pmc1-validate
|
||||
|
||||
@@ -15,7 +15,7 @@ rocprofiler_configure_pytest_files(CONFIG pytest.ini COPY validate.py conftest.p
|
||||
|
||||
# pmc1
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-json-execute
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-json-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.json -d ${CMAKE_CURRENT_BINARY_DIR}/json_input
|
||||
@@ -27,13 +27,13 @@ string(REPLACE "LD_PRELOAD=" "ROCPROF_PRELOAD=" PRELOAD_ENV
|
||||
set(cc-env-kernel-filtering "${PRELOAD_ENV}")
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-json-execute
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-json-execute
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" ENVIRONMENT
|
||||
"${cc-env-kernel-filtering}" FAIL_REGULAR_EXPRESSION
|
||||
"${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-cmd-execute
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-cmd-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.txt --kernel-include-regex ".*kernel"
|
||||
@@ -41,14 +41,14 @@ add_test(
|
||||
out --output-format csv -- $<TARGET_FILE:vector-ops>)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-cmd-execute
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-cmd-execute
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" ENVIRONMENT
|
||||
"${cc-env-kernel-filtering}" FAIL_REGULAR_EXPRESSION
|
||||
"${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
# pmc1
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-yaml-execute
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-yaml-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.yml -T -d
|
||||
@@ -56,12 +56,12 @@ add_test(
|
||||
$<TARGET_FILE:vector-ops>)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-yaml-execute
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-yaml-execute
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" ENVIRONMENT
|
||||
"${cc-env-kernel-filtering}" FAIL_REGULAR_EXPRESSION
|
||||
"${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-json-validate
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-json-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py -k _pass
|
||||
--input-csv-pass1
|
||||
@@ -78,7 +78,7 @@ add_test(
|
||||
--input-json-pass4 ${CMAKE_CURRENT_BINARY_DIR}/json_input/pass_4/out_results.json)
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-yaml-validate
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-yaml-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py -k _pass
|
||||
--input-csv-pass1
|
||||
@@ -95,26 +95,26 @@ add_test(
|
||||
--input-json-pass4 ${CMAKE_CURRENT_BINARY_DIR}/yaml_input/pass_4/out_results.json)
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-input-cmd-validate
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-input-cmd-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py -k
|
||||
test_validate_counter_collection_csv_pmc1 --input-csv-pmc1
|
||||
${CMAKE_CURRENT_BINARY_DIR}/cmd_input/pmc_1/out_counter_collection.csv)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-json-validate
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-json-validate
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" DEPENDS
|
||||
"rocprofv3-test-cc-kernel-filtering-input-json-execute"
|
||||
"rocprofv3-test-counter-collection-kernel-filtering-input-json-execute"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-cmd-validate
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-cmd-validate
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" DEPENDS
|
||||
"rocprofv3-test-cc-kernel-filtering-input-cmd-execute"
|
||||
"rocprofv3-test-counter-collection-kernel-filtering-input-cmd-execute"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-input-yaml-validate
|
||||
rocprofv3-test-counter-collection-kernel-filtering-input-yaml-validate
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" DEPENDS
|
||||
"rocprofv3-test-cc-kernel-filtering-input-yaml-execute"
|
||||
"rocprofv3-test-counter-collection-kernel-filtering-input-yaml-execute"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
@@ -14,9 +14,11 @@ rocprofiler_configure_pytest_files(CONFIG pytest.ini COPY validate.py conftest.p
|
||||
input.json)
|
||||
|
||||
# basic-metrics
|
||||
add_test(NAME rocprofv3-test-list-metrics-execute
|
||||
COMMAND $<TARGET_FILE:rocprofiler-sdk::rocprofv3> -d
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_cc_2 -o metrics --list-metrics)
|
||||
add_test(
|
||||
NAME rocprofv3-test-list-metrics-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -d
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_2 -o metrics --list-metrics)
|
||||
|
||||
# list-metrics-stdout
|
||||
add_test(NAME rocprofv3-test-list-metrics-std-out-execute
|
||||
@@ -45,17 +47,18 @@ set_tests_properties(
|
||||
PASS_REGULAR_EXPRESSION
|
||||
"gpu-agent[0-9]*:[a-zA-Z_]*\\n;Description:(.*)\\n*;Expression:(.)*\\n*;Block:[a-zA-Z]*\\n*;Dimensions:([A-Z_]*\\[[0-9]*:[0-9]*\\])*\\n*;"
|
||||
)
|
||||
set(VALIDATION_FILES ${CMAKE_CURRENT_BINARY_DIR}/out_cc_2/metrics_basic_metrics.csv
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_cc_2/metrics_derived_metrics.csv)
|
||||
set(VALIDATION_FILES
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_2/metrics_basic_metrics.csv
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_2/metrics_derived_metrics.csv)
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-list-metrics-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py
|
||||
--derived-metrics-input
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_cc_2/metrics_derived_metrics.csv
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_2/metrics_derived_metrics.csv
|
||||
--basic-metrics-input
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_cc_2/metrics_basic_metrics.csv)
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_2/metrics_basic_metrics.csv)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-list-metrics-validate
|
||||
|
||||
@@ -14,7 +14,7 @@ rocprofiler_configure_pytest_files(CONFIG pytest.ini COPY validate.py conftest.p
|
||||
input_range.json)
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-range-filter-execute
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-range-filter-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input_range.json -d
|
||||
@@ -26,13 +26,13 @@ string(REPLACE "LD_PRELOAD=" "ROCPROF_PRELOAD=" PRELOAD_ENV
|
||||
set(cc-env-kernel-filtering "${PRELOAD_ENV}")
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-range-filter-execute
|
||||
rocprofv3-test-counter-collection-kernel-filtering-range-filter-execute
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" ENVIRONMENT
|
||||
"${cc-env-kernel-filtering}" FAIL_REGULAR_EXPRESSION
|
||||
"${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
add_test(
|
||||
NAME rocprofv3-test-cc-kernel-filtering-range-filter-validate
|
||||
NAME rocprofv3-test-counter-collection-kernel-filtering-range-filter-validate
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py --json-config
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input_range.json --input-json-pass1
|
||||
@@ -43,7 +43,7 @@ add_test(
|
||||
${CMAKE_CURRENT_BINARY_DIR}/range_filter/pass_3/out_results.json)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-cc-kernel-filtering-range-filter-validate
|
||||
rocprofv3-test-counter-collection-kernel-filtering-range-filter-validate
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" DEPENDS
|
||||
"rocprofv3-test-cc-kernel-filtering-range-filter-execute"
|
||||
"rocprofv3-test-counter-collection-kernel-filtering-range-filter-execute"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
@@ -19,8 +19,9 @@ add_test(
|
||||
NAME rocprofv3-test-tracing-plus-counter-collection-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> --hsa-trace -i
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.txt -d ${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace
|
||||
-o pmc3 --output-format JSON PFTRACE CSV -- $<TARGET_FILE:simple-transpose>)
|
||||
${CMAKE_CURRENT_BINARY_DIR}/input.txt -d
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace -o pmc3 --output-format
|
||||
JSON PFTRACE CSV -- $<TARGET_FILE:simple-transpose>)
|
||||
|
||||
string(REPLACE "LD_PRELOAD=" "ROCPROF_PRELOAD=" PRELOAD_ENV
|
||||
"${ROCPROFILER_MEMCHECK_PRELOAD_ENV}")
|
||||
@@ -38,22 +39,22 @@ foreach(_DIR "pmc_1" "pmc_2" "pmc_3" "pmc_4")
|
||||
NAME rocprofv3-test-tracing-plus-counter-collection-validate-${_DIR}
|
||||
COMMAND
|
||||
${Python3_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/validate.py --json-input
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/${_DIR}/pmc3_results.json"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/${_DIR}/pmc3_results.json"
|
||||
--pftrace-input
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/${_DIR}/pmc3_results.pftrace"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/${_DIR}/pmc3_results.pftrace"
|
||||
--hsa-input
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/${_DIR}/pmc3_hsa_api_trace.csv"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/${_DIR}/pmc3_hsa_api_trace.csv"
|
||||
--agent-input
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/${_DIR}/pmc3_agent_info.csv"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/${_DIR}/pmc3_agent_info.csv"
|
||||
--counter-input
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/${_DIR}/pmc3_counter_collection.csv"
|
||||
"${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/${_DIR}/pmc3_counter_collection.csv"
|
||||
)
|
||||
|
||||
set_tests_properties(
|
||||
rocprofv3-test-tracing-plus-counter-collection-validate-${_DIR}
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests;application-replay" DEPENDS
|
||||
"rocprofv3-test-tracing-plus-cc-execute" FAIL_REGULAR_EXPRESSION
|
||||
"${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
"rocprofv3-test-tracing-plus-counter-collection-execute"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
endforeach()
|
||||
|
||||
set(cmdl_single "GRBM_COUNT")
|
||||
@@ -68,8 +69,8 @@ foreach(_GROUP "single" "multiple")
|
||||
NAME ${_TEST_NAME_PREFIX}-execute
|
||||
COMMAND
|
||||
$<TARGET_FILE:rocprofiler-sdk::rocprofv3> --hip-trace --hsa-trace --pmc
|
||||
${cmdl_${_GROUP}} -d ${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace -o
|
||||
cmdl/${_GROUP} --output-format JSON PFTRACE CSV --
|
||||
${cmdl_${_GROUP}} -d ${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace
|
||||
-o cmdl/${_GROUP} --output-format JSON PFTRACE CSV --
|
||||
$<TARGET_FILE:simple-transpose>)
|
||||
|
||||
set_tests_properties(
|
||||
@@ -77,7 +78,8 @@ foreach(_GROUP "single" "multiple")
|
||||
PROPERTIES TIMEOUT 45 LABELS "integration-tests" ENVIRONMENT "${cc-tracing-env}"
|
||||
FAIL_REGULAR_EXPRESSION "${ROCPROFILER_DEFAULT_FAIL_REGEX}")
|
||||
|
||||
set(_TEST_OUTPUT_PREFIX ${CMAKE_CURRENT_BINARY_DIR}/out_cc_trace/cmdl/${_GROUP})
|
||||
set(_TEST_OUTPUT_PREFIX
|
||||
${CMAKE_CURRENT_BINARY_DIR}/out_counter_collection_trace/cmdl/${_GROUP})
|
||||
|
||||
add_test(
|
||||
NAME ${_TEST_NAME_PREFIX}-validate
|
||||
|
||||
Yeni konuda referans
Bir kullanıcı engelle