[rocprofv3-avail] Rework rocprofv3-avail tool (#312)

---------

Co-authored-by: vlaindic_amdeng <vladimir.indic@amd.com>
This commit is contained in:
Nagaraj, Sriraksha
2025-06-06 13:51:37 -05:00
committed by GitHub
parent a24f486732
commit 80d60d8535
24 changed files with 1672 additions and 897 deletions
+5 -5
View File
@@ -278,23 +278,23 @@ read_map(const std::string& fname)
return data;
}
auto ifs = std::ifstream{fname};
auto ifs = std::ifstream(fname);
if(!ifs || !ifs.good())
{
ROCP_CI_LOG(WARNING) << fmt::format("file '{}' cannot be read", fname);
return data;
}
auto last_label = std::string{};
while(true)
while(ifs && ifs.good())
{
auto label = std::string{};
ifs >> label;
if(ifs.eof() || label.empty()) break;
if(ifs.fail() || ifs.eof() || label.empty()) break;
auto entry = std::string{};
ifs >> entry;
if(ifs.eof())
if(ifs.fail() || ifs.eof())
{
ROCP_CI_LOG(WARNING) << fmt::format(
"unexpected file format in '{}' at {}", fname, label);