Profiler.h¶
-
class
Cubism::Util::Profiler: public Cubism::Util::Sampler Runtime profiler.
Used to collect runtime samples for a code section that is enclosed by the
push()andpop()methods. Used for profiling.Public Functions
-
inline
Profiler(const std::string &name = "default", const MPI_Comm comm = MPI_COMM_WORLD)¶ Main constructor.
- Parameters
name: Name of the profilercomm: MPI communicator associated to the profiler
-
inline void
push(const std::string &name)¶ Push a new profiling agent on the stack.
Starts a timer for a new profiling agent.
- Parameters
name: Name of the agent
-
inline void
pop()¶ Pop the top profiling agent.
Pops the top (most recent) profiling agent from the stack and collects the time measurement.
-
void
printReport()¶ Print profiling report to standard output.
-
inline