LLVM  6.0.0svn
Classes | Public Types | Static Public Member Functions | List of all members
llvm::SSAUpdaterTraits< MachineSSAUpdater > Class Template Reference

Classes

class  PHI_iterator
 Iterator for PHI operands. More...
 

Public Types

using BlkT = MachineBasicBlock
 
using ValT = unsigned
 
using PhiT = MachineInstr
 
using BlkSucc_iterator = MachineBasicBlock::succ_iterator
 

Static Public Member Functions

static BlkSucc_iterator BlkSucc_begin (BlkT *BB)
 
static BlkSucc_iterator BlkSucc_end (BlkT *BB)
 
static PHI_iterator PHI_begin (PhiT *PHI)
 
static PHI_iterator PHI_end (PhiT *PHI)
 
static void FindPredecessorBlocks (MachineBasicBlock *BB, SmallVectorImpl< MachineBasicBlock *> *Preds)
 FindPredecessorBlocks - Put the predecessors of BB into the Preds vector. More...
 
static unsigned GetUndefVal (MachineBasicBlock *BB, MachineSSAUpdater *Updater)
 GetUndefVal - Create an IMPLICIT_DEF instruction with a new register. More...
 
static unsigned CreateEmptyPHI (MachineBasicBlock *BB, unsigned NumPreds, MachineSSAUpdater *Updater)
 CreateEmptyPHI - Create a PHI instruction that defines a new register. More...
 
static void AddPHIOperand (MachineInstr *PHI, unsigned Val, MachineBasicBlock *Pred)
 AddPHIOperand - Add the specified value as an operand of the PHI for the specified predecessor block. More...
 
static MachineInstrInstrIsPHI (MachineInstr *I)
 InstrIsPHI - Check if an instruction is a PHI. More...
 
static MachineInstrValueIsPHI (unsigned Val, MachineSSAUpdater *Updater)
 ValueIsPHI - Check if the instruction that defines the specified register is a PHI instruction. More...
 
static MachineInstrValueIsNewPHI (unsigned Val, MachineSSAUpdater *Updater)
 ValueIsNewPHI - Like ValueIsPHI but also check if the PHI has no source operands, i.e., it was just added. More...
 
static unsigned GetPHIValue (MachineInstr *PHI)
 GetPHIValue - For the specified PHI instruction, return the register that it defines. More...
 

Detailed Description

template<>
class llvm::SSAUpdaterTraits< MachineSSAUpdater >

Definition at line 242 of file MachineSSAUpdater.cpp.

Member Typedef Documentation

◆ BlkSucc_iterator

Definition at line 247 of file MachineSSAUpdater.cpp.

◆ BlkT

Definition at line 244 of file MachineSSAUpdater.cpp.

◆ PhiT

Definition at line 246 of file MachineSSAUpdater.cpp.

◆ ValT

Definition at line 245 of file MachineSSAUpdater.cpp.

Member Function Documentation

◆ AddPHIOperand()

static void llvm::SSAUpdaterTraits< MachineSSAUpdater >::AddPHIOperand ( MachineInstr PHI,
unsigned  Val,
MachineBasicBlock Pred 
)
inlinestatic

AddPHIOperand - Add the specified value as an operand of the PHI for the specified predecessor block.

Definition at line 315 of file MachineSSAUpdater.cpp.

References llvm::MachineInstrBuilder::addMBB(), and llvm::MachineBasicBlock::getParent().

◆ BlkSucc_begin()

static BlkSucc_iterator llvm::SSAUpdaterTraits< MachineSSAUpdater >::BlkSucc_begin ( BlkT BB)
inlinestatic

Definition at line 249 of file MachineSSAUpdater.cpp.

References llvm::MachineBasicBlock::succ_begin().

◆ BlkSucc_end()

static BlkSucc_iterator llvm::SSAUpdaterTraits< MachineSSAUpdater >::BlkSucc_end ( BlkT BB)
inlinestatic

Definition at line 250 of file MachineSSAUpdater.cpp.

References llvm::MachineBasicBlock::succ_end().

◆ CreateEmptyPHI()

static unsigned llvm::SSAUpdaterTraits< MachineSSAUpdater >::CreateEmptyPHI ( MachineBasicBlock BB,
unsigned  NumPreds,
MachineSSAUpdater Updater 
)
inlinestatic

CreateEmptyPHI - Create a PHI instruction that defines a new register.

Add it into the specified block and return the register.

Definition at line 304 of file MachineSSAUpdater.cpp.

References llvm::MachineBasicBlock::begin(), llvm::MachineBasicBlock::empty(), llvm::MachineBasicBlock::end(), llvm::MachineInstr::getOperand(), llvm::MachineOperand::getReg(), and InsertNewDef().

◆ FindPredecessorBlocks()

static void llvm::SSAUpdaterTraits< MachineSSAUpdater >::FindPredecessorBlocks ( MachineBasicBlock BB,
SmallVectorImpl< MachineBasicBlock *> *  Preds 
)
inlinestatic

FindPredecessorBlocks - Put the predecessors of BB into the Preds vector.

Definition at line 283 of file MachineSSAUpdater.cpp.

References E, llvm::MachineBasicBlock::pred_begin(), llvm::MachineBasicBlock::pred_end(), and llvm::SmallVectorTemplateBase< T, isPodLike< T >::value >::push_back().

◆ GetPHIValue()

static unsigned llvm::SSAUpdaterTraits< MachineSSAUpdater >::GetPHIValue ( MachineInstr PHI)
inlinestatic

GetPHIValue - For the specified PHI instruction, return the register that it defines.

Definition at line 344 of file MachineSSAUpdater.cpp.

References getAvailableVals(), llvm::MachineInstr::getOperand(), llvm::MachineOperand::getReg(), and llvm::SSAUpdaterImpl< UpdaterT >::GetValue().

◆ GetUndefVal()

static unsigned llvm::SSAUpdaterTraits< MachineSSAUpdater >::GetUndefVal ( MachineBasicBlock BB,
MachineSSAUpdater Updater 
)
inlinestatic

GetUndefVal - Create an IMPLICIT_DEF instruction with a new register.

Add it into the specified block and return the register.

Definition at line 292 of file MachineSSAUpdater.cpp.

References llvm::MachineBasicBlock::getFirstTerminator(), llvm::MachineInstr::getOperand(), llvm::MachineOperand::getReg(), and InsertNewDef().

◆ InstrIsPHI()

static MachineInstr* llvm::SSAUpdaterTraits< MachineSSAUpdater >::InstrIsPHI ( MachineInstr I)
inlinestatic

InstrIsPHI - Check if an instruction is a PHI.

Definition at line 321 of file MachineSSAUpdater.cpp.

References llvm::MachineInstr::isPHI().

◆ PHI_begin()

static PHI_iterator llvm::SSAUpdaterTraits< MachineSSAUpdater >::PHI_begin ( PhiT PHI)
inlinestatic

Definition at line 275 of file MachineSSAUpdater.cpp.

◆ PHI_end()

static PHI_iterator llvm::SSAUpdaterTraits< MachineSSAUpdater >::PHI_end ( PhiT PHI)
inlinestatic

Definition at line 277 of file MachineSSAUpdater.cpp.

◆ ValueIsNewPHI()

static MachineInstr* llvm::SSAUpdaterTraits< MachineSSAUpdater >::ValueIsNewPHI ( unsigned  Val,
MachineSSAUpdater Updater 
)
inlinestatic

ValueIsNewPHI - Like ValueIsPHI but also check if the PHI has no source operands, i.e., it was just added.

Definition at line 335 of file MachineSSAUpdater.cpp.

References llvm::MachineInstr::getNumOperands().

◆ ValueIsPHI()

static MachineInstr* llvm::SSAUpdaterTraits< MachineSSAUpdater >::ValueIsPHI ( unsigned  Val,
MachineSSAUpdater Updater 
)
inlinestatic

ValueIsPHI - Check if the instruction that defines the specified register is a PHI instruction.

Definition at line 329 of file MachineSSAUpdater.cpp.

References llvm::MachineRegisterInfo::getVRegDef().


The documentation for this class was generated from the following file: