LLVM API Documentation
#include "llvm/CodeGen/Passes.h"
#include "llvm/CodeGen/MachineFunctionPass.h"
#include "llvm/Target/TargetInstrInfo.h"
#include "llvm/Target/TargetMachine.h"
#include "llvm/ADT/STLExtras.h"
Include dependency graph for BranchFolding.cpp:
Go to the source code of this file.
Functions | |
FunctionPass * | llvm::createBranchFoldingPass () |
static void | ReplaceUsesOfBlockWith (MachineBasicBlock *BB, MachineBasicBlock *Old, MachineBasicBlock *New, const TargetInstrInfo &TII) |
|
ReplaceUsesOfBlockWith - Given a machine basic block 'BB' that branched to 'Old', change the code and CFG so that it branches to 'New' instead. Definition at line 78 of file BranchFolding.cpp. References llvm::MachineBasicBlock::addSuccessor(), llvm::MachineBasicBlock::begin(), llvm::MachineFunction::end(), llvm::MachineBasicBlock::end(), llvm::MachineBasicBlock::getParent(), I, llvm::TargetInstrInfo::insertGoto(), llvm::TargetInstrInfo::isTerminatorInstr(), llvm::MachineBasicBlock::removeSuccessor(), llvm::MachineBasicBlock::succ_begin(), and llvm::MachineBasicBlock::succ_end(). |