51 unsigned Reg = O->getReg();
55 }
else if (O->isRegMask())
61 if (!O->isReg() || !O->readsReg())
63 unsigned Reg = O->getReg();
74 unsigned Reg = O->getReg();
77 if (!O->isDef() && !O->readsReg())
80 }
else if (O->isRegMask())
88 for (
const auto &LI : MBB.
liveins())
const MachineFunction * getParent() const
Return the MachineFunction containing this basic block.
bool isValid() const
Check if the iterator is at the end of the list.
iterator_range< livein_iterator > liveins() const
static void addPristines(LiveRegUnits &LiveUnits, const MachineFunction &MF)
Adds pristine registers to the given LiveUnits.
static void addBlockLiveIns(LiveRegUnits &LiveUnits, const MachineBasicBlock &MBB)
Add live-in registers of basic block MBB to LiveUnits.
iterator_range< succ_iterator > successors()
const std::vector< CalleeSavedInfo > & getCalleeSavedInfo() const
Returns a reference to call saved info vector for the current function.
void addLiveOuts(const MachineBasicBlock &MBB)
Adds registers living out of block MBB.
void removeReg(unsigned Reg)
Removes all register units covered by physical register Reg.
Reg
All possible values of the reg field in the ModR/M byte.
void addRegsInMask(const uint32_t *RegMask)
Adds register units not preserved by the regmask RegMask.
The MachineFrameInfo class represents an abstract stack frame until prolog/epilog code is inserted...
void addLiveIns(const MachineBasicBlock &MBB)
Adds registers living into block MBB.
MCRegUnitRootIterator enumerates the root registers of a register unit.
static void addCalleeSavedRegs(LiveRegUnits &LiveUnits, const MachineFunction &MF)
Adds all callee saved registers to LiveUnits.
uint16_t MCPhysReg
An unsigned integer type large enough to represent all physical registers, but not necessarily virtua...
const MCPhysReg * getCalleeSavedRegs() const
Returns list of callee saved registers.
unsigned const MachineRegisterInfo * MRI
MachineFrameInfo & getFrameInfo()
getFrameInfo - Return the frame info object for the current function.
void stepBackward(const MachineInstr &MI)
Updates liveness when stepping backwards over the instruction MI.
bool isCalleeSavedInfoValid() const
Has the callee saved info been calculated yet?
void addReg(unsigned Reg)
Adds register units covered by physical register Reg.
bool isReturnBlock() const
Convenience function that returns true if the block ends in a return instruction. ...
ConstMIBundleOperands - Iterate over all operands in a const bundle of machine instructions.
void accumulate(const MachineInstr &MI)
Adds all register units used, defined or clobbered in MI.
The CalleeSavedInfo class tracks the information need to locate where a callee saved register is in t...
static bool clobbersPhysReg(const uint32_t *RegMask, unsigned PhysReg)
clobbersPhysReg - Returns true if this RegMask clobbers PhysReg.
void addRegMasked(unsigned Reg, LaneBitmask Mask)
Adds register units covered by physical register Reg that are part of the lanemask Mask...
unsigned getNumRegUnits() const
Return the number of (native) register units in the target.
MachineRegisterInfo - Keep track of information for virtual and physical registers, including vreg register classes, use/def chains for registers, etc.
Representation of each machine instruction.
static bool isPhysicalRegister(unsigned Reg)
Return true if the specified register number is in the physical register namespace.
MachineRegisterInfo & getRegInfo()
getRegInfo - Return information about the registers currently in use.
A set of register units used to track register liveness.
bool isValid() const
isValid - Returns true until all the operands have been visited.
void removeRegsNotPreserved(const uint32_t *RegMask)
Removes register units not preserved by the regmask RegMask.