|
| OpBuilder (MLIRContext *ctx) |
| Create a builder with the given context. More...
|
|
| OpBuilder (Region *region) |
| Create a builder and set the insertion point to the start of the region. More...
|
|
| OpBuilder (Region ®ion) |
|
virtual | ~OpBuilder () |
|
| OpBuilder (Operation *op) |
|
| OpBuilder (Block *block) |
|
| OpBuilder (Block *block, Block::iterator insertPoint) |
|
void | clearInsertionPoint () |
|
InsertPoint | saveInsertionPoint () const |
| Return a saved insertion point. More...
|
|
void | restoreInsertionPoint (InsertPoint ip) |
| Restore the insert point to a previously saved point. More...
|
|
void | setInsertionPoint (Block *block, Block::iterator insertPoint) |
| Set the insertion point to the specified location. More...
|
|
void | setInsertionPoint (Operation *op) |
|
void | setInsertionPointAfter (Operation *op) |
|
void | setInsertionPointToStart (Block *block) |
| Sets the insertion point to the start of the specified block. More...
|
|
void | setInsertionPointToEnd (Block *block) |
| Sets the insertion point to the end of the specified block. More...
|
|
Block * | getInsertionBlock () const |
|
Block::iterator | getInsertionPoint () const |
| Returns the current insertion point of the builder. More...
|
|
virtual Operation * | insert (Operation *op) |
| Insert the given operation at the current insertion point and return it. More...
|
|
Block * | createBlock (Region *parent, Region::iterator insertPt={}) |
|
Block * | createBlock (Block *insertBefore) |
|
Block * | getBlock () const |
| Returns the current block of the builder. More...
|
|
Operation * | createOperation (const OperationState &state) |
| Creates an operation given the fields represented as an OperationState. More...
|
|
template<typename OpTy , typename... Args> |
OpTy | create (Location location, Args &&... args) |
| Create an operation of specific op type at the current insertion point. More...
|
|
template<typename OpTy , typename... Args> |
void | createOrFold (SmallVectorImpl< Value > &results, Location location, Args &&... args) |
|
template<typename OpTy , typename... Args> |
std::enable_if< OpTy::template hasTrait< OpTrait::OneResult >), Value >::type | createOrFold (Location location, Args &&... args) |
| Overload to create or fold a single result operation. More...
|
|
template<typename OpTy , typename... Args> |
std::enable_if< OpTy::template hasTrait< OpTrait::ZeroResult >), OpTy >::type | createOrFold (Location location, Args &&... args) |
| Overload to create or fold a zero result operation. More...
|
|
LogicalResult | tryFold (Operation *op, SmallVectorImpl< Value > &results) |
|
Operation * | clone (Operation &op, BlockAndValueMapping &mapper) |
|
Operation * | clone (Operation &op) |
|
Operation * | cloneWithoutRegions (Operation &op, BlockAndValueMapping &mapper) |
|
Operation * | cloneWithoutRegions (Operation &op) |
|
template<typename OpT > |
OpT | cloneWithoutRegions (OpT op) |
|
| Builder (MLIRContext *context) |
|
| Builder (ModuleOp module) |
|
MLIRContext * | getContext () const |
|
Identifier | getIdentifier (StringRef str) |
|
Location | getUnknownLoc () |
|
Location | getFileLineColLoc (Identifier filename, unsigned line, unsigned column) |
|
Location | getFusedLoc (ArrayRef< Location > locs, Attribute metadata=Attribute()) |
|
FloatType | getBF16Type () |
|
FloatType | getF16Type () |
|
FloatType | getF32Type () |
|
FloatType | getF64Type () |
|
IndexType | getIndexType () |
|
IntegerType | getI1Type () |
|
IntegerType | getIntegerType (unsigned width) |
|
FunctionType | getFunctionType (ArrayRef< Type > inputs, ArrayRef< Type > results) |
|
TupleType | getTupleType (ArrayRef< Type > elementTypes) |
|
NoneType | getNoneType () |
|
template<typename Ty , typename... Args> |
Ty | getType (Args... args) |
| Get or construct an instance of the type 'ty' with provided arguments. More...
|
|
NamedAttribute | getNamedAttr (StringRef name, Attribute val) |
|
UnitAttr | getUnitAttr () |
|
BoolAttr | getBoolAttr (bool value) |
|
DictionaryAttr | getDictionaryAttr (ArrayRef< NamedAttribute > value) |
|
IntegerAttr | getIntegerAttr (Type type, int64_t value) |
|
IntegerAttr | getIntegerAttr (Type type, const APInt &value) |
|
FloatAttr | getFloatAttr (Type type, double value) |
|
FloatAttr | getFloatAttr (Type type, const APFloat &value) |
|
StringAttr | getStringAttr (StringRef bytes) |
|
ArrayAttr | getArrayAttr (ArrayRef< Attribute > value) |
|
FlatSymbolRefAttr | getSymbolRefAttr (Operation *value) |
|
FlatSymbolRefAttr | getSymbolRefAttr (StringRef value) |
|
SymbolRefAttr | getSymbolRefAttr (StringRef value, ArrayRef< FlatSymbolRefAttr > nestedReferences) |
|
Attribute | getZeroAttr (Type type) |
|
FloatAttr | getF16FloatAttr (float value) |
|
FloatAttr | getF32FloatAttr (float value) |
|
FloatAttr | getF64FloatAttr (double value) |
|
IntegerAttr | getI8IntegerAttr (int8_t value) |
|
IntegerAttr | getI16IntegerAttr (int16_t value) |
|
IntegerAttr | getI32IntegerAttr (int32_t value) |
|
IntegerAttr | getI64IntegerAttr (int64_t value) |
|
DenseIntElementsAttr | getI32VectorAttr (ArrayRef< int32_t > values) |
|
ArrayAttr | getAffineMapArrayAttr (ArrayRef< AffineMap > values) |
|
ArrayAttr | getI32ArrayAttr (ArrayRef< int32_t > values) |
|
ArrayAttr | getI64ArrayAttr (ArrayRef< int64_t > values) |
|
ArrayAttr | getIndexArrayAttr (ArrayRef< int64_t > values) |
|
ArrayAttr | getF32ArrayAttr (ArrayRef< float > values) |
|
ArrayAttr | getF64ArrayAttr (ArrayRef< double > values) |
|
ArrayAttr | getStrArrayAttr (ArrayRef< StringRef > values) |
|
AffineExpr | getAffineDimExpr (unsigned position) |
|
AffineExpr | getAffineSymbolExpr (unsigned position) |
|
AffineExpr | getAffineConstantExpr (int64_t constant) |
|
AffineMap | getEmptyAffineMap () |
| Returns a zero result affine map with no dimensions or symbols: () -> (). More...
|
|
AffineMap | getConstantAffineMap (int64_t val) |
|
AffineMap | getDimIdentityMap () |
|
AffineMap | getMultiDimIdentityMap (unsigned rank) |
|
AffineMap | getSymbolIdentityMap () |
|
AffineMap | getSingleDimShiftAffineMap (int64_t shift) |
|
AffineMap | getShiftedAffineMap (AffineMap map, int64_t shift) |
|
This class helps build Operations. Operations that are created are automatically inserted at an insertion point. The builder is copyable.