LLVM 23.0.0git
llvm::LivenessInfo Class Reference

Class to track incremental liveness update. More...

#include "Target/Hexagon/HexagonGlobalRegion.h"

Public Member Functions

 LivenessInfo (const TargetInstrInfo *TII, const TargetRegisterInfo *TRI, MachineBasicBlock *MBB)
 ~LivenessInfo ()
void parseOperands (MachineInstr *MI, BitVector &Gen, BitVector &Kill, BitVector &Use)
 Determine def/use set for MI.
void parseOperandsWithReset (MachineInstr *MI, BitVector &Gen, BitVector &Kill, BitVector &Use)
void setUsed (BitVector &Set, unsigned Reg)
 setUsed - Set the register and its sub-registers as being used.
void UpdateLiveness (MachineBasicBlock *MBB)
void dump ()

Detailed Description

Class to track incremental liveness update.

Definition at line 29 of file HexagonGlobalRegion.h.

Constructor & Destructor Documentation

◆ LivenessInfo()

LivenessInfo::LivenessInfo ( const TargetInstrInfo * TII,
const TargetRegisterInfo * TRI,
MachineBasicBlock * MBB )

Definition at line 22 of file HexagonGlobalRegion.cpp.

References for(), MBB, and setUsed().

◆ ~LivenessInfo()

llvm::LivenessInfo::~LivenessInfo ( )
inline

Definition at line 38 of file HexagonGlobalRegion.h.

Member Function Documentation

◆ dump()

void LivenessInfo::dump ( )

Definition at line 210 of file HexagonGlobalRegion.cpp.

References llvm::dbgs(), LLVM_DEBUG, and llvm::printReg().

◆ parseOperands()

void LivenessInfo::parseOperands ( MachineInstr * MI,
BitVector & Gen,
BitVector & Kill,
BitVector & Use )

Determine def/use set for MI.

Beware, if def is conditional, like here: BUNDLE PC<imp-def>, R0<imp-def>, P0<imp-use,kill>, R16<imp-use>

  • R0<def> = LDriuh_cdnNotPt P0<kill,internal>, R16, 0;
  • P0<def> = C2_cmpeqi R16, 0; It is not a statefull definition of R0.

Definition at line 78 of file HexagonGlobalRegion.cpp.

References llvm::dbgs(), llvm::MachineOperand::getReg(), llvm::MachineOperand::isDead(), llvm::MachineOperand::isDef(), llvm::MachineOperand::isKill(), isPredicatedDef(), llvm::MachineOperand::isReg(), llvm::MachineOperand::isUse(), llvm::Kill, LLVM_DEBUG, MI, llvm::printReg(), and setUsed().

Referenced by parseOperandsWithReset().

◆ parseOperandsWithReset()

void LivenessInfo::parseOperandsWithReset ( MachineInstr * MI,
BitVector & Gen,
BitVector & Kill,
BitVector & Use )

Definition at line 104 of file HexagonGlobalRegion.cpp.

References llvm::Kill, MI, parseOperands(), and llvm::BitVector::reset().

Referenced by UpdateLiveness().

◆ setUsed()

void LivenessInfo::setUsed ( BitVector & Set,
unsigned Reg )

setUsed - Set the register and its sub-registers as being used.

Taken from RegScavenger::setUsed().

Definition at line 114 of file HexagonGlobalRegion.cpp.

References llvm::MCSubRegIterator::isValid().

Referenced by LivenessInfo(), parseOperands(), and UpdateLiveness().

◆ UpdateLiveness()


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