MLIR  20.0.0git
Functions
Utils.cpp File Reference
#include "mlir/Dialect/Tensor/Utils/Utils.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Arith/IR/Arith.h"
#include "mlir/Dialect/Arith/Utils/Utils.h"
#include "mlir/Dialect/Utils/IndexingUtils.h"
#include "mlir/Dialect/Vector/IR/VectorOps.h"
#include "mlir/Interfaces/ValueBoundsOpInterface.h"

Go to the source code of this file.

Functions

static SmallVector< int64_t > computePackUnPackPerm (int64_t rank, ArrayRef< int64_t > &innerDimsPos, ArrayRef< int64_t > &outerPerm, PackingMetadata &packingMetadata)
 The permutation can be obtained from two permutations: a) Compute the permutation vector to move the last numPackedDims into the innerPosDims of a shape of rank rank. More...
 

Function Documentation

◆ computePackUnPackPerm()

static SmallVector<int64_t> computePackUnPackPerm ( int64_t  rank,
ArrayRef< int64_t > &  innerDimsPos,
ArrayRef< int64_t > &  outerPerm,
PackingMetadata &  packingMetadata 
)
static

The permutation can be obtained from two permutations: a) Compute the permutation vector to move the last numPackedDims into the innerPosDims of a shape of rank rank.

b) Compute the permutation vector to move outer dims if the outerPerm parameter is not empty. Apply (b) permutation on (a) permutation to get the final permutation.

Definition at line 102 of file Utils.cpp.

References mlir::applyPermutationToVector(), and mlir::computePermutationVector().