My Project
Namespaces | Classes | Typedefs | Functions
mlir::edsc::intrinsics Namespace Reference

Namespaces

 detail
 

Classes

struct  OperationBuilder
 
struct  ValueBuilder
 

Typedefs

using linalg_fill = OperationBuilder< linalg::FillOp >
 
using linalg_reshape = OperationBuilder< linalg::ReshapeOp >
 
using linalg_yield = OperationBuilder< linalg::YieldOp >
 
using addf = ValueBuilder< AddFOp >
 
using affine_apply = ValueBuilder< AffineApplyOp >
 
using affine_if = OperationBuilder< AffineIfOp >
 
using affine_load = ValueBuilder< AffineLoadOp >
 
using affine_store = OperationBuilder< AffineStoreOp >
 
using alloc = ValueBuilder< AllocOp >
 
using call = OperationBuilder< mlir::CallOp >
 
using constant_float = ValueBuilder< ConstantFloatOp >
 
using constant_index = ValueBuilder< ConstantIndexOp >
 
using constant_int = ValueBuilder< ConstantIntOp >
 
using dealloc = OperationBuilder< DeallocOp >
 
using dim = ValueBuilder< DimOp >
 
using muli = ValueBuilder< MulIOp >
 
using mulf = ValueBuilder< MulFOp >
 
using memref_cast = ValueBuilder< MemRefCastOp >
 
using ret = OperationBuilder< ReturnOp >
 
using select = ValueBuilder< SelectOp >
 
using std_load = ValueBuilder< LoadOp >
 
using std_store = OperationBuilder< StoreOp >
 
using subi = ValueBuilder< SubIOp >
 
using tanh = ValueBuilder< TanhOp >
 
using view = ValueBuilder< ViewOp >
 

Functions

OperationHandle br (BlockHandle bh, ArrayRef< ValueHandle > operands)
 
OperationHandle br (BlockHandle *bh, ArrayRef< ValueHandle *> captures, ArrayRef< ValueHandle > operands)
 
OperationHandle cond_br (ValueHandle cond, BlockHandle trueBranch, ArrayRef< ValueHandle > trueOperands, BlockHandle falseBranch, ArrayRef< ValueHandle > falseOperands)
 
OperationHandle cond_br (ValueHandle cond, BlockHandle *trueBranch, ArrayRef< ValueHandle *> trueCaptures, ArrayRef< ValueHandle > trueOperands, BlockHandle *falseBranch, ArrayRef< ValueHandle *> falseCaptures, ArrayRef< ValueHandle > falseOperands)
 

Detailed Description

Provides a set of first class intrinsics. In the future, most of intrinsics related to Operation that don't contain other operations should be Tablegen'd.

Typedef Documentation

◆ addf

using mlir::edsc::intrinsics::addf = typedef ValueBuilder<AddFOp>

◆ affine_apply

◆ affine_if

◆ affine_load

◆ affine_store

◆ alloc

using mlir::edsc::intrinsics::alloc = typedef ValueBuilder<AllocOp>

◆ call

using mlir::edsc::intrinsics::call = typedef OperationBuilder<mlir::CallOp>

◆ constant_float

◆ constant_index

◆ constant_int

◆ dealloc

◆ dim

using mlir::edsc::intrinsics::dim = typedef ValueBuilder<DimOp>

◆ linalg_fill

using mlir::edsc::intrinsics::linalg_fill = typedef OperationBuilder<linalg::FillOp>

◆ linalg_reshape

using mlir::edsc::intrinsics::linalg_reshape = typedef OperationBuilder<linalg::ReshapeOp>

◆ linalg_yield

using mlir::edsc::intrinsics::linalg_yield = typedef OperationBuilder<linalg::YieldOp>

◆ memref_cast

using mlir::edsc::intrinsics::memref_cast = typedef ValueBuilder<MemRefCastOp>

◆ mulf

using mlir::edsc::intrinsics::mulf = typedef ValueBuilder<MulFOp>

◆ muli

using mlir::edsc::intrinsics::muli = typedef ValueBuilder<MulIOp>

◆ ret

using mlir::edsc::intrinsics::ret = typedef OperationBuilder<ReturnOp>

◆ select

using mlir::edsc::intrinsics::select = typedef ValueBuilder<SelectOp>

◆ std_load

◆ std_store

◆ subi

using mlir::edsc::intrinsics::subi = typedef ValueBuilder<SubIOp>

◆ tanh

using mlir::edsc::intrinsics::tanh = typedef ValueBuilder<TanhOp>

◆ view

using mlir::edsc::intrinsics::view = typedef ValueBuilder<ViewOp>

Function Documentation

◆ br() [1/2]

OperationHandle mlir::edsc::intrinsics::br ( BlockHandle  bh,
ArrayRef< ValueHandle operands 
)

Branches into the mlir::Block* captured by BlockHandle b with operands.

Prerequisites: All Handles have already captured previously constructed IR objects.

◆ br() [2/2]

OperationHandle mlir::edsc::intrinsics::br ( BlockHandle bh,
ArrayRef< ValueHandle *>  captures,
ArrayRef< ValueHandle operands 
)

Creates a new mlir::Block* and branches to it from the current block. Argument types are specified by operands. Captures the new block in bh and the actual operands in captures. To insert the new mlir::Block*, a local ScopedContext is constructed and released to the current block. The branch operation is then added to the new block.

Prerequisites: b has not yet captured an mlir::Block*. No captures have captured any mlir::Value. All operands have already captured an mlir::Value captures.size() == operands.size() captures and operands are pairwise of the same type.

◆ cond_br() [1/2]

OperationHandle mlir::edsc::intrinsics::cond_br ( ValueHandle  cond,
BlockHandle  trueBranch,
ArrayRef< ValueHandle trueOperands,
BlockHandle  falseBranch,
ArrayRef< ValueHandle falseOperands 
)

Branches into the mlir::Block* captured by BlockHandle trueBranch with trueOperands if cond evaluates to true (resp. falseBranch and falseOperand if cond evaluates to false).

Prerequisites: All Handles have captured previously constructed IR objects.

◆ cond_br() [2/2]

OperationHandle mlir::edsc::intrinsics::cond_br ( ValueHandle  cond,
BlockHandle trueBranch,
ArrayRef< ValueHandle *>  trueCaptures,
ArrayRef< ValueHandle trueOperands,
BlockHandle falseBranch,
ArrayRef< ValueHandle *>  falseCaptures,
ArrayRef< ValueHandle falseOperands 
)

Eagerly creates new mlir::Block* with argument types specified by trueOperands/falseOperands. Captures the new blocks in trueBranch/falseBranch and the arguments in trueCaptures/falseCaptures. To insert the new mlir::Block*, a local ScopedContext is constructed and released. The branch operation is then added in the original location and targeting the eagerly constructed blocks.

Prerequisites: trueBranch/falseBranch has not yet captured an mlir::Block*. No trueCaptures/falseCaptures have captured any mlir::Value. All trueOperands/trueOperands have already captured an mlir::Value trueCaptures.size() == trueOperands.size() falseCaptures.size() == falseOperands.size() trueCaptures and trueOperands are pairwise of the same type falseCaptures and falseOperands are pairwise of the same type.