LLVM  4.0.0
Public Member Functions | Public Attributes | Protected Member Functions | List of all members
llvm::Statistic Class Reference

#include <Statistic.h>

Collaboration diagram for llvm::Statistic:
[legend]

Public Member Functions

unsigned getValue () const
 
const char * getDebugType () const
 
const char * getName () const
 
const char * getDesc () const
 
void construct (const char *debugtype, const char *name, const char *desc)
 construct - This should only be called for non-global statistics. More...
 
 operator unsigned () const
 
const Statisticoperator= (unsigned Val)
 
const Statisticoperator++ ()
 
unsigned operator++ (int)
 
const Statisticoperator-- ()
 
unsigned operator-- (int)
 
const Statisticoperator+= (unsigned V)
 
const Statisticoperator-= (unsigned V)
 

Public Attributes

const char * DebugType
 
const char * Name
 
const char * Desc
 
std::atomic< unsignedValue
 
bool Initialized
 

Protected Member Functions

Statisticinit ()
 
void RegisterStatistic ()
 RegisterStatistic - The first time a statistic is bumped, this method is called. More...
 

Detailed Description

Definition at line 39 of file Statistic.h.

Member Function Documentation

void llvm::Statistic::construct ( const char *  debugtype,
const char *  name,
const char *  desc 
)
inline

construct - This should only be called for non-global statistics.

Definition at line 53 of file Statistic.h.

References DebugType, Desc, Initialized, Name, and name.

const char* llvm::Statistic::getDebugType ( ) const
inline

Definition at line 48 of file Statistic.h.

References DebugType.

Referenced by llvm::PrintStatisticsJSON().

const char* llvm::Statistic::getDesc ( ) const
inline

Definition at line 50 of file Statistic.h.

References Desc.

const char* llvm::Statistic::getName ( ) const
inline

Definition at line 49 of file Statistic.h.

References Name.

Referenced by llvm::PrintStatisticsJSON().

unsigned llvm::Statistic::getValue ( ) const
inline

Definition at line 47 of file Statistic.h.

Referenced by operator unsigned(), and llvm::PrintStatisticsJSON().

Statistic& llvm::Statistic::init ( )
inlineprotected
llvm::Statistic::operator unsigned ( ) const
inline

Definition at line 62 of file Statistic.h.

References getValue().

const Statistic& llvm::Statistic::operator++ ( )
inline

Definition at line 70 of file Statistic.h.

References init().

unsigned llvm::Statistic::operator++ ( int  )
inline

Definition at line 75 of file Statistic.h.

References init().

const Statistic& llvm::Statistic::operator+= ( unsigned  V)
inline

Definition at line 90 of file Statistic.h.

References init().

const Statistic& llvm::Statistic::operator-- ( )
inline

Definition at line 80 of file Statistic.h.

References init().

unsigned llvm::Statistic::operator-- ( int  )
inline

Definition at line 85 of file Statistic.h.

References init().

const Statistic& llvm::Statistic::operator-= ( unsigned  V)
inline

Definition at line 97 of file Statistic.h.

References init().

const Statistic& llvm::Statistic::operator= ( unsigned  Val)
inline

Definition at line 65 of file Statistic.h.

References init().

void Statistic::RegisterStatistic ( )
protected

RegisterStatistic - The first time a statistic is bumped, this method is called.

Definition at line 79 of file Statistic.cpp.

References Enabled, Initialized, llvm::sys::MemoryFence(), StatInfo, StatLock, Stats, TsanHappensBefore, TsanIgnoreWritesBegin, and TsanIgnoreWritesEnd.

Referenced by init().

Member Data Documentation

const char* llvm::Statistic::DebugType

Definition at line 41 of file Statistic.h.

Referenced by construct(), and getDebugType().

const char* llvm::Statistic::Desc

Definition at line 43 of file Statistic.h.

Referenced by construct(), and getDesc().

bool llvm::Statistic::Initialized

Definition at line 45 of file Statistic.h.

Referenced by construct(), init(), and RegisterStatistic().

const char* llvm::Statistic::Name

Definition at line 42 of file Statistic.h.

Referenced by construct(), and getName().

std::atomic<unsigned> llvm::Statistic::Value

Definition at line 44 of file Statistic.h.


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