LLVM 17.0.0git
Public Member Functions | Public Attributes | List of all members
LiveDebugValues::VLocTracker Class Reference

Collection of DBG_VALUEs observed when traversing a block. More...

#include "CodeGen/LiveDebugValues/InstrRefBasedImpl.h"

Collaboration diagram for LiveDebugValues::VLocTracker:
Collaboration graph
[legend]

Public Member Functions

 VLocTracker (const OverlapMap &O, const DIExpression *EmptyExpr)
 
void defVar (const MachineInstr &MI, const DbgValueProperties &Properties, const SmallVectorImpl< DbgOpID > &DebugOps)
 
void considerOverlaps (const DebugVariable &Var, const DILocation *Loc)
 
void clear ()
 

Public Attributes

MapVector< DebugVariable, DbgValueVars
 Map DebugVariable to the latest Value it's defined to have.
 
SmallDenseMap< DebugVariable, const DILocation *, 8 > Scopes
 
MachineBasicBlockMBB = nullptr
 
const OverlapMapOverlappingFragments
 
DbgValueProperties EmptyProperties
 

Detailed Description

Collection of DBG_VALUEs observed when traversing a block.

Records each variable and the value the DBG_VALUE refers to. Requires the machine value location dataflow algorithm to have run already, so that values can be identified.

Definition at line 965 of file InstrRefBasedImpl.h.

Constructor & Destructor Documentation

◆ VLocTracker()

LiveDebugValues::VLocTracker::VLocTracker ( const OverlapMap O,
const DIExpression EmptyExpr 
)
inline

Definition at line 982 of file InstrRefBasedImpl.h.

Member Function Documentation

◆ clear()

void LiveDebugValues::VLocTracker::clear ( )
inline

Definition at line 1030 of file InstrRefBasedImpl.h.

References Scopes, and Vars.

◆ considerOverlaps()

void LiveDebugValues::VLocTracker::considerOverlaps ( const DebugVariable Var,
const DILocation Loc 
)
inline

◆ defVar()

void LiveDebugValues::VLocTracker::defVar ( const MachineInstr MI,
const DbgValueProperties Properties,
const SmallVectorImpl< DbgOpID > &  DebugOps 
)
inline

Member Data Documentation

◆ EmptyProperties

DbgValueProperties LiveDebugValues::VLocTracker::EmptyProperties

Definition at line 979 of file InstrRefBasedImpl.h.

Referenced by considerOverlaps().

◆ MBB

MachineBasicBlock* LiveDebugValues::VLocTracker::MBB = nullptr

Definition at line 977 of file InstrRefBasedImpl.h.

◆ OverlappingFragments

const OverlapMap& LiveDebugValues::VLocTracker::OverlappingFragments

Definition at line 978 of file InstrRefBasedImpl.h.

Referenced by considerOverlaps().

◆ Scopes

SmallDenseMap<DebugVariable, const DILocation *, 8> LiveDebugValues::VLocTracker::Scopes

Definition at line 976 of file InstrRefBasedImpl.h.

Referenced by clear(), considerOverlaps(), and defVar().

◆ Vars

MapVector<DebugVariable, DbgValue> LiveDebugValues::VLocTracker::Vars

Map DebugVariable to the latest Value it's defined to have.

Needs to be a MapVector because we determine order-in-the-input-MIR from the order in this container. We only retain the last DbgValue in each block for each variable, to determine the blocks live-out variable value. The Vars container forms the transfer function for this block, as part of the dataflow analysis. The movement of values between locations inside of a block is handled at a much later stage, in the TransferTracker class.

Definition at line 975 of file InstrRefBasedImpl.h.

Referenced by clear(), considerOverlaps(), and defVar().


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