Celeritas  0.5.0-86+4a8eea4
Functions
TraceCounter.perfetto.cc File Reference

Numeric tracing counter. More...

#include "TraceCounter.hh"
#include <type_traits>
#include <perfetto.h>
#include "corecel/Types.hh"
#include "detail/TrackEvent.perfetto.hh"

Functions

template<class T >
void celeritas::trace_counter (char const *name, T value)
 Simple performance tracing counter. More...
 
template void celeritas::trace_counter (char const *, unsigned int)
 
template void celeritas::trace_counter (char const *, std::size_t)
 
template void celeritas::trace_counter (char const *, float)
 
template void celeritas::trace_counter (char const *, double)
 

Detailed Description

Numeric tracing counter.

Function Documentation

◆ trace_counter()

template<class T >
void celeritas::trace_counter ( char const *  name,
value 
)
inline

Simple performance tracing counter.

Template Parameters
TArithmetic counter type

Records a named value at the current timestamp which can then be displayed on a timeline. Only supported on host, this compiles but is a noop on device.

See https://perfetto.dev/docs/instrumentation/track-events#counters