Zth (libzth)
zth::Backtrace Class Reference

Save a backtrace. More...

#include <perf.h>

Public Types

typedef vector_type< void * >::type bt_type
 

Public Member Functions

 Backtrace (size_t skip=0, size_t maxDepth=128)
 
Fiberfiber () const noexcept
 
uint64_t fiberId () const noexcept
 
bt_type const & bt () const noexcept
 
bool truncated () const noexcept
 
Timestamp const & t0 () const noexcept
 
Timestamp const & t1 () const noexcept
 
void printPartial (size_t start, ssize_t end=-1, int color=-1) const
 
void print (int color=-1) const
 
void printDelta (Backtrace const &other, int color=-1) const
 

Detailed Description

Save a backtrace.

Examples
5_perf.cpp.

Definition at line 52 of file perf.h.

Member Typedef Documentation

◆ bt_type

typedef vector_type<void*>::type zth::Backtrace::bt_type

Definition at line 55 of file perf.h.

Constructor & Destructor Documentation

◆ Backtrace()

zth::Backtrace::Backtrace ( size_t  skip = 0,
size_t  maxDepth = 128 
)
explicit

Definition at line 509 of file perf.cpp.

Member Function Documentation

◆ bt()

bt_type const& zth::Backtrace::bt ( ) const
inlinenoexcept

Definition at line 68 of file perf.h.

◆ fiber()

Fiber* zth::Backtrace::fiber ( ) const
inlinenoexcept

Definition at line 58 of file perf.h.

◆ fiberId()

uint64_t zth::Backtrace::fiberId ( ) const
inlinenoexcept

Definition at line 63 of file perf.h.

◆ print()

void zth::Backtrace::print ( int  color = -1) const
Examples
5_perf.cpp.

Definition at line 651 of file perf.cpp.

◆ printDelta()

void zth::Backtrace::printDelta ( Backtrace const &  other,
int  color = -1 
) const
Examples
5_perf.cpp.

Definition at line 667 of file perf.cpp.

◆ printPartial()

void zth::Backtrace::printPartial ( size_t  start,
ssize_t  end = -1,
int  color = -1 
) const

Definition at line 562 of file perf.cpp.

◆ t0()

Timestamp const& zth::Backtrace::t0 ( ) const
inlinenoexcept

Definition at line 78 of file perf.h.

◆ t1()

Timestamp const& zth::Backtrace::t1 ( ) const
inlinenoexcept

Definition at line 83 of file perf.h.

◆ truncated()

bool zth::Backtrace::truncated ( ) const
inlinenoexcept

Definition at line 73 of file perf.h.


The documentation for this class was generated from the following files: