[rocprofiler-systems] Add cached demangler and replace old demangle (#2135)

* Add cached demangler and replace old

* Add unit tests

* Applied suggestions from code review

* Applied suggestions from code review
This commit is contained in:
Milan Radosavljevic
2025-12-16 08:32:18 +01:00
committed by GitHub
parent 21afa807a9
commit 666e76deac
27 changed files with 450 additions and 84 deletions
@@ -29,6 +29,8 @@
#include <timemory/components/timing/wall_clock.hpp>
#include <timemory/utility/join.hpp>
#include "core/demangler.hpp"
#include <algorithm>
#include <link.h>
#include <linux/limits.h>
@@ -893,7 +895,8 @@ process_modules(const std::vector<module_t*>& _app_modules)
for(auto* fitr : symtab_data.functions.at(itr))
{
symtab_data.typed_func_names[tim::demangle(fitr->getName())] = fitr;
symtab_data.typed_func_names[rocprofsys::utility::demangle(fitr->getName())] =
fitr;
symtab_data.symbols.emplace(fitr, std::vector<symtab_symbol_t*>{});
if(!fitr->getSymbols(symtab_data.symbols.at(fitr))) continue;
@@ -906,7 +909,6 @@ process_modules(const std::vector<module_t*>& _app_modules)
}
}
}
_pr.stop();
_wc.stop();
verbprintf(0, "Processing %zu modules... Done (%.3f %s, %.3f %s)\n",