Movatterモバイル変換


[0]ホーム

URL:


LLVM 20.0.0git
Public Member Functions |List of all members
llvm::StatepointLoweringState Class Reference

This class tracks both per-statepoint and per-selectiondag information.More...

#include "CodeGen/SelectionDAG/StatepointLowering.h"

Public Member Functions

 StatepointLoweringState ()=default
 
void startNewStatepoint (SelectionDAGBuilder &Builder)
 Reset all state tracking for a newly encountered safepoint.
 
void clear ()
 Clear the memory usage of this object.
 
SDValue getLocation (SDValue Val)
 Returns the spill location of a value incoming to the current statepoint.
 
void setLocation (SDValue Val,SDValue Location)
 
void scheduleRelocCall (constGCRelocateInst &RelocCall)
 Record the fact that we expect to encounter a given gc_relocate before the next statepoint.
 
void relocCallVisited (constGCRelocateInst &RelocCall)
 Remove this gc_relocate from the list we're expecting to see before the next statepoint.
 
SDValue allocateStackSlot (EVTValueType,SelectionDAGBuilder &Builder)
 Get a stack slot we can use to store an value of type ValueType.
 
void reserveStackSlot (intOffset)
 
bool isStackSlotAllocated (intOffset)
 

Detailed Description

This class tracks both per-statepoint and per-selectiondag information.

For each statepoint it tracks locations of it's gc valuess (incoming and relocated) and list of gcreloc calls scheduled for visiting (this is used for a debug mode consistency check only). The spill slot tracking works in concert with information inFunctionLoweringInfo.

Definition at line33 of fileStatepointLowering.h.

Constructor & Destructor Documentation

◆ StatepointLoweringState()

llvm::StatepointLoweringState::StatepointLoweringState()
default

Member Function Documentation

◆ allocateStackSlot()

SDValue StatepointLoweringState::allocateStackSlot(EVT ValueType,
SelectionDAGBuilderBuilder 
)

Get a stack slot we can use to store an value of type ValueType.

This will hopefully be a recylced slot from another statepoint.

Definition at line107 of fileStatepointLowering.cpp.

Referencesassert(),llvm::SelectionDAG::CreateStackTemporary(),llvm::SelectionDAGBuilder::DAG,llvm::SelectionDAGBuilder::FuncInfo,llvm::SelectionDAG::getFrameIndex(),llvm::MachineFunction::getFrameInfo(),llvm::SelectionDAG::getMachineFunction(),llvm::MachineFrameInfo::getObjectSize(),llvm::MachineFrameInfo::markAsStatepointSpillSlotObjectIndex(),llvm::SmallVectorTemplateBase< T, bool >::push_back(),llvm::SmallBitVector::resize(),llvm::SmallBitVector::set(),llvm::SmallBitVector::size(),llvm::SmallVectorBase< Size_T >::size(),llvm::FunctionLoweringInfo::StatepointStackSlots, andllvm::SmallBitVector::test().

Referenced byspillIncomingStatepointValue().

◆ clear()

void StatepointLoweringState::clear()

Clear the memory usage of this object.

This is called fromSelectionDAGBuilder::clear. We require this is never called in the midst of processing a statepoint sequence.

Definition at line99 of fileStatepointLowering.cpp.

Referencesassert(), andllvm::SmallBitVector::clear().

Referenced byllvm::SelectionDAGBuilder::clear().

◆ getLocation()

SDValue llvm::StatepointLoweringState::getLocation(SDValue Val)
inline

Returns the spill location of a value incoming to the current statepoint.

Will return SDValue() if this value hasn't been spilled. Otherwise, the value has already been spilled and no further action is required by the caller.

Definition at line50 of fileStatepointLowering.h.

ReferencesI.

Referenced byllvm::SelectionDAGBuilder::LowerAsSTATEPOINT(),reservePreviousStackSlotForValue(), andspillIncomingStatepointValue().

◆ isStackSlotAllocated()

bool llvm::StatepointLoweringState::isStackSlotAllocated(int Offset)
inline

Definition at line100 of fileStatepointLowering.h.

Referencesassert(),llvm::Offset,llvm::SmallBitVector::size(), andllvm::SmallBitVector::test().

Referenced byreservePreviousStackSlotForValue().

◆ relocCallVisited()

void llvm::StatepointLoweringState::relocCallVisited(constGCRelocateInstRelocCall)
inline

Remove this gc_relocate from the list we're expecting to see before the next statepoint.

If we weren't expecting to see it, we'll report an assertion.

Definition at line75 of fileStatepointLowering.h.

Referencesassert(),llvm::find(),I, andllvm::Value::use_empty().

◆ reserveStackSlot()

void llvm::StatepointLoweringState::reserveStackSlot(int Offset)
inline

Definition at line92 of fileStatepointLowering.h.

Referencesassert(),llvm::Offset,llvm::SmallBitVector::set(),llvm::SmallBitVector::size(), andllvm::SmallBitVector::test().

Referenced byreservePreviousStackSlotForValue().

◆ scheduleRelocCall()

void llvm::StatepointLoweringState::scheduleRelocCall(constGCRelocateInstRelocCall)
inline

Record the fact that we expect to encounter a given gc_relocate before the next statepoint.

If we don't see it, we'll report an assertion.

Definition at line66 of fileStatepointLowering.h.

Referencesllvm::Value::use_empty().

Referenced byllvm::SelectionDAGBuilder::LowerAsSTATEPOINT().

◆ setLocation()

void llvm::StatepointLoweringState::setLocation(SDValue Val,
SDValue Location 
)
inline

Definition at line57 of fileStatepointLowering.h.

Referencesassert().

Referenced byllvm::SelectionDAGBuilder::LowerAsSTATEPOINT(),reservePreviousStackSlotForValue(), andspillIncomingStatepointValue().

◆ startNewStatepoint()

void StatepointLoweringState::startNewStatepoint(SelectionDAGBuilderBuilder)

Reset all state tracking for a newly encountered safepoint.

Also performs some consistency checking.

Definition at line86 of fileStatepointLowering.cpp.

Referencesassert(),llvm::SmallBitVector::clear(),llvm::SelectionDAGBuilder::FuncInfo,llvm::SmallBitVector::resize(),llvm::SmallVectorBase< Size_T >::size(), andllvm::FunctionLoweringInfo::StatepointStackSlots.

Referenced byllvm::SelectionDAGBuilder::LowerAsSTATEPOINT().


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

Generated on Sun Jul 20 2025 19:53:48 for LLVM by doxygen 1.9.6
[8]ページ先頭

©2009-2025 Movatter.jp