|
LLVM 23.0.0git
|
Instrumentation opportunity for numeric operations. More...
#include "llvm/Transforms/IPO/Instrumentor.h"
Public Types | |
| enum | ConfigKind { PassTypeId , PassSize , PassOpcode , PassResult , ReplaceResult , PassLeft , PassRight , PassId , 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 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 |
Additional Inherited Members | |
| Static Public Attributes inherited from llvm::instrumentor::InstructionIO< Instruction::Add, Instruction::FAdd, Instruction::Sub, Instruction::FSub, Instruction::Mul, Instruction::FMul, Instruction::UDiv, Instruction::FDiv, Instruction::SDiv, Instruction::URem, Instruction::SRem, Instruction::FRem, Instruction::Shl, Instruction::LShr, Instruction::AShr, Instruction::And, Instruction::Or, Instruction::Xor, Instruction::FNeg > | |
| static constexpr std::array< unsigned, sizeof...(Opcodes)> | OpcodesArray |
Instrumentation opportunity for numeric operations.
This includes Add, FAdd, Sub, FSub, Mul, FMul, UDiv, FDiv, SDiv, URem, SRem, FRem, Shl, LShr, AShr, And, Or, Xor, and FNeg.
Definition at line 1091 of file Instrumentor.h.
Definition at line 1113 of file Instrumentor.h.
| Enumerator | |
|---|---|
| PassTypeId | |
| PassSize | |
| PassOpcode | |
| PassResult | |
| ReplaceResult | |
| PassLeft | |
| PassRight | |
| PassId | |
| NumConfig | |
Definition at line 1101 of file Instrumentor.h.
|
inline |
Definition at line 1099 of file Instrumentor.h.
Referenced by populate().
|
static |
}
Definition at line 1693 of file Instrumentor.cpp.
References llvm::cast(), and I.
Referenced by init().
|
inlineoverridevirtual |
Get the name of the instruction.
For single-opcode IOs, this defaults to the opcode name. For multi-opcode IOs, getName() MUST be overridden to provide an explicit name identifying the whole group of opcodes.
Definition at line 1116 of file Instrumentor.h.
|
static |
Definition at line 1699 of file Instrumentor.cpp.
References llvm::cast(), llvm::PoisonValue::get(), and I.
Referenced by init().
| void NumericIO::init | ( | InstrumentationConfig & | IConf, |
| InstrumentorIRBuilderTy & | IIRB, | ||
| ConfigTy * | UserConfig = nullptr ) |
Definition at line 1708 of file Instrumentor.cpp.
References llvm::instrumentor::InstrumentationConfig::addChoice(), llvm::instrumentor::InstrumentationOpportunity::addCommonArgs(), Config, llvm::instrumentor::InstrumentorIRBuilderTy::Ctx, getLeft(), llvm::instrumentor::InstrumentationOpportunity::getLocationKind(), getOpcode(), getRight(), getSize(), getTypeId(), llvm::instrumentor::InstrumentationOpportunity::getValue(), llvm::instrumentor::IRTArg::INDIRECT_HAS_SIZE, llvm::instrumentor::InstrumentationLocation::INSTRUCTION_PRE, llvm::instrumentor::InstrumentorIRBuilderTy::Int32Ty, llvm::instrumentor::InstrumentorIRBuilderTy::Int64Ty, llvm::instrumentor::InstrumentationOpportunity::IRTArgs, llvm::instrumentor::IRTArg::NONE, PassId, PassLeft, PassOpcode, PassResult, PassRight, PassSize, PassTypeId, llvm::instrumentor::IRTArg::POTENTIALLY_INDIRECT, llvm::instrumentor::IRTArg::REPLACABLE, ReplaceResult, and llvm::instrumentor::InstrumentationOpportunity::replaceValue().
|
inlinestatic |
Definition at line 1126 of file Instrumentor.h.
References llvm::instrumentor::InstrumentationConfig::allocate(), llvm::instrumentor::InstrumentationLocation::INSTRUCTION_POST, llvm::instrumentor::InstrumentationLocation::INSTRUCTION_PRE, and NumericIO().
Referenced by llvm::instrumentor::InstrumentationConfig::populate().
| ConfigTy llvm::instrumentor::NumericIO::Config |
Definition at line 1114 of file Instrumentor.h.
Referenced by init().