From 4f1bc8dc3fdad5385555fd1c69a61f838fc361f6 Mon Sep 17 00:00:00 2001 From: Kevin Huck Date: Mon, 24 Jun 2024 11:29:23 -0700 Subject: [PATCH] Some updates for handling Iris commands - generate unique IDs. --- src/apex/taskstubs_implementation.cpp | 4 +++- src/scripts/apex-treesummary.py | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/apex/taskstubs_implementation.cpp b/src/apex/taskstubs_implementation.cpp index 97a35091..113870bf 100644 --- a/src/apex/taskstubs_implementation.cpp +++ b/src/apex/taskstubs_implementation.cpp @@ -213,8 +213,10 @@ extern "C" { } void tasktimer_command_start_impl(const char* type_name) { + // we need to create a unique GUID for the command + static tasktimer_guid_t guid{UINT64_MAX/2}; std::string tmpstr{type_name}; - auto task = apex::new_task(tmpstr); + auto task = apex::new_task(tmpstr, guid++); timerStack(task, true); } diff --git a/src/scripts/apex-treesummary.py b/src/scripts/apex-treesummary.py index b3f3f84c..8f5b4759 100755 --- a/src/scripts/apex-treesummary.py +++ b/src/scripts/apex-treesummary.py @@ -230,7 +230,7 @@ def drawDOT(df, args, name): df.loc[df['calls'] == 0, 'bytes per call'] = df['total bytes'] metric = 'bytes per call' # Make a new dataframe from rank 0 - filename = name + 'tasktree.dot'; + filename = name.replace(' ', '-') + '-tasktree.dot'; f = open(filename, 'w') f.write('digraph prof {\n') #f.write(' label = "(get this from metadata file output - or, generate it from apex-treesummary.py!)";\n')