docc 0.8.3 (0d44999b)
C++ API Reference
Loading...
Searching...
No Matches
mlir::linalg::LinalgGenericToLinalgSoftmax Struct Reference

y[..., d, ...] = exp(x) / sum_d(exp(x_d)) More...

#include <mlir/Dialect/Linalg/Transforms/CustomSpecializeSoftmax.h>

Inheritance diagram for mlir::linalg::LinalgGenericToLinalgSoftmax:
[legend]

Public Member Functions

bool checkIndexingMap (Attribute attr, long long dim=-1) const
bool checkIndexingMapCollapsed (Attribute attr, long long dim) const
bool checkIndexingMaps (ArrayAttr maps, const std::vector< bool > &reduced_mask, long long dim) const
bool checkIteratorTypes (ArrayAttr types, size_t rank, long long dim=-1) const
bool equalShapes (const ArrayRef< int64_t > &shape1, const ArrayRef< int64_t > &shape2) const
long long determineDimension (const ArrayRef< int64_t > &full_shape, const ArrayRef< int64_t > &reduced_shape) const
template<typename ElemOp>
bool isElementwiseRegion (Region &region) const
bool isFillOp (FillOp fill_op, uint64_t constant) const
LogicalResult matchAndRewrite (GenericOp generic_op, PatternRewriter &rewriter) const override

Detailed Description

y[..., d, ...] = exp(x) / sum_d(exp(x_d))

Member Function Documentation

◆ checkIndexingMap()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::checkIndexingMap ( Attribute attr,
long long dim = -1 ) const

◆ checkIndexingMapCollapsed()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::checkIndexingMapCollapsed ( Attribute attr,
long long dim ) const

◆ checkIndexingMaps()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::checkIndexingMaps ( ArrayAttr maps,
const std::vector< bool > & reduced_mask,
long long dim ) const

◆ checkIteratorTypes()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::checkIteratorTypes ( ArrayAttr types,
size_t rank,
long long dim = -1 ) const

◆ determineDimension()

long long mlir::linalg::LinalgGenericToLinalgSoftmax::determineDimension ( const ArrayRef< int64_t > & full_shape,
const ArrayRef< int64_t > & reduced_shape ) const

◆ equalShapes()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::equalShapes ( const ArrayRef< int64_t > & shape1,
const ArrayRef< int64_t > & shape2 ) const

◆ isElementwiseRegion()

template<typename ElemOp>
bool mlir::linalg::LinalgGenericToLinalgSoftmax::isElementwiseRegion ( Region & region) const
inline

◆ isFillOp()

bool mlir::linalg::LinalgGenericToLinalgSoftmax::isFillOp ( FillOp fill_op,
uint64_t constant ) const

◆ matchAndRewrite()

LogicalResult mlir::linalg::LinalgGenericToLinalgSoftmax::matchAndRewrite ( GenericOp generic_op,
PatternRewriter & rewriter ) const
override

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