My Project
Public Member Functions | Static Public Member Functions | List of all members
mlir::detail::OperandStorage Class Referencefinal

#include <OperationSupport.h>

Inheritance diagram for mlir::detail::OperandStorage:
Inheritance graph
[legend]
Collaboration diagram for mlir::detail::OperandStorage:
Collaboration graph
[legend]

Public Member Functions

 OperandStorage (unsigned numOperands, bool resizable)
 
 ~OperandStorage ()
 
void setOperands (Operation *owner, ValueRange operands)
 
void eraseOperand (unsigned index)
 Erase an operand held by the storage. More...
 
MutableArrayRef< OpOperandgetOperands ()
 Get the operation operands held by the storage. More...
 
unsigned size () const
 Return the number of operands held in the storage. More...
 
bool isResizable () const
 Returns if this storage is resizable. More...
 

Static Public Member Functions

static size_t additionalAllocSize (unsigned numOperands, bool resizable)
 Returns the additional size necessary for allocating this object. More...
 

Detailed Description

This class handles the management of operation operands. Operands are stored similarly to the elements of a SmallVector except for two key differences. The first is the inline storage, which is a trailing objects array. The second is that being able to dynamically resize the operand list is optional.

Constructor & Destructor Documentation

◆ OperandStorage()

mlir::detail::OperandStorage::OperandStorage ( unsigned  numOperands,
bool  resizable 
)
inline

◆ ~OperandStorage()

mlir::detail::OperandStorage::~OperandStorage ( )
inline

Member Function Documentation

◆ additionalAllocSize()

static size_t mlir::detail::OperandStorage::additionalAllocSize ( unsigned  numOperands,
bool  resizable 
)
inlinestatic

Returns the additional size necessary for allocating this object.

◆ eraseOperand()

void detail::OperandStorage::eraseOperand ( unsigned  index)

Erase an operand held by the storage.

◆ getOperands()

MutableArrayRef<OpOperand> mlir::detail::OperandStorage::getOperands ( )
inline

Get the operation operands held by the storage.

◆ isResizable()

bool mlir::detail::OperandStorage::isResizable ( ) const
inline

Returns if this storage is resizable.

◆ setOperands()

void detail::OperandStorage::setOperands ( Operation owner,
ValueRange  operands 
)

Replace the operands contained in the storage with the ones provided in 'operands'.

◆ size()

unsigned mlir::detail::OperandStorage::size ( ) const
inline

Return the number of operands held in the storage.


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