Miscellaneous Testing Fixes + CMake find_package include guard (#1106)
* Improve ROCPROFILER_DEFAULT_FAIL_REGEX * Support find_package called twice * Skip iteration of ROCPROFILER_AGENT_TYPE_CPU * Relax tests/rocprofv3/summary * Tweak to rocprofiler-sdk-tool/tool.cpp * Move rocprofv3-trigger-list-metrics to libexec * Remove PC_SAMPLING_TESTS_REGEX from CI workflow * Update packaging - core component depends on roctx component * Increase verbosity for failing tests * Fix RPATH of rocprofv3-trigger-list-metrics --------- Co-authored-by: Gopesh Bhardwaj <gopesh.bhardwaj@amd.com>
This commit is contained in:
committed by
GitHub
parent
bfe80a4428
commit
a92fa8f071
@@ -65,21 +65,4 @@ install(
|
||||
COMPONENT tools
|
||||
EXPORT rocprofiler-sdk-tool-targets)
|
||||
|
||||
add_executable(rocprofv3-trigger-list-metrics)
|
||||
target_sources(rocprofv3-trigger-list-metrics PRIVATE rocprofv3_trigger_list_metrics.cpp)
|
||||
target_link_libraries(rocprofv3-trigger-list-metrics
|
||||
PRIVATE rocprofiler-sdk::rocprofiler-hsa-runtime)
|
||||
set_target_properties(
|
||||
rocprofv3-trigger-list-metrics
|
||||
PROPERTIES RUNTIME_OUTPUT_DIRECTORY
|
||||
${PROJECT_BINARY_DIR}/${CMAKE_INSTALL_LIBDIR}/rocprofiler-sdk
|
||||
BUILD_RPATH "\$ORIGIN:\$ORIGIN/.."
|
||||
INSTALL_RPATH "\$ORIGIN:\$ORIGIN/..")
|
||||
|
||||
install(
|
||||
TARGETS rocprofv3-trigger-list-metrics
|
||||
DESTINATION ${CMAKE_INSTALL_LIBDIR}/rocprofiler-sdk
|
||||
COMPONENT tools
|
||||
EXPORT rocprofiler-sdk-tool-targets)
|
||||
|
||||
add_subdirectory(kokkosp)
|
||||
|
||||
@@ -71,14 +71,9 @@
|
||||
{ \
|
||||
std::string status_msg = \
|
||||
rocprofiler_get_status_string(ROCPROFILER_VARIABLE(CHECKSTATUS, __LINE__)); \
|
||||
std::cerr << "[" #result "][" << __FILE__ << ":" << __LINE__ << "] " << msg \
|
||||
<< " failed with error code " << ROCPROFILER_VARIABLE(CHECKSTATUS, __LINE__) \
|
||||
<< ": " << status_msg << "\n" \
|
||||
<< std::flush; \
|
||||
std::stringstream errmsg{}; \
|
||||
errmsg << "[" #result "][" << __FILE__ << ":" << __LINE__ << "] " << msg " failure (" \
|
||||
<< status_msg << ")"; \
|
||||
throw std::runtime_error(errmsg.str()); \
|
||||
ROCP_FATAL << " :: [" << __FILE__ << ":" << __LINE__ << "]\n\t" << #result << "\n\n" \
|
||||
<< msg << " failed with error code " \
|
||||
<< ROCPROFILER_VARIABLE(CHECKSTATUS, __LINE__) << ": " << status_msg; \
|
||||
} \
|
||||
}
|
||||
|
||||
|
||||
@@ -1,30 +0,0 @@
|
||||
// MIT License
|
||||
//
|
||||
// Copyright (c) 2023 Advanced Micro Devices, Inc. All rights reserved.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
// of this software and associated documentation files (the "Software"), to deal
|
||||
// in the Software without restriction, including without limitation the rights
|
||||
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
// copies of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included in all
|
||||
// copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
// SOFTWARE.
|
||||
|
||||
#include <hsa/hsa.h>
|
||||
|
||||
int
|
||||
main()
|
||||
{
|
||||
hsa_init();
|
||||
return 0;
|
||||
}
|
||||
@@ -1181,10 +1181,9 @@ list_metrics_iterate_agents(rocprofiler_agent_version_t,
|
||||
return ROCPROFILER_STATUS_SUCCESS;
|
||||
},
|
||||
reinterpret_cast<void*>(&node_id));
|
||||
if(status != ROCPROFILER_STATUS_SUCCESS)
|
||||
{
|
||||
ROCP_ERROR << "Failed to iterate counters for agent " << node_id;
|
||||
}
|
||||
|
||||
ROCP_ERROR_IF(status != ROCPROFILER_STATUS_SUCCESS)
|
||||
<< "Failed to iterate counters for agent " << node_id << " (" << agent->name << ")";
|
||||
}
|
||||
return ROCPROFILER_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user