MLIR  20.0.0git
Classes | Namespaces | Functions
LinalgInterfaces.h File Reference
#include "mlir/Dialect/Utils/StructuredOpsUtils.h"
#include "mlir/IR/AffineMap.h"
#include "mlir/IR/BuiltinTypes.h"
#include "mlir/IR/IRMapping.h"
#include "mlir/IR/ImplicitLocOpBuilder.h"
#include "mlir/IR/OpDefinition.h"
#include "mlir/Interfaces/DestinationStyleOpInterface.h"
#include "mlir/Interfaces/InferTypeOpInterface.h"
#include "mlir/Interfaces/ViewLikeInterface.h"
#include "mlir/Support/RawOstreamExtras.h"
#include "mlir/Dialect/Linalg/IR/LinalgStructuredOps.h.inc"
#include "mlir/Dialect/Linalg/IR/LinalgInterfaces.h.inc"

Go to the source code of this file.

Classes

struct  mlir::linalg::ContractionDimensions
 Positions of a Linalg op loops that correspond to different kinds of a contraction dimension. More...
 
struct  mlir::linalg::ConvolutionDimensions
 Positions of a Linalg op loops that correspond to different kinds of a convolution dimension. More...
 

Namespaces

 mlir
 Include the generated interface declarations.
 
 mlir::linalg
 
 mlir::linalg::detail
 

Functions

bool mlir::linalg::detail::canOpOperandsBeDroppedImpl (linalg::LinalgOp linalgOp, ArrayRef< OpOperand * > droppedOperands)
 Implementation of the method that check if given operands can be dropped, i.e. More...
 
FailureOr< ContractionDimensionsmlir::linalg::inferContractionDims (LinalgOp linalgOp)
 Find at least 2 parallel (m and n) and 1 reduction (k) dimension candidates that form a matmul subcomputation within linalgOp. More...
 
FailureOr< ContractionDimensionsmlir::linalg::inferContractionDims (ArrayRef< AffineMap > indexingMaps)
 
bool mlir::linalg::isaContractionOpInterface (LinalgOp linalgOp)
 Checks whether linalgOp conforms to ContractionOpInterface. More...
 
FailureOr< ConvolutionDimensionsmlir::linalg::inferConvolutionDims (LinalgOp linalgOp)
 Find at least 1 parallel (output_image) and reduction (filter_loop) dimension candidates that form a convolution subcomputation within linalgOp. More...
 
bool mlir::linalg::isaConvolutionOpInterface (LinalgOp linalgOp, bool allowEmptyConvolvedDims=false)
 Checks whether linalgOp conforms to ConvolutionOpInterface. More...
 
bool mlir::linalg::isaCopyOpInterface (LinalgOp linalgOp)
 Checks whether linalgOp is semantically equivalent to a linalg.copyOp. More...
 
bool mlir::linalg::isaElemwiseSingleUnaryOpInterface (GenericOp genericOp)
 Checks whether a given genericOp is semantically equivalent to a single linalgelementwise unary op. More...
 
bool mlir::linalg::isaElemwiseSingleBinaryOpInterface (GenericOp genericOp)
 Checks whether genericOp is semantically equivalent to a single linalg elementwise binary op e.g. More...
 
std::optional< Valuemlir::linalg::isaFillOpInterface (GenericOp genericOp)
 Checks whether genericOp is semantically equivalent to a linalg.fill. More...
 
bool mlir::linalg::detail::isContractionBody (Block &block, function_ref< bool(Operation *, Operation *)> isaPair, llvm::raw_ostream &errs=mlir::thread_safe_nulls())
 Returns true if the block contains a contraction of the following form: More...
 
MatchContractionResult mlir::linalg::detail::isContractionInterfaceImpl (Operation *op, ContractionDimensions *dimensions=nullptr)
 Checks whether op conforms to ContractionOpInterface and populates dimensions with indexes of the different kinds of dimensions when present. More...
 
StringRef mlir::linalg::detail::getMatchContractionMessage (MatchContractionResult res)
 Returns the error message corresponding to the contraction checking return code. More...
 
MatchConvolutionResult mlir::linalg::detail::isConvolutionInterfaceImpl (Operation *op, ConvolutionDimensions *dimensions=nullptr, bool allowEmptyConvolvedDims=false)
 Checks whether op conforms to ConvolutionOpInterface and populates dimensions with indexes of the different kinds of dimensions when present. More...
 
StringRef mlir::linalg::detail::getMatchConvolutionMessage (MatchConvolutionResult res)
 Returns the error message corresponding to the convolution checking return code. More...
 
LogicalResult mlir::linalg::detail::verifyContractionInterface (Operation *op)
 Verify that op conforms to ContractionOpInterface. More...
 
LogicalResult mlir::linalg::detail::verifyConvolutionInterface (Operation *op)
 Verify that op conforms to the ConvolutionOpInterface. More...
 
LogicalResult mlir::linalg::detail::verifyFillInterface (Operation *op)
 Verify that op conforms to the FillOpInterface. More...
 
LogicalResult mlir::linalg::detail::verifyStructuredOpInterface (Operation *op)
 Verify that op conforms to the invariants of StructuredOpInterface. More...