LLVM 22.0.0git
|
#include "llvm/Transforms/Utils/EntryExitInstrumenter.h"
#include "llvm/Analysis/GlobalsModRef.h"
#include "llvm/IR/DebugInfoMetadata.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/IR/Module.h"
#include "llvm/IR/Type.h"
#include "llvm/InitializePasses.h"
#include "llvm/TargetParser/Triple.h"
#include "llvm/Pass.h"
#include "llvm/Transforms/Utils.h"
Go to the source code of this file.
Functions | |
static void | insertCall (Function &CurFn, StringRef Func, BasicBlock::iterator InsertionPt, DebugLoc DL) |
static bool | runOnFunction (Function &F, bool PostInlining) |
INITIALIZE_PASS_BEGIN (PostInlineEntryExitInstrumenter, "post-inline-ee-instrument", "Instrument function entry/exit with calls to e.g. mcount() " "(post inlining)", false, false) INITIALIZE_PASS_END(PostInlineEntryExitInstrumenter | |
post inline ee Instrument function entry exit with calls to e g | mcount () " "(post inlining)" |
Variables | |
post inline ee | instrument |
post inline ee Instrument function entry exit with calls to e g | false |
INITIALIZE_PASS_BEGIN | ( | PostInlineEntryExitInstrumenter | , |
"post-inline-ee-instrument" | , | ||
"Instrument function entry/exit with calls to e.g. mcount() " "(post inlining)" | , | ||
false | , | ||
false | ) |
References INITIALIZE_PASS_DEPENDENCY, and INITIALIZE_PASS_END.
|
static |
Definition at line 25 of file EntryExitInstrumenter.cpp.
References llvm::Function::addFnAttr(), llvm::CallingConv::C, Call, llvm::CallInst::Create(), DL, llvm::Attribute::get(), llvm::FunctionType::get(), llvm::Type::getInt32Ty(), llvm::Intrinsic::getOrInsertDeclaration(), llvm::PointerType::getUnqual(), llvm::Type::getVoidTy(), llvm::GlobalValue::InternalLinkage, llvm::Triple::isAArch64(), llvm::Triple::isLoongArch(), llvm::Triple::isOSAIX(), llvm::Triple::isRISCV(), llvm::Triple::isSystemZ(), llvm::report_fatal_error(), and llvm::Instruction::setDebugLoc().
Referenced by runOnFunction().
Definition at line 103 of file EntryExitInstrumenter.cpp.
References Changed, DL, llvm::StringRef::empty(), F, llvm::MDNode::get(), insertCall(), llvm::isa(), and T.
Referenced by INITIALIZE_PASS(), INITIALIZE_PASS(), INITIALIZE_PASS(), llvm::ComplexDeinterleavingPass::run(), llvm::EntryExitInstrumenterPass::run(), and llvm::StraightLineStrengthReducePass::run().
Definition at line 193 of file EntryExitInstrumenter.cpp.
void FunctionInstrumenter::instrument |
Definition at line 190 of file EntryExitInstrumenter.cpp.