15 #ifndef LLVM_CODEGEN_LIVEREGUNITS_H
16 #define LLVM_CODEGEN_LIVEREGUNITS_H
27 class MachineBasicBlock;
67 if (UnitMask.
none() || (UnitMask &
Mask).any())
68 Units.
set((*Unit).first);
120 Units.
reset(RegUnits);
130 #endif // LLVM_CODEGEN_LIVEREGUNITS_H
void resize(unsigned N, bool t=false)
resize - Grow or shrink the bitvector.
A common definition of LaneBitmask for use in TableGen and CodeGen.
bool available(unsigned Reg) const
Returns true if no part of physical register Reg is live.
void removeUnits(const BitVector &RegUnits)
Removes all register units marked in the bitvector RegUnits.
MCRegUnitMaskIterator enumerates a list of register units and their associated lane masks for Reg...
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.
void addLiveIns(const MachineBasicBlock &MBB)
Adds registers living into block MBB.
void init(const TargetRegisterInfo &TRI)
Initialize and clear the set.
constexpr bool none() const
bool empty() const
empty - Tests whether there are no bits in this bitvector.
void stepBackward(const MachineInstr &MI)
Updates liveness when stepping backwards over the instruction MI.
void addUnits(const BitVector &RegUnits)
Adds all register units marked in the bitvector RegUnits.
void addReg(unsigned Reg)
Adds register units covered by physical register Reg.
TargetRegisterInfo base class - We assume that the target defines a static array of TargetRegisterDes...
bool test(unsigned Idx) const
void accumulate(const MachineInstr &MI)
Adds all register units used, defined or clobbered in MI.
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.
Representation of each machine instruction.
LiveRegUnits()=default
Constructs a new empty LiveRegUnits set.
void clear()
Clears the set.
A set of register units used to track register liveness.
bool empty() const
Returns true if the set is empty.
std::vector< uint8_t > Unit
void removeRegsNotPreserved(const uint32_t *RegMask)
Removes register units not preserved by the regmask RegMask.
const BitVector & getBitVector() const
Return the internal bitvector representation of the set.
std::underlying_type< E >::type Mask()
Get a bitmask with 1s in all places up to the high-order bit of E's largest value.
LiveRegUnits(const TargetRegisterInfo &TRI)
Constructs and initialize an empty LiveRegUnits set.