|
LLVM 23.0.0git
|
#include "llvm/Transforms/IPO/Instrumentor.h"
Public Types | |
| enum | ConfigKind { PassId , PassName , PassTargetTriple , NumConfig } |
| using | ConfigTy = BaseConfigTy<ConfigKind> |
| Public Types inherited from llvm::instrumentor::InstrumentationOpportunity | |
| using | CallbackTy = std::function<bool(Value &)> |
| An optional callback that takes the value that is about to be instrumented and can return false if it should be skipped. | |
Public Member Functions | |
| ModuleIO (bool IsPRE) | |
| StringRef | getName () const override |
| Get the name of the instrumentation opportunity. | |
| void | init (InstrumentationConfig &IConf, InstrumentorIRBuilderTy &IIRB, ConfigTy *UserConfig=nullptr) |
| Public Member Functions inherited from llvm::instrumentor::InstrumentationOpportunity | |
| virtual | ~InstrumentationOpportunity () |
| InstrumentationOpportunity (const InstrumentationLocation IP) | |
Construct an opportunity with location IP. | |
| virtual Value * | instrument (Value *&V, InstrumentationConfig &IConf, InstrumentorIRBuilderTy &IIRB, InstrumentationCaches &ICaches) |
| } | |
| virtual Type * | getRetTy (LLVMContext &Ctx) const |
| Get the return type for the instrumentation runtime function. | |
| unsigned | getOpcode () const |
| Get the opcode of the instruction instrumentation opportunity. | |
| InstrumentationLocation::KindTy | getLocationKind () const |
| Get the location kind of the instrumentation opportunity. | |
| void | addCommonArgs (InstrumentationConfig &IConf, LLVMContext &Ctx, bool PassId) |
| } | |
Public Attributes | |
| ConfigTy | Config |
| Public Attributes inherited from llvm::instrumentor::InstrumentationOpportunity | |
| InstrumentationLocation | IP |
| The instrumentation location of the opportunity. | |
| SmallVector< IRTArg > | IRTArgs |
| The list of possible arguments for the instrumentation runtime function. | |
| bool | Enabled = true |
| Whether the opportunity is enabled. | |
| StringRef | Filter |
| A filter expression to be matched against runtime property values. | |
| CallbackTy | CB = nullptr |
Definition at line 711 of file Instrumentor.h.
Definition at line 724 of file Instrumentor.h.
| Enumerator | |
|---|---|
| PassId | |
| PassName | |
| PassTargetTriple | |
| NumConfig | |
Definition at line 717 of file Instrumentor.h.
|
inline |
Definition at line 712 of file Instrumentor.h.
References llvm::instrumentor::InstrumentationOpportunity::InstrumentationOpportunity().
Referenced by populate().
|
static |
Definition at line 1253 of file Instrumentor.cpp.
References llvm::cast(), llvm::instrumentor::InstrumentationConfig::getGlobalString(), llvm::Module::getName(), and llvm::GlobalValue::getParent().
Referenced by init().
|
inlineoverridevirtual |
Get the name of the instrumentation opportunity.
Implements llvm::instrumentor::InstrumentationOpportunity.
Definition at line 727 of file Instrumentor.h.
|
static |
Definition at line 1259 of file Instrumentor.cpp.
References llvm::cast(), llvm::instrumentor::InstrumentationConfig::getGlobalString(), llvm::GlobalValue::getParent(), llvm::Module::getTargetTriple(), and llvm::Triple::getTriple().
Referenced by init().
| void ModuleIO::init | ( | InstrumentationConfig & | IConf, |
| InstrumentorIRBuilderTy & | IIRB, | ||
| ConfigTy * | UserConfig = nullptr ) |
Definition at line 1237 of file Instrumentor.cpp.
References llvm::instrumentor::InstrumentationConfig::addChoice(), llvm::instrumentor::InstrumentationOpportunity::addCommonArgs(), Config, llvm::instrumentor::InstrumentorIRBuilderTy::Ctx, getModuleName(), getTargetTriple(), llvm::instrumentor::InstrumentationOpportunity::IRTArgs, PassId, PassName, PassTargetTriple, llvm::instrumentor::InstrumentorIRBuilderTy::PtrTy, and llvm::instrumentor::IRTArg::STRING.
|
inlinestatic |
Definition at line 738 of file Instrumentor.h.
References llvm::instrumentor::InstrumentationConfig::allocate(), and ModuleIO().
Referenced by llvm::instrumentor::InstrumentationConfig::populate().
| ConfigTy llvm::instrumentor::ModuleIO::Config |
Definition at line 725 of file Instrumentor.h.
Referenced by init().