|
LLVM 22.0.0git
|
#include "llvm/Support/DebugCounter.h"
Classes | |
| class | CounterInfo |
| Struct to store counter info. More... | |
| struct | CounterState |
Public Member Functions | |
| LLVM_ABI void | push_back (const std::string &) |
| LLVM_DUMP_METHOD void | dump () const |
| LLVM_ABI void | print (raw_ostream &OS) const |
| CounterInfo * | getCounterInfo (StringRef Name) const |
| unsigned int | getNumCounters () const |
| std::pair< StringRef, StringRef > | getCounterDesc (CounterInfo *Info) const |
| MapVector< StringRef, CounterInfo * >::const_iterator | begin () const |
| MapVector< StringRef, CounterInfo * >::const_iterator | end () const |
| void | activateAllCounters () |
Static Public Member Functions | |
| static LLVM_ABI void | printChunks (raw_ostream &OS, ArrayRef< IntegerInclusiveInterval > Intervals) |
| static LLVM_ABI bool | parseChunks (StringRef Str, IntegerInclusiveIntervalUtils::IntervalList &Res) |
| Return true on parsing error and print the error message on the llvm::errs() | |
| static LLVM_ABI DebugCounter & | instance () |
| Returns a reference to the singleton instance. | |
| static void | registerCounter (CounterInfo *Info) |
| static LLVM_ABI bool | shouldExecuteImpl (CounterInfo &Counter) |
| static bool | shouldExecute (CounterInfo &Counter) |
| static bool | isCounterSet (CounterInfo &Info) |
| static CounterState | getCounterState (CounterInfo &Info) |
| static void | setCounterState (CounterInfo &Info, CounterState State) |
Protected Member Functions | |
| void | addCounter (CounterInfo *Info) |
| bool | handleCounterIncrement (CounterInfo &Info) |
Protected Attributes | |
| MapVector< StringRef, CounterInfo * > | Counters |
| bool | ShouldPrintCounter = false |
| bool | ShouldPrintCounterQueries = false |
| bool | BreakOnLast = false |
Definition at line 58 of file DebugCounter.h.
|
inline |
Definition at line 163 of file DebugCounter.h.
|
inlineprotected |
Definition at line 169 of file DebugCounter.h.
References Counters, and Info.
Referenced by registerCounter().
|
inline |
Definition at line 156 of file DebugCounter.h.
References Counters.
| LLVM_DUMP_METHOD void DebugCounter::dump | ( | ) | const |
Definition at line 197 of file DebugCounter.cpp.
References llvm::dbgs(), LLVM_DUMP_METHOD, and print().
|
inline |
Definition at line 159 of file DebugCounter.h.
References Counters.
|
inline |
Definition at line 151 of file DebugCounter.h.
References Info.
|
inline |
Definition at line 143 of file DebugCounter.h.
References Counters.
Referenced by print(), and push_back().
|
inlinestatic |
Definition at line 124 of file DebugCounter.h.
References Info.
|
inline |
Definition at line 148 of file DebugCounter.h.
References Counters.
|
protected |
Handle consecutive blocks.
Definition at line 161 of file DebugCounter.cpp.
References BreakOnLast, and LLVM_BUILTIN_DEBUGTRAP.
|
static |
Returns a reference to the singleton instance.
Definition at line 113 of file DebugCounter.cpp.
References Owner.
Referenced by llvm::initDebugCounterOptions(), registerCounter(), and shouldExecuteImpl().
|
inlinestatic |
Definition at line 116 of file DebugCounter.h.
References Info.
|
static |
Return true on parsing error and print the error message on the llvm::errs()
References LLVM_ABI.
| void DebugCounter::print | ( | raw_ostream & | OS | ) | const |
Definition at line 148 of file DebugCounter.cpp.
References llvm::CallingConv::C, Counters, getCounterInfo(), llvm::left_justify(), printChunks(), and llvm::sort().
Referenced by dump().
|
static |
Definition at line 13 of file DebugCounter.cpp.
References llvm::IntegerInclusiveIntervalUtils::printIntervals().
Referenced by print().
| void DebugCounter::push_back | ( | const std::string & | Val | ) |
Definition at line 117 of file DebugCounter.cpp.
References llvm::errs(), getCounterInfo(), llvm::handleAllErrors(), llvm::IntegerInclusiveIntervalUtils::parseIntervals(), and llvm::StringRef::split().
|
inlinestatic |
Definition at line 102 of file DebugCounter.h.
References addCounter(), Info, and instance().
Referenced by llvm::DebugCounter::CounterInfo::CounterInfo().
|
inlinestatic |
Definition at line 129 of file DebugCounter.h.
References Info.
|
inlinestatic |
Definition at line 107 of file DebugCounter.h.
References shouldExecuteImpl().
Referenced by checkCondition(), DCEInstruction(), findRenameRegForSameLdStRegPair(), llvm::getKnowledgeFromBundle(), llvm::Attributor::getOrCreateAAFor(), slpvectorizer::BoUpSLP::isTreeTinyAndNotFullyVectorizable(), llvm::Negator::Negate(), optimizeDivRem(), optimizeSQRT(), llvm::InstCombinerImpl::run(), and llvm::InstructionSelect::selectMachineFunction().
|
static |
Definition at line 186 of file DebugCounter.cpp.
References llvm::dbgs(), and instance().
Referenced by shouldExecute().
|
protected |
Definition at line 178 of file DebugCounter.h.
Referenced by handleCounterIncrement().
|
protected |
Definition at line 172 of file DebugCounter.h.
Referenced by activateAllCounters(), addCounter(), begin(), end(), getCounterInfo(), getNumCounters(), and print().
|
protected |
Definition at line 174 of file DebugCounter.h.
|
protected |
Definition at line 176 of file DebugCounter.h.