LLVM 22.0.0git
LiveDebugValues::DbgValue Class Reference

Class recording the (high level) value of a variable. More...

#include "CodeGen/LiveDebugValues/InstrRefBasedImpl.h"

Public Types

enum  KindT { Undef , Def , VPHI , NoVal }

Public Member Functions

 DbgValue (ArrayRef< DbgOpID > DbgOps, const DbgValueProperties &Prop)
 DbgValue (unsigned BlockNo, const DbgValueProperties &Prop, KindT Kind)
 DbgValue (const DbgValueProperties &Prop, KindT Kind)
void dump (const MLocTracker *MTrack=nullptr, const DbgOpIDMap *OpStore=nullptr) const
bool operator== (const DbgValue &Other) const
bool operator!= (const DbgValue &Other) const
ArrayRef< DbgOpIDgetDbgOpIDs () const
DbgOpID getDbgOpID (unsigned Index) const
void setDbgOpIDs (ArrayRef< DbgOpID > NewIDs)
unsigned getLocationOpCount () const
bool hasJoinableLocOps (const DbgValue &Other) const
bool isUnjoinedPHI () const
bool hasIdenticalValidLocOps (const DbgValue &Other) const

Public Attributes

int BlockNo
 For a NoVal or VPHI DbgValue, which block it was generated in.
DbgValueProperties Properties
 Qualifiers for the ValueIDNum above.
KindT Kind
 Discriminator for whether this is a constant or an in-program value.

Detailed Description

Class recording the (high level) value of a variable.

Identifies the value of the variable as a list of ValueIDNums and constant MachineOperands, or as an empty list for undef debug values or VPHI values which we have not found valid locations for. This class also stores meta-information about how the value is qualified. Used to reason about variable values when performing the second (DebugVariable specific) dataflow analysis.

Definition at line 513 of file InstrRefBasedImpl.h.

Member Enumeration Documentation

◆ KindT

Enumerator
Undef 
Def 
VPHI 
NoVal 

Definition at line 529 of file InstrRefBasedImpl.h.

Constructor & Destructor Documentation

◆ DbgValue() [1/3]

◆ DbgValue() [2/3]

LiveDebugValues::DbgValue::DbgValue ( unsigned BlockNo,
const DbgValueProperties & Prop,
KindT Kind )
inline

Definition at line 562 of file InstrRefBasedImpl.h.

References assert(), BlockNo, Kind, NoVal, Properties, and VPHI.

◆ DbgValue() [3/3]

LiveDebugValues::DbgValue::DbgValue ( const DbgValueProperties & Prop,
KindT Kind )
inline

Definition at line 567 of file InstrRefBasedImpl.h.

References assert(), BlockNo, Kind, Properties, and Undef.

Member Function Documentation

◆ dump()

void DbgValue::dump ( const MLocTracker * MTrack = nullptr,
const DbgOpIDMap * OpStore = nullptr ) const

◆ getDbgOpID()

DbgOpID LiveDebugValues::DbgValue::getDbgOpID ( unsigned Index) const
inline

Definition at line 602 of file InstrRefBasedImpl.h.

References assert(), and LiveDebugValues::DbgOpID::UndefID.

Referenced by dump(), and hasJoinableLocOps().

◆ getDbgOpIDs()

ArrayRef< DbgOpID > LiveDebugValues::DbgValue::getDbgOpIDs ( ) const
inline

Definition at line 597 of file InstrRefBasedImpl.h.

Referenced by dump(), hasIdenticalValidLocOps(), and operator==().

◆ getLocationOpCount()

unsigned LiveDebugValues::DbgValue::getLocationOpCount ( ) const
inline

Definition at line 624 of file InstrRefBasedImpl.h.

References Properties.

Referenced by hasJoinableLocOps(), and setDbgOpIDs().

◆ hasIdenticalValidLocOps()

bool LiveDebugValues::DbgValue::hasIdenticalValidLocOps ( const DbgValue & Other) const
inline

Definition at line 643 of file InstrRefBasedImpl.h.

References DbgValue(), llvm::equal(), getDbgOpIDs(), and llvm::Other.

◆ hasJoinableLocOps()

bool LiveDebugValues::DbgValue::hasJoinableLocOps ( const DbgValue & Other) const
inline

◆ isUnjoinedPHI()

bool LiveDebugValues::DbgValue::isUnjoinedPHI ( ) const
inline

Definition at line 641 of file InstrRefBasedImpl.h.

References Kind, and VPHI.

Referenced by hasJoinableLocOps().

◆ operator!=()

bool LiveDebugValues::DbgValue::operator!= ( const DbgValue & Other) const
inline

Definition at line 593 of file InstrRefBasedImpl.h.

References DbgValue(), and llvm::Other.

◆ operator==()

bool LiveDebugValues::DbgValue::operator== ( const DbgValue & Other) const
inline

◆ setDbgOpIDs()

void LiveDebugValues::DbgValue::setDbgOpIDs ( ArrayRef< DbgOpID > NewIDs)
inline

Definition at line 612 of file InstrRefBasedImpl.h.

References assert(), getLocationOpCount(), and llvm::ArrayRef< T >::size().

Member Data Documentation

◆ BlockNo

int LiveDebugValues::DbgValue::BlockNo

For a NoVal or VPHI DbgValue, which block it was generated in.

Definition at line 524 of file InstrRefBasedImpl.h.

Referenced by DbgValue(), DbgValue(), DbgValue(), dump(), and operator==().

◆ Kind

KindT LiveDebugValues::DbgValue::Kind

Discriminator for whether this is a constant or an in-program value.

Definition at line 539 of file InstrRefBasedImpl.h.

Referenced by DbgValue(), DbgValue(), DbgValue(), dump(), isUnjoinedPHI(), and operator==().

◆ Properties

DbgValueProperties LiveDebugValues::DbgValue::Properties

Qualifiers for the ValueIDNum above.

Definition at line 527 of file InstrRefBasedImpl.h.

Referenced by DbgValue(), DbgValue(), DbgValue(), dump(), getLocationOpCount(), and operator==().


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