mlir.dialects._vector_transform_ops_gen

Attributes

Classes

ApplyCastAwayVectorLeadingOneDimPatternsOp

Collect a set of leading one dimension removal patterns.

ApplyCastAwayVectorLeadingOneDimPatternsOpAdaptor

ApplyDropInnerMostUnitDimsFromXferOpsPatternsOp

Apply vector patterns to drop the inner most unit dims from

ApplyDropInnerMostUnitDimsFromXferOpsPatternsOpAdaptor

ApplyDropUnitDimWithShapeCastPatternsOp

Apply vector patterns to fold unit dims with vector.shape_cast Ops:

ApplyDropUnitDimWithShapeCastPatternsOpAdaptor

ApplyFoldArithExtensionPatternsOp

Collect a set of patterns that fold arithmetic extension on floating point

ApplyFoldArithExtensionPatternsOpAdaptor

ApplyFoldElementwiseToVectorPatternsOp

Collect a set of patterns that fold elementwise op on vectors to the vector

ApplyFoldElementwiseToVectorPatternsOpAdaptor

ApplyInterleaveToShufflePatternsOp

Indicates that 1D vector interleave operations should be rewritten as

ApplyInterleaveToShufflePatternsOpAdaptor

ApplyLowerBitCastPatternsOp

Indicates that vector bitcast operations should be lowered to

ApplyLowerBitCastPatternsOpAdaptor

ApplyLowerBroadcastPatternsOp

Indicates that vector broadcast operations should be lowered to

ApplyLowerBroadcastPatternsOpAdaptor

ApplyLowerContractionPatternsOp

Indicates that vector contraction-like operations should be lowered to

ApplyLowerContractionPatternsOpAdaptor

ApplyLowerCreateMaskPatternsOp

Indicates that vector create_mask-like operations should be lowered to

ApplyLowerCreateMaskPatternsOpAdaptor

ApplyLowerGatherPatternsOp

Indicates that vector.gather operations should be lowered to

ApplyLowerGatherPatternsOpAdaptor

ApplyLowerInterleavePatternsOp

Indicates that vector interleave operations should be lowered to

ApplyLowerInterleavePatternsOpAdaptor

ApplyLowerMaskedTransfersPatternsOp

Apply opt-in patterns that lower vector.mask operations surrounding

ApplyLowerMaskedTransfersPatternsOpAdaptor

ApplyLowerMasksPatternsOp

Indicates that vector.create_mask and vector.constant_mask operations

ApplyLowerMasksPatternsOpAdaptor

ApplyLowerMultiReductionPatternsOp

Indicates that vector multi_reduction-like operations should be lowered to

ApplyLowerMultiReductionPatternsOpAdaptor

ApplyLowerOuterProductPatternsOp

Indicates that the vector outerproduct operations should be lowered to

ApplyLowerOuterProductPatternsOpAdaptor

ApplyLowerScanPatternsOp

Indicates that vector.scan operations should be lowered to

ApplyLowerScanPatternsOpAdaptor

ApplyLowerShapeCastPatternsOp

Indicates that vector shape_cast operations should be lowered to

ApplyLowerShapeCastPatternsOpAdaptor

ApplyLowerTransferPatternsOp

Indicates that vector transfer operations should be lowered to finer-grained

ApplyLowerTransferPatternsOpAdaptor

ApplyLowerTransposePatternsOp

Indicates that vector transpose-like operations should be lowered to

ApplyLowerTransposePatternsOpAdaptor

ApplyMaterializeMasksPatternsOp

Indicates that mask operations should be lowered to fine-grained arithemtic

ApplyMaterializeMasksPatternsOpAdaptor

ApplyRankReducingSubviewPatternsOp

Apply opt-in vector transfer permutation patterns that include:

ApplyRankReducingSubviewPatternsOpAdaptor

ApplyRewriteNarrowTypePatternsOp

Indicates that vector narrow rewrite operations should be applied.

ApplyRewriteNarrowTypePatternsOpAdaptor

ApplySinkVectorMemPatternsOp

Patterns that replace redundant Vector Ops (followed by

ApplySinkVectorMemPatternsOpAdaptor

ApplySinkVectorPatternsOp

Patterns that remove redundant Vector Ops by re-ordering them with

ApplySinkVectorPatternsOpAdaptor

ApplySplitTransferFullPartialPatternsOp

Indicates that vector transfer operations should be split to full and

ApplySplitTransferFullPartialPatternsOpAdaptor

ApplyTransferPermutationPatternsOp

Apply opt-in vector transfer permutation patterns that include:

ApplyTransferPermutationPatternsOpAdaptor

ApplyTransferToScfPatternsOp

Indicates that vector transfer operations should be rewritten with scf.for

ApplyTransferToScfPatternsOpAdaptor

ApplyUnrollFromElementsPatternsOp

Indicates that vector from_elements operations should be unrolled

ApplyUnrollFromElementsPatternsOpAdaptor

ApplyUnrollToElementsPatternsOp

Indicates that vector to_elements operations should be unrolled

ApplyUnrollToElementsPatternsOpAdaptor

ApplyVectorReductionToContractPatternsOp

Apply opt-in patterns that convert reductions to contract:

ApplyVectorReductionToContractPatternsOpAdaptor

ApplyVectorToLLVMConversionPatternsOp

Collects patterns that convert vector dialect ops to LLVM dialect ops. These

ApplyVectorToLLVMConversionPatternsOpAdaptor

Functions

apply_patterns_vector_cast_away_vector_leading_one_dim(...)

apply_patterns_vector_drop_inner_most_unit_dims_from_xfer_ops(...)

apply_patterns_vector_drop_unit_dims_with_shape_cast(...)

apply_patterns_vector_fold_arith_extension(...)

apply_patterns_vector_elementwise_to_vector(...)

apply_patterns_vector_interleave_to_shuffle(...)

apply_patterns_vector_lower_bitcast(...)

apply_patterns_vector_lower_broadcast(...)

apply_patterns_vector_lower_contraction(...)

apply_patterns_vector_lower_create_mask(...)

apply_patterns_vector_lower_gather(...)

apply_patterns_vector_lower_interleave(...)

apply_patterns_vector_lower_masked_transfers(...)

apply_patterns_vector_lower_masks(...)

apply_patterns_vector_lower_multi_reduction(...)

apply_patterns_vector_lower_outerproduct(...)

apply_patterns_vector_lower_scan(...)

apply_patterns_vector_lower_shape_cast(...)

apply_patterns_vector_lower_transfer(...)

apply_patterns_vector_lower_transpose(...)

apply_patterns_vector_materialize_masks(...)

apply_patterns_vector_rank_reducing_subview_patterns(...)

apply_patterns_vector_rewrite_narrow_types(...)

apply_patterns_vector_sink_mem_ops(...)

apply_patterns_vector_sink_ops(→ ApplySinkVectorPatternsOp)

apply_patterns_vector_split_transfer_full_partial(...)

apply_patterns_vector_transfer_permutation_patterns(...)

apply_patterns_vector_transfer_to_scf(...)

apply_patterns_vector_unroll_from_elements(...)

apply_patterns_vector_unroll_to_elements(...)

apply_patterns_vector_reduction_to_contract(...)

apply_conversion_patterns_vector_vector_to_llvm(...)

Module Contents

mlir.dialects._vector_transform_ops_gen._ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyCastAwayVectorLeadingOneDimPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Collect a set of leading one dimension removal patterns.

These patterns insert vector.shape_cast to remove leading one dimensions to expose more canonical forms of read/write/insert/extract operations. With them, there are more chances that we can cancel out extract-insert pairs or forward write-read pairs.

OPERATION_NAME = 'transform.apply_patterns.vector.cast_away_vector_leading_one_dim'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyCastAwayVectorLeadingOneDimPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyCastAwayVectorLeadingOneDimPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.cast_away_vector_leading_one_dim'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_cast_away_vector_leading_one_dim(*, loc=None, ip=None) ApplyCastAwayVectorLeadingOneDimPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyDropInnerMostUnitDimsFromXferOpsPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply vector patterns to drop the inner most unit dims from vector.transfer_read and vector.transfer_write Ops by taking a subview (via memref.subview) of the original source/destination MemRef. Since it requires the input/ouptu to be MemRefs, this Op is only helpful past-bufferization.

OPERATION_NAME = 'transform.apply_patterns.vector.drop_inner_most_unit_dims_from_xfer_ops'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyDropInnerMostUnitDimsFromXferOpsPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyDropInnerMostUnitDimsFromXferOpsPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.drop_inner_most_unit_dims_from_xfer_ops'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_drop_inner_most_unit_dims_from_xfer_ops(*, loc=None, ip=None) ApplyDropInnerMostUnitDimsFromXferOpsPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyDropUnitDimWithShapeCastPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply vector patterns to fold unit dims with vector.shape_cast Ops:

  • DropUnitDimFromElementwiseOps

  • DropUnitDimsFromScfForOp

  • DropUnitDimsFromTransposeOp

Excludes patterns for vector.transfer Ops. This is complemented by shape_cast folding patterns.

OPERATION_NAME = 'transform.apply_patterns.vector.drop_unit_dims_with_shape_cast'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyDropUnitDimWithShapeCastPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyDropUnitDimWithShapeCastPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.drop_unit_dims_with_shape_cast'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_drop_unit_dims_with_shape_cast(*, loc=None, ip=None) ApplyDropUnitDimWithShapeCastPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyFoldArithExtensionPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Collect a set of patterns that fold arithmetic extension on floating point into vector contract for the backends with native support.

OPERATION_NAME = 'transform.apply_patterns.vector.fold_arith_extension'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyFoldArithExtensionPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyFoldArithExtensionPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.fold_arith_extension'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_fold_arith_extension(*, loc=None, ip=None) ApplyFoldArithExtensionPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyFoldElementwiseToVectorPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Collect a set of patterns that fold elementwise op on vectors to the vector dialect.

OPERATION_NAME = 'transform.apply_patterns.vector.elementwise_to_vector'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyFoldElementwiseToVectorPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyFoldElementwiseToVectorPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.elementwise_to_vector'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_elementwise_to_vector(*, loc=None, ip=None) ApplyFoldElementwiseToVectorPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyInterleaveToShufflePatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that 1D vector interleave operations should be rewritten as vector shuffle operations.

This is motivated by some current codegen backends not handling vector interleave operations.

OPERATION_NAME = 'transform.apply_patterns.vector.interleave_to_shuffle'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyInterleaveToShufflePatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyInterleaveToShufflePatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.interleave_to_shuffle'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_interleave_to_shuffle(*, loc=None, ip=None) ApplyInterleaveToShufflePatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBitCastPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector bitcast operations should be lowered to finer-grained vector primitives.

This is usally a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_bitcast'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBitCastPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBitCastPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_bitcast'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_bitcast(*, loc=None, ip=None) ApplyLowerBitCastPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBroadcastPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector broadcast operations should be lowered to finer-grained vector primitives.

This is usally a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_broadcast'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBroadcastPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerBroadcastPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_broadcast'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_broadcast(*, loc=None, ip=None) ApplyLowerBroadcastPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerContractionPatternsOp(*, lowering_strategy=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector contraction-like operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_contraction'
_ODS_REGIONS = (0, True)
lowering_strategy() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyLowerContractionPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerContractionPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_contraction'
lowering_strategy() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_contraction(*, lowering_strategy=None, loc=None, ip=None) ApplyLowerContractionPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerCreateMaskPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector create_mask-like operations should be lowered to finer-grained vector primitives.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_create_mask'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerCreateMaskPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerCreateMaskPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_create_mask'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_create_mask(*, loc=None, ip=None) ApplyLowerCreateMaskPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerGatherPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector.gather operations should be lowered to finer-grained vector primitives.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_gather'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerGatherPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerGatherPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_gather'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_gather(*, loc=None, ip=None) ApplyLowerGatherPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerInterleavePatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector interleave operations should be lowered to finer-grained vector primitives.

This is usally a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_interleave'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerInterleavePatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerInterleavePatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_interleave'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_interleave(*, loc=None, ip=None) ApplyLowerInterleavePatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMaskedTransfersPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply opt-in patterns that lower vector.mask operations surrounding side-effecting ops:

  • MaskedTransferReadOpPattern

  • MaskedTransferWriteOpPattern

  • MaskedGatherOpPattern

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_masked_transfers'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMaskedTransfersPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMaskedTransfersPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_masked_transfers'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_masked_transfers(*, loc=None, ip=None) ApplyLowerMaskedTransfersPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMasksPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector.create_mask and vector.constant_mask operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_masks'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMasksPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMasksPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_masks'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_masks(*, loc=None, ip=None) ApplyLowerMasksPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMultiReductionPatternsOp(*, lowering_strategy=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector multi_reduction-like operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_multi_reduction'
_ODS_REGIONS = (0, True)
lowering_strategy() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMultiReductionPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerMultiReductionPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_multi_reduction'
lowering_strategy() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_multi_reduction(*, lowering_strategy=None, loc=None, ip=None) ApplyLowerMultiReductionPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerOuterProductPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that the vector outerproduct operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_outerproduct'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerOuterProductPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerOuterProductPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_outerproduct'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_outerproduct(*, loc=None, ip=None) ApplyLowerOuterProductPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerScanPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector.scan operations should be lowered to finer-grained vector primitives.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_scan'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerScanPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerScanPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_scan'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_scan(*, loc=None, ip=None) ApplyLowerScanPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerShapeCastPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector shape_cast operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_shape_cast'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerShapeCastPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerShapeCastPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_shape_cast'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_shape_cast(*, loc=None, ip=None) ApplyLowerShapeCastPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransferPatternsOp(*, max_transfer_rank=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector transfer operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_transfer'
_ODS_REGIONS = (0, True)
max_transfer_rank() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransferPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransferPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_transfer'
max_transfer_rank() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_transfer(*, max_transfer_rank=None, loc=None, ip=None) ApplyLowerTransferPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransposePatternsOp(*, lowering_strategy=None, avx2_lowering_strategy=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector transpose-like operations should be lowered to finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.lower_transpose'
_ODS_REGIONS = (0, True)
lowering_strategy() _ods_ir
avx2_lowering_strategy() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransposePatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyLowerTransposePatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.lower_transpose'
lowering_strategy() _ods_ir
avx2_lowering_strategy() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_lower_transpose(*, lowering_strategy=None, avx2_lowering_strategy=None, loc=None, ip=None) ApplyLowerTransposePatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyMaterializeMasksPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that mask operations should be lowered to fine-grained arithemtic operations.

This is usually the last step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.materialize_masks'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyMaterializeMasksPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyMaterializeMasksPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.materialize_masks'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_materialize_masks(*, loc=None, ip=None) ApplyMaterializeMasksPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyRankReducingSubviewPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply opt-in vector transfer permutation patterns that include:

  • TransferReadDropUnitDimsPattern

  • TransferWriteDropUnitDimsPattern

These patterns have the effect of rewriting a vector.transfer with unit dimensions into a rank-reduced version thanks to subview operations. This is complemented by shape_cast folding patterns.

OPERATION_NAME = 'transform.apply_patterns.vector.rank_reducing_subview_patterns'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyRankReducingSubviewPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyRankReducingSubviewPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.rank_reducing_subview_patterns'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_rank_reducing_subview_patterns(*, loc=None, ip=None) ApplyRankReducingSubviewPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyRewriteNarrowTypePatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector narrow rewrite operations should be applied.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

Warning: these patterns currently only work for little endian targets.

OPERATION_NAME = 'transform.apply_patterns.vector.rewrite_narrow_types'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyRewriteNarrowTypePatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyRewriteNarrowTypePatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.rewrite_narrow_types'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_rewrite_narrow_types(*, loc=None, ip=None) ApplyRewriteNarrowTypePatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorMemPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Patterns that replace redundant Vector Ops (followed by vector.load/vector.store) with either vector.load/vector.store or memref.load/memref.store. Currently limited to 1-element vectors.

Example:

vector.load %arg0[%arg1] : memref<?xf32>, vector<4xf32>
vector.extract %0[1] : f32 from vector<4xf32>

Gets converted to:

%c1 = arith.constant 1 : index
%0 = arith.addi %arg1, %c1 overflow<nsw> : index
%1 = memref.load %arg0[%0] : memref<?xf32>
OPERATION_NAME = 'transform.apply_patterns.vector.sink_mem_ops'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorMemPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorMemPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.sink_mem_ops'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_sink_mem_ops(*, loc=None, ip=None) ApplySinkVectorMemPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Patterns that remove redundant Vector Ops by re-ordering them with e.g. elementwise Ops.

Example:

%at = vector.transpose %a, [1, 0]: vector<4x2xf32> to vector<2x4xf32>
%bt = vector.transpose %b, [1, 0]: vector<4x2xf32> to vector<2x4xf32>
%r = arith.addf %at, %bt : vector<2x4xf32>

gets converted to:

%0 = arith.addf %a, %b : vector<4x2xf32>
%r = vector.transpose %0, [1, 0] : vector<2x4xf32>

At the moment, these patterns are limited to vector.broadcast, vector.transpose and vector.extract.

OPERATION_NAME = 'transform.apply_patterns.vector.sink_ops'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplySinkVectorPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.sink_ops'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_sink_ops(*, loc=None, ip=None) ApplySinkVectorPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplySplitTransferFullPartialPatternsOp(*, split_transfer_strategy=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector transfer operations should be split to full and partial parts.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.split_transfer_full_partial'
_ODS_REGIONS = (0, True)
split_transfer_strategy() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplySplitTransferFullPartialPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplySplitTransferFullPartialPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.split_transfer_full_partial'
split_transfer_strategy() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_split_transfer_full_partial(*, split_transfer_strategy=None, loc=None, ip=None) ApplySplitTransferFullPartialPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyTransferPermutationPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply opt-in vector transfer permutation patterns that include:

  • TransferReadPermutationLowering

  • TransferWritePermutationLowering

  • TransferOpReduceRank

  • TransferWriteNonPermutationLowering

These patterns have the effect of rewriting a vector.transfer with an arbitrary permutation_map to a vector.transfer with a permutation_map that is a minor identity followed by a vector.transpose.

In other words, this makes the vector.transfer contiguous on the most minor dimensions and materializes the permutation_map as a vector.transpose.

OPERATION_NAME = 'transform.apply_patterns.vector.transfer_permutation_patterns'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyTransferPermutationPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyTransferPermutationPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.transfer_permutation_patterns'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_transfer_permutation_patterns(*, loc=None, ip=None) ApplyTransferPermutationPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyTransferToScfPatternsOp(*, max_transfer_rank=None, full_unroll=None, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector transfer operations should be rewritten with scf.for loops over finer-grained vector primitives.

This is usually a late step that is run after bufferization as part of the process of lowering to e.g. LLVM or NVVM.

OPERATION_NAME = 'transform.apply_patterns.vector.transfer_to_scf'
_ODS_REGIONS = (0, True)
max_transfer_rank() _ods_ir
full_unroll() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyTransferToScfPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyTransferToScfPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.transfer_to_scf'
max_transfer_rank() _ods_ir
full_unroll() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_transfer_to_scf(*, max_transfer_rank=None, full_unroll=None, loc=None, ip=None) ApplyTransferToScfPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollFromElementsPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector from_elements operations should be unrolled along the outermost dimension.

OPERATION_NAME = 'transform.apply_patterns.vector.unroll_from_elements'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollFromElementsPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollFromElementsPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.unroll_from_elements'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_unroll_from_elements(*, loc=None, ip=None) ApplyUnrollFromElementsPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollToElementsPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Indicates that vector to_elements operations should be unrolled along the outermost dimension.

OPERATION_NAME = 'transform.apply_patterns.vector.unroll_to_elements'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollToElementsPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyUnrollToElementsPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.unroll_to_elements'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_unroll_to_elements(*, loc=None, ip=None) ApplyUnrollToElementsPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyVectorReductionToContractPatternsOp(*, loc=None, ip=None)

Bases: _ods_ir

Apply opt-in patterns that convert reductions to contract:

  • MultiReduceToContract

  • CombineContractBroadcast

  • CombineContractABTranspose

  • CombineContractResultTranspose

  • ReorderElementwiseOpsOnTranspose

  • ReorderElementwiseOpsOnBroadcast

  • ReorderCastOpsOnBroadcast

These patterns have the effect of rewriting a vector.multi_reduce into a vector.contract.

OPERATION_NAME = 'transform.apply_patterns.vector.reduction_to_contract'
_ODS_REGIONS = (0, True)
class mlir.dialects._vector_transform_ops_gen.ApplyVectorReductionToContractPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyVectorReductionToContractPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_patterns.vector.reduction_to_contract'
mlir.dialects._vector_transform_ops_gen.apply_patterns_vector_reduction_to_contract(*, loc=None, ip=None) ApplyVectorReductionToContractPatternsOp
class mlir.dialects._vector_transform_ops_gen.ApplyVectorToLLVMConversionPatternsOp(*, reassociate_fp_reductions=None, force_32bit_vector_indices=None, use_vector_alignment=None, loc=None, ip=None)

Bases: _ods_ir

Collects patterns that convert vector dialect ops to LLVM dialect ops. These patterns require an “LLVMTypeConverter”.

The patterns can be customized as follows:

  • reassociate_fp_reductions: Allows LLVM to reassociate floating-point

reductions for speed. * force_32bit_vector_indices: Allows the compiler to assume that vector indices fit in 32-bit if that yields faster code.

OPERATION_NAME = 'transform.apply_conversion_patterns.vector.vector_to_llvm'
_ODS_REGIONS = (0, True)
reassociate_fp_reductions() _ods_ir
force_32bit_vector_indices() _ods_ir
use_vector_alignment() _ods_ir
class mlir.dialects._vector_transform_ops_gen.ApplyVectorToLLVMConversionPatternsOpAdaptor(operands: list, attributes: OpAttributeMap)
class mlir.dialects._vector_transform_ops_gen.ApplyVectorToLLVMConversionPatternsOpAdaptor(operands: list, opview: OpView)

Bases: _ods_ir

OPERATION_NAME = 'transform.apply_conversion_patterns.vector.vector_to_llvm'
reassociate_fp_reductions() _ods_ir
force_32bit_vector_indices() _ods_ir
use_vector_alignment() _ods_ir
mlir.dialects._vector_transform_ops_gen.apply_conversion_patterns_vector_vector_to_llvm(*, reassociate_fp_reductions=None, force_32bit_vector_indices=None, use_vector_alignment=None, loc=None, ip=None) ApplyVectorToLLVMConversionPatternsOp