Fix init order for getMetricIdMap (#341)
* Fix init order for getMetricIdMap Ensure that getMetricIdMap() stays valid until the destruction of the counting service. Adds a test to ensure that this behavior is maintained (this test fails without this change). * source formatting (clang-format v11) (#343) Co-authored-by: bwelton <bwelton@users.noreply.github.com> * cmake formatting (cmake-format) (#342) Co-authored-by: bwelton <bwelton@users.noreply.github.com> * Remove threading * Update usage of rocprofiler::counters::get{Metric,MetricId}Map() - uses common::static_object * Update counter init_order testing --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: bwelton <bwelton@users.noreply.github.com> Co-authored-by: Jonathan R. Madsen <jonathanrmadsen@gmail.com>
此提交包含在:
1 父節點
78dd471110
當前提交
ef71cc38c1
9 file changed
+225
-15
No files matched your search
@@ -115,7 +115,7 @@ get_ast_map()
|
||||
{
|
||||
static std::unordered_map<std::string, EvaluateASTMap> ast_map = []() {
|
||||
std::unordered_map<std::string, EvaluateASTMap> data;
|
||||
const auto& metric_map = counters::getMetricMap();
|
||||
const auto& metric_map = *CHECK_NOTNULL(counters::getMetricMap());
|
||||
for(const auto& [gfx, metrics] : metric_map)
|
||||
{
|
||||
// TODO: Remove global XML from derrived counters...
|
||||
|
||||
Reference in new issue
封鎖使用者