Proto  3.2
Namespaces | Macros | Functions
Proto_Timer.H File Reference
#include <cstdlib>
#include <vector>
#include <string>
#include <iostream>
#include <fstream>
#include <list>
#include <cstdio>
#include <cstring>
#include <sys/time.h>
#include <chrono>
Include dependency graph for Proto_Timer.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 Proto
 

Macros

#define PR_TICKS
 
#define PR_TIMER(name, tpointer)
 
#define PR_TIME(name)
 
#define PR_FLOPS(flops)   if(PR_tpointer)PR_tpointer->addFlops(flops);
 
#define PR_TIMELEAF(name)
 
#define PR_TIMERS(name)
 
#define PR_START(tpointer)
 
#define PR_STOP(tpointer)
 
#define PR_TIMER_REPORT()   ::Proto::TraceTimer::staticReport()
 
#define PR_TIMER_RESET()   ::Proto::TraceTimer::staticReset()
 
#define PR_TIMER_PRUNE(threshold)   ::Proto::TraceTimer::staticPruneTimersParentChildPercent(threshold)
 
#define PR_TIMER_SETFILE(filename)   ::Proto::TraceTimer::staticSetTimerFileName(filename);
 

Functions

unsigned long long int PR_ticks ()
 

Macro Definition Documentation

◆ PR_TICKS

#define PR_TICKS

◆ PR_TIMER

#define PR_TIMER (   name,
  tpointer 
)
Value:
const char* TimerTag_##tpointer = name ; \
::Proto::TraceTimer* tpointer = NULL ; \
if(::Proto::TraceTimer::getTID()==0) \
{ \
tpointer = ::Proto::TraceTimer::staticGetTimer(TimerTag_##tpointer) ; \
}

◆ PR_TIME

#define PR_TIME (   name)
Value:
const char* TimerTagA = name ; \
char PR_TimermutexA = 0; \
::Proto::TraceTimer* PR_tpointer = NULL; \
if(::Proto::TraceTimer::getTID()==0) \
{ \
PR_tpointer = ::Proto::TraceTimer::staticGetTimer(TimerTagA); \
} \
::Proto::AutoStart autostart(PR_tpointer, &PR_TimermutexA)

◆ PR_FLOPS

#define PR_FLOPS (   flops)    if(PR_tpointer)PR_tpointer->addFlops(flops);

◆ PR_TIMELEAF

#define PR_TIMELEAF (   name)
Value:
const char* TimerTagA = name ; \
::Proto::TraceTimer* PR_tpointer = NULL; \
if(::Proto::TraceTimer::getTID()==0) \
{ \
PR_tpointer = ::Proto::TraceTimer::staticGetTimer(TimerTagA); \
} \
::Proto::AutoStartLeaf autostart(PR_tpointer)

◆ PR_TIMERS

#define PR_TIMERS (   name)
Value:
const char* TimerTagA = name ; \
char PR_TimermutexA = 0; \
char PR_Timermutex = 0; \
::Proto::TraceTimer* PR_tpointer = NULL; \
if(::Proto::TraceTimer::getTID()==0) \
{ \
PR_tpointer = ::Proto::TraceTimer::staticGetTimer(TimerTagA); \
} \
::Proto::AutoStart autostart(PR_tpointer, &PR_TimermutexA, &PR_Timermutex)

◆ PR_START

#define PR_START (   tpointer)
Value:
if(::Proto::TraceTimer::getTID()==0) \
{ \
tpointer->start(&PR_Timermutex); \
}

◆ PR_STOP

#define PR_STOP (   tpointer)
Value:
if(::Proto::TraceTimer::getTID()==0) \
{ \
tpointer->stop(&PR_Timermutex); \
}

◆ PR_TIMER_REPORT

#define PR_TIMER_REPORT ( )    ::Proto::TraceTimer::staticReport()

◆ PR_TIMER_RESET

#define PR_TIMER_RESET ( )    ::Proto::TraceTimer::staticReset()

◆ PR_TIMER_PRUNE

#define PR_TIMER_PRUNE (   threshold)    ::Proto::TraceTimer::staticPruneTimersParentChildPercent(threshold)

◆ PR_TIMER_SETFILE

#define PR_TIMER_SETFILE (   filename)    ::Proto::TraceTimer::staticSetTimerFileName(filename);

Function Documentation

◆ PR_ticks()

unsigned long long int PR_ticks ( )
inline