Skip to content

Commit

Permalink
Fixing tasktree processing for non-timers, adding to apex_exec script
Browse files Browse the repository at this point in the history
  • Loading branch information
khuck committed Apr 2, 2021
1 parent 95cd5b4 commit 9c120d4
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/apex/apex.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1999,7 +1999,9 @@ extern "C" {
}

static void apex_finalize_static_void(void) {
#if !defined(APEX_HAVE_MPI)
finalize();
#endif
}

void apex_finalize_() { finalize(); }
Expand Down
2 changes: 1 addition & 1 deletion src/apex/profiler_listener.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ std::unordered_set<profile*> free_profiles;
}
}
#endif
if (apex_options::use_tasktree_output()) {
if (apex_options::use_tasktree_output() && !p->is_counter) {
p->tt_ptr->tree_node->addAccumulated(p->elapsed(), p->is_resume);
}
return 1;
Expand Down
4 changes: 2 additions & 2 deletions src/apex/profiler_listener.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,15 +72,15 @@ class profiler_queue_t : public ConcurrentQueue<std::shared_ptr<profiler> > {
public:
profiler_queue_t() {}
virtual ~profiler_queue_t() {
finalize();
//finalize();
}
};

class dependency_queue_t : public ConcurrentQueue<task_dependency*> {
public:
dependency_queue_t() {}
virtual ~dependency_queue_t() {
finalize();
//finalize();
}
};

Expand Down
13 changes: 13 additions & 0 deletions src/scripts/apex_exec
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ where APEX options are zero or more of:
--apex:tau enable tau profile output
--apex:taskgraph enable taskgraph output
(graphviz required for post-processing)
--apex:tasktree enable tasktree output
(graphviz required for post-processing)
--apex:otf2 enable OTF2 trace output
--apex:otf2path specify location of OTF2 archive
(default: ./OTF2_archive)
Expand Down Expand Up @@ -68,6 +70,7 @@ otf2=no
gtrace=no
scatter=no
taskgraph=no
tasktree=no
screen=yes
csv=no
tau=no
Expand Down Expand Up @@ -143,6 +146,11 @@ while (( "$#" )); do
export APEX_TASKGRAPH_OUTPUT=1
shift
;;
--apex:tasktree)
tasktree=yes
export APEX_TASKTREE_OUTPUT=1
shift
;;
--apex:screen)
screen=yes
shift
Expand Down Expand Up @@ -355,3 +363,8 @@ if [ ${taskgraph} = yes ] ; then
dot -Tpdf -O taskgraph.0.dot
fi

if [ ${tasktree} = yes ] ; then
echo "Generating tasktree with GraphViz..."
dot -Tpdf -O tasktree.0.dot
fi

0 comments on commit 9c120d4

Please sign in to comment.