diff options
author | Ian Hinder <ian.hinder@aei.mpg.de> | 2011-06-02 11:13:41 +0200 |
---|---|---|
committer | Barry Wardell <barry.wardell@gmail.com> | 2011-12-14 18:26:31 +0000 |
commit | 62e741831713b64b733103efd789690c81cbf4e4 (patch) | |
tree | 88f22a4bec7f369a24cce11215359445f6d6ebb2 /Carpet/Carpet/src/Evolve.cc | |
parent | a9d7ca03a8cd7fe797167b444c77d85b1e6a3e2d (diff) |
Make Carpet timers hierarchical
This commit modifies the timer infrastructure in Carpet to generate a
tree of timers where the hierarchy reflects the call-graph of the
program. This makes it much easier to interpret the timer output than
with the previous flat structure, where it was not possible to see
which timers "contained" which others. More implementation details
are given at the top of TimerNode.hh.
Note that the Timer source and header files have been renamed as
CactusTimer and a new Timer file and object has been created. This is
because the Timer object now only provides a wrapper around the Cactus
timer mechanism which was contained in the old Timer object.
Diffstat (limited to 'Carpet/Carpet/src/Evolve.cc')
-rw-r--r-- | Carpet/Carpet/src/Evolve.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Carpet/Carpet/src/Evolve.cc b/Carpet/Carpet/src/Evolve.cc index 8337e98aa..4eb348c96 100644 --- a/Carpet/Carpet/src/Evolve.cc +++ b/Carpet/Carpet/src/Evolve.cc @@ -18,6 +18,7 @@ #include <carpet.hh> #include <Timers.hh> +#include <TimerSet.hh> @@ -82,7 +83,7 @@ namespace Carpet { cctkGH->cctk_iteration % output_timers_every == 0 and cctkGH->cctk_iteration % do_every == 0) { - TimerSet::writeData (cctkGH, timer_file); + Carpet::TimerSet::writeData (cctkGH, timer_file); } } @@ -630,6 +631,7 @@ namespace Carpet { timers_t & timers = * timersp; // Obtain timer, creating a new one if it does not yet exist + // This is no longer necessary with the new timer implementation ostringstream timernamebuf; timernamebuf << where << "::" << name; string const timername = timernamebuf.str(); |