FLANG
fir::InsertionPoint Class Reference

#include <Optimizer/Transforms/StackArrays.h>

Public Member Functions

template<class T>
 InsertionPoint (T *ptr, bool saveRestoreStack=false)
 InsertionPoint (std::nullptr_t null)
mlir::Operation * tryGetOperation () const
 Get contained operation, or nullptr.
mlir::Block * tryGetBlock () const
 Get contained block, or nullptr.
bool shouldSaveRestoreStack () const
 operator bool () const
bool operator== (const InsertionPoint &rhs) const
bool operator!= (const InsertionPoint &rhs) const

Detailed Description

Stores where an alloca should be inserted. If the PointerUnion is an Operation the alloca should be inserted /after/ the operation. If it is a block, the alloca can be placed anywhere in that block.

Member Function Documentation

◆ shouldSaveRestoreStack()

bool fir::InsertionPoint::shouldSaveRestoreStack ( ) const
inline

Get whether the stack should be saved/restored. If yes, an llvm.stacksave intrinsic should be added before the alloca, and an llvm.stackrestore intrinsic should be added where the freemem is


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