ExaFMM 1
Fast-multipole Method for exascale systems
Public Member Functions | Public Attributes | Private Member Functions | Private Attributes
Logger Class Reference

Timer and Trace logger. More...

#include <logger.h>

Inheritance diagram for Logger:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 Logger ()
 Constructor.
 ~Logger ()
 Destructor.
void startTimer (std::string event)
 Start timer for given event.
double stopTimer (std::string event, bool print=false)
 Stop timer for given event.
void eraseTimer (std::string event)
 Erase entry in timer.
void resetTimer ()
 Erase all events in timer.
void printTime (std::string event)
 Print timings of a specific event.
void printAllTime ()
 Print timings of all events.
void writeTime ()
 Write timings of all events.
void startTracer (ThreadTrace &beginTrace)
 Start tracer for given event.
void stopTracer (ThreadTrace &beginTrace, int color)
 Stop tracer for given event.
void writeTrace ()
 Write traces of all events.

Public Attributes

bool printNow
 Switch to print timings.

Private Member Functions

double get_time () const
 Timer function.

Private Attributes

std::ofstream timerFile
 File ID to store log.
Timer beginTimer
 Timer base value.
Timer timer
 Stores timings for all events.
Traces traces
 Stores traces for all events.
pthread_mutex_t mutex
 Pthread communicator.

Detailed Description

Timer and Trace logger.

Definition at line 28 of file logger.h.


Constructor & Destructor Documentation

Logger::Logger ( ) [inline]

Constructor.

Definition at line 47 of file logger.h.

Logger::~Logger ( ) [inline]

Destructor.

Definition at line 53 of file logger.h.


Member Function Documentation

void Logger::eraseTimer ( std::string  event) [inline]

Erase entry in timer.

Definition at line 71 of file logger.h.

Here is the caller graph for this function:

double Logger::get_time ( ) const [inline, private]

Timer function.

Definition at line 37 of file logger.h.

Here is the caller graph for this function:

void Logger::printAllTime ( ) [inline]

Print timings of all events.

Definition at line 86 of file logger.h.

void Logger::printTime ( std::string  event) [inline]

Print timings of a specific event.

Definition at line 81 of file logger.h.

void Logger::resetTimer ( ) [inline]

Erase all events in timer.

Definition at line 76 of file logger.h.

Here is the caller graph for this function:

void Logger::startTimer ( std::string  event) [inline]

Start timer for given event.

Definition at line 58 of file logger.h.

Here is the call graph for this function:

Here is the caller graph for this function:

void Logger::startTracer ( ThreadTrace beginTrace) [inline]

Start tracer for given event.

Definition at line 100 of file logger.h.

Here is the call graph for this function:

double Logger::stopTimer ( std::string  event,
bool  print = false 
) [inline]

Stop timer for given event.

Definition at line 63 of file logger.h.

Here is the call graph for this function:

Here is the caller graph for this function:

void Logger::stopTracer ( ThreadTrace beginTrace,
int  color 
) [inline]

Stop tracer for given event.

Definition at line 107 of file logger.h.

Here is the call graph for this function:

void Logger::writeTime ( ) [inline]

Write timings of all events.

Definition at line 93 of file logger.h.

Here is the caller graph for this function:

void Logger::writeTrace ( ) [inline]

Write traces of all events.

Definition at line 119 of file logger.h.

Here is the caller graph for this function:


Member Data Documentation

Timer base value.

Definition at line 31 of file logger.h.

pthread_mutex_t Logger::mutex [private]

Pthread communicator.

Definition at line 34 of file logger.h.

Switch to print timings.

Definition at line 44 of file logger.h.

Timer Logger::timer [private]

Stores timings for all events.

Definition at line 32 of file logger.h.

std::ofstream Logger::timerFile [private]

File ID to store log.

Definition at line 30 of file logger.h.

Stores traces for all events.

Definition at line 33 of file logger.h.


The documentation for this class was generated from the following file:
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Defines