MLIR 23.0.0git
XeGPUDialect.cpp File Reference
#include "mlir/Dialect/Affine/Utils.h"
#include "mlir/Dialect/Arith/Utils/Utils.h"
#include "mlir/Dialect/GPU/IR/GPUDialect.h"
#include "mlir/Dialect/LLVMIR/XeVMDialect.h"
#include "mlir/Dialect/Utils/IndexingUtils.h"
#include "mlir/Dialect/XeGPU/IR/XeGPU.h"
#include "mlir/Dialect/XeGPU/uArch/uArchCommon.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/DialectImplementation.h"
#include "llvm/ADT/SmallVectorExtras.h"
#include "llvm/ADT/TypeSwitch.h"
#include "llvm/Support/Debug.h"
#include <mlir/Dialect/XeGPU/IR/XeGPUTypes.cpp.inc>
#include <mlir/Dialect/XeGPU/IR/XeGPU.cpp.inc>
#include <mlir/Dialect/XeGPU/IR/XeGPUAttrs.cpp.inc>
#include "mlir/Dialect/XeGPU/IR/XeGPUOpInterface.cpp.inc"
#include <mlir/Dialect/XeGPU/IR/XeGPUDialect.cpp.inc>

Go to the source code of this file.

Namespaces

namespace  mlir
 Include the generated interface declarations.
namespace  mlir::xegpu

Macros

#define GET_TYPEDEF_LIST
#define GET_OP_LIST
#define GET_ATTRDEF_LIST
#define GET_OP_INTERFACE_CLASSES
#define div(a, b)
#define rem(a, b)
#define mul(a, b)
#define add(a, b)
#define GET_ATTRDEF_CLASSES
#define GET_TYPEDEF_CLASSES

Functions

static SmallVector< SmallVector< Value > > mlir::xegpu::genCoordinates (OpBuilder &builder, Location loc, SmallVector< Value > delinearizedId, ArrayRef< int64_t > subShapesLayout, ArrayRef< int64_t > subShape, ArrayRef< int64_t > srcShape)
static SmallVector< SmallVector< int64_t > > mlir::xegpu::genStaticCoordinates (llvm::ArrayRef< int64_t > canonicalIds, llvm::ArrayRef< int64_t > layout, llvm::ArrayRef< int64_t > subShape, llvm::ArrayRef< int64_t > shape)
static SmallVector< SmallVector< int64_t > > mlir::xegpu::expandBlockCoords (ArrayRef< SmallVector< int64_t > > blockStarts, ArrayRef< int64_t > subShape)
 Expands per-distribution-unit block-start coordinates into the full list of element coordinates each block covers: every element of the subShape-sized region (row-major) offset by the block start.
static bool mlir::xegpu::compareDistributedCoords (xegpu::DistributeLayoutAttr self, const xegpu::DistributeLayoutAttr &other, ArrayRef< int64_t > shape, xegpu::LayoutKind level, int64_t size)
 Returns true if self and other distribute shape identically at level: every id in [0, size) owns the same coordinates under both.
static SmallVector< int64_tmlir::xegpu::mapSlicedDimsToParentSpace (const SmallVector< int64_t > &dimsToMap, ArrayRef< int64_t > sliceDims)
SmallVector< int64_tmlir::xegpu::getPermForParentLayout (ArrayRef< int64_t > sliceDims, ArrayRef< int64_t > permutation)
template<typename ArithOp>
OpFoldResult mlir::xegpu::genBinOp (OpFoldResult a, OpFoldResult b, Location loc, OpBuilder &builder)
SmallVector< OpFoldResultmlir::xegpu::getBlockedOffsets (OpBuilder &builder, Location loc, ArrayRef< OpFoldResult > offsets, ArrayRef< int64_t > blockShape)

Macro Definition Documentation

◆ add

◆ div

◆ GET_ATTRDEF_CLASSES

#define GET_ATTRDEF_CLASSES

Definition at line 1900 of file XeGPUDialect.cpp.

◆ GET_ATTRDEF_LIST

#define GET_ATTRDEF_LIST

◆ GET_OP_INTERFACE_CLASSES

#define GET_OP_INTERFACE_CLASSES

Definition at line 41 of file XeGPUDialect.cpp.

◆ GET_OP_LIST

#define GET_OP_LIST

◆ GET_TYPEDEF_CLASSES

#define GET_TYPEDEF_CLASSES

Definition at line 1902 of file XeGPUDialect.cpp.

◆ GET_TYPEDEF_LIST

#define GET_TYPEDEF_LIST

◆ mul

◆ rem