LLVM 20.0.0git
Macros | Functions | Variables
CallBrPrepare.cpp File Reference
#include "llvm/CodeGen/CallBrPrepare.h"
#include "llvm/ADT/ArrayRef.h"
#include "llvm/ADT/SmallPtrSet.h"
#include "llvm/ADT/SmallVector.h"
#include "llvm/ADT/iterator.h"
#include "llvm/Analysis/CFG.h"
#include "llvm/CodeGen/Passes.h"
#include "llvm/IR/BasicBlock.h"
#include "llvm/IR/Dominators.h"
#include "llvm/IR/Function.h"
#include "llvm/IR/IRBuilder.h"
#include "llvm/IR/Instructions.h"
#include "llvm/IR/IntrinsicInst.h"
#include "llvm/IR/Intrinsics.h"
#include "llvm/InitializePasses.h"
#include "llvm/Pass.h"
#include "llvm/Transforms/Utils/BasicBlockUtils.h"
#include "llvm/Transforms/Utils/SSAUpdater.h"

Go to the source code of this file.

Macros

#define DEBUG_TYPE   "callbr-prepare"
 

Functions

static bool SplitCriticalEdges (ArrayRef< CallBrInst * > CBRs, DominatorTree &DT)
 
static bool InsertIntrinsicCalls (ArrayRef< CallBrInst * > CBRs, DominatorTree &DT)
 
static void UpdateSSA (DominatorTree &DT, CallBrInst *CBR, CallInst *Intrinsic, SSAUpdater &SSAUpdate)
 
static SmallVector< CallBrInst *, 2 > FindCallBrs (Function &Fn)
 
 INITIALIZE_PASS_BEGIN (CallBrPrepare, "callbrprepare", "Prepare callbr", false, false) INITIALIZE_PASS_END(CallBrPrepare
 
static bool IsInSameBasicBlock (const Use &U, const BasicBlock *BB)
 
static void PrintDebugDomInfo (const DominatorTree &DT, const Use &U, const BasicBlock *BB, bool IsDefaultDest)
 

Variables

 callbrprepare
 
Prepare callbr
 
Prepare false
 

Macro Definition Documentation

◆ DEBUG_TYPE

#define DEBUG_TYPE   "callbr-prepare"

Definition at line 55 of file CallBrPrepare.cpp.

Function Documentation

◆ FindCallBrs()

SmallVector< CallBrInst *, 2 > FindCallBrs ( Function Fn)
static

◆ INITIALIZE_PASS_BEGIN()

INITIALIZE_PASS_BEGIN ( CallBrPrepare  ,
"callbrprepare"  ,
"Prepare callbr"  ,
false  ,
false   
)

◆ InsertIntrinsicCalls()

bool InsertIntrinsicCalls ( ArrayRef< CallBrInst * >  CBRs,
DominatorTree DT 
)
static

◆ IsInSameBasicBlock()

static bool IsInSameBasicBlock ( const Use U,
const BasicBlock BB 
)
static

Definition at line 167 of file CallBrPrepare.cpp.

References I.

Referenced by UpdateSSA().

◆ PrintDebugDomInfo()

static void PrintDebugDomInfo ( const DominatorTree DT,
const Use U,
const BasicBlock BB,
bool  IsDefaultDest 
)
static

◆ SplitCriticalEdges()

bool SplitCriticalEdges ( ArrayRef< CallBrInst * >  CBRs,
DominatorTree DT 
)
static

◆ UpdateSSA()

void UpdateSSA ( DominatorTree DT,
CallBrInst CBR,
CallInst Intrinsic,
SSAUpdater SSAUpdate 
)
static

Variable Documentation

◆ callbr

Prepare callbr

Definition at line 100 of file CallBrPrepare.cpp.

◆ callbrprepare

callbrprepare

Definition at line 100 of file CallBrPrepare.cpp.

◆ false

Prepare false

Definition at line 100 of file CallBrPrepare.cpp.