#include "mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.h"
#include "mlir/Analysis/DataLayoutAnalysis.h"
#include "mlir/Conversion/LLVMCommon/TypeConverter.h"
#include "mlir/Dialect/Affine/IR/AffineOps.h"
#include "mlir/Dialect/Arith/IR/Arith.h"
#include "mlir/Dialect/MemRef/IR/MemRef.h"
#include "mlir/Dialect/MemRef/Transforms/Passes.h"
#include "mlir/Dialect/MemRef/Transforms/Transforms.h"
#include "mlir/Dialect/MemRef/Utils/MemRefUtils.h"
#include "mlir/Dialect/NVGPU/IR/NVGPUDialect.h"
#include "mlir/Dialect/SCF/IR/SCF.h"
#include "mlir/Dialect/Transform/IR/TransformDialect.h"
#include "mlir/Dialect/Transform/IR/TransformTypes.h"
#include "mlir/Dialect/Transform/Interfaces/TransformInterfaces.h"
#include "mlir/Dialect/Vector/IR/VectorOps.h"
#include "mlir/Dialect/Vector/Transforms/VectorTransforms.h"
#include "mlir/Interfaces/LoopLikeInterface.h"
#include "mlir/Transforms/GreedyPatternRewriteDriver.h"
#include "llvm/Support/Debug.h"
usingnamespacemlir;
#define DEBUG_TYPE …
#define DBGS() …
std::unique_ptr<TypeConverter>
transform::MemrefToLLVMTypeConverterOp::getTypeConverter() { … }
StringRef transform::MemrefToLLVMTypeConverterOp::getTypeConverterType() { … }
namespace {
class AllocToAllocaPattern : public OpRewritePattern<memref::AllocOp> { … };
}
void transform::ApplyAllocToAllocaOp::populatePatterns(
RewritePatternSet &patterns) { … }
void transform::ApplyAllocToAllocaOp::populatePatternsWithState(
RewritePatternSet &patterns, transform::TransformState &state) { … }
void transform::ApplyExpandOpsPatternsOp::populatePatterns(
RewritePatternSet &patterns) { … }
void transform::ApplyExpandStridedMetadataPatternsOp::populatePatterns(
RewritePatternSet &patterns) { … }
void transform::ApplyExtractAddressComputationsPatternsOp::populatePatterns(
RewritePatternSet &patterns) { … }
void transform::ApplyFoldMemrefAliasOpsPatternsOp::populatePatterns(
RewritePatternSet &patterns) { … }
void transform::ApplyResolveRankedShapedTypeResultDimsPatternsOp::
populatePatterns(RewritePatternSet &patterns) { … }
DiagnosedSilenceableFailure
transform::MemRefAllocaToGlobalOp::apply(transform::TransformRewriter &rewriter,
transform::TransformResults &results,
transform::TransformState &state) { … }
void transform::MemRefAllocaToGlobalOp::getEffects(
SmallVectorImpl<MemoryEffects::EffectInstance> &effects) { … }
DiagnosedSilenceableFailure transform::MemRefMultiBufferOp::apply(
transform::TransformRewriter &rewriter,
transform::TransformResults &transformResults,
transform::TransformState &state) { … }
DiagnosedSilenceableFailure
transform::MemRefEraseDeadAllocAndStoresOp::applyToOne(
transform::TransformRewriter &rewriter, Operation *target,
transform::ApplyToEachResultList &results,
transform::TransformState &state) { … }
void transform::MemRefEraseDeadAllocAndStoresOp::getEffects(
SmallVectorImpl<MemoryEffects::EffectInstance> &effects) { … }
void transform::MemRefEraseDeadAllocAndStoresOp::build(OpBuilder &builder,
OperationState &result,
Value target) { … }
DiagnosedSilenceableFailure transform::MemRefMakeLoopIndependentOp::applyToOne(
transform::TransformRewriter &rewriter, Operation *target,
transform::ApplyToEachResultList &results,
transform::TransformState &state) { … }
namespace {
class MemRefTransformDialectExtension
: public transform::TransformDialectExtension<
MemRefTransformDialectExtension> { … };
}
#define GET_OP_CLASSES
#include "mlir/Dialect/MemRef/TransformOps/MemRefTransformOps.cpp.inc"
void mlir::memref::registerTransformDialectExtension(
DialectRegistry ®istry) { … }