[rocprof-sys] Use fmt APIs to construct strings instead of JOIN (#2643)

## Motivation

With the introduction of the new logging system base on `spdlog` library, opportunity shows to replace `timemory` dependent JOIN implementation with `fmt` library `format` and `join` APIs, which are shipped as a part of `spdlog` lib

## Technical Details

Use `fmt` provided APIs to properly format and package strings.
This commit is contained in:
marantic-amd
2026-01-23 06:34:58 +01:00
committed by GitHub
parent 3318c540ea
commit 956a73c4c8
38 changed files with 356 additions and 357 deletions
@@ -173,15 +173,15 @@ thread_init()
{
LOG_CRITICAL("thread setup failed. thread info not initialized: {}",
[&_tinfo]() {
if(_tinfo) return JOIN("", *_tinfo);
if(_tinfo) return _tinfo->as_string();
return std::string{ "no thread_info" };
}());
std::exit(1);
}
if(_tidx > 0) threading::set_thread_name(JOIN(" ", "Thread", _tidx).c_str());
if(_tidx > 0) threading::set_thread_name(fmt::format("Thread {}", _tidx).c_str());
thread_data<thread_bundle_t>::construct(
JOIN('/', "rocprofsys/process", process::get_id(), "thread", _tidx),
fmt::format("rocprofsys/process/{}/thread/{}", process::get_id(), _tidx),
quirk::config<quirk::auto_start>{});
// save the hash maps
get_timemory_hash_ids(_tidx) = tim::get_hash_ids();