[Mlir-commits] [mlir] 4d60f47 - [mlir][NFC] Renamed VectorOps to Vector
River Riddle
llvmlistbot at llvm.org
Tue Mar 17 15:28:36 PDT 2020
Author: Rob Suderman
Date: 2020-03-17T15:28:08-07:00
New Revision: 4d60f47b082f20d93f621fb5cd4bb978c26b7bf1
URL: https://github.com/llvm/llvm-project/commit/4d60f47b082f20d93f621fb5cd4bb978c26b7bf1
DIFF: https://github.com/llvm/llvm-project/commit/4d60f47b082f20d93f621fb5cd4bb978c26b7bf1.diff
LOG: [mlir][NFC] Renamed VectorOps to Vector
Summary: Renamed VectorOps to Vector to avoid the redundant Ops suffix.
Differential Revision: https://reviews.llvm.org/D76317
Added:
mlir/include/mlir/Dialect/Vector/CMakeLists.txt
mlir/include/mlir/Dialect/Vector/EDSC/Builders.h
mlir/include/mlir/Dialect/Vector/EDSC/Intrinsics.h
mlir/include/mlir/Dialect/Vector/VectorOps.h
mlir/include/mlir/Dialect/Vector/VectorOps.td
mlir/include/mlir/Dialect/Vector/VectorTransformPatterns.td
mlir/include/mlir/Dialect/Vector/VectorTransforms.h
mlir/include/mlir/Dialect/Vector/VectorUtils.h
mlir/lib/Dialect/Vector/CMakeLists.txt
mlir/lib/Dialect/Vector/EDSC/Builders.cpp
mlir/lib/Dialect/Vector/VectorOps.cpp
mlir/lib/Dialect/Vector/VectorTransforms.cpp
mlir/lib/Dialect/Vector/VectorUtils.cpp
mlir/test/Dialect/Vector/canonicalize.mlir
mlir/test/Dialect/Vector/invalid.mlir
mlir/test/Dialect/Vector/ops.mlir
mlir/test/Dialect/Vector/vector-contract-transforms.mlir
mlir/test/Dialect/Vector/vector-slices-transforms.mlir
mlir/test/Dialect/Vector/vector-transforms.mlir
Modified:
mlir/docs/Dialects/Vector.md
mlir/include/mlir/Dialect/CMakeLists.txt
mlir/include/mlir/InitAllDialects.h
mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt
mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
mlir/lib/Conversion/VectorToLoops/ConvertVectorToLoops.cpp
mlir/lib/Dialect/CMakeLists.txt
mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
mlir/lib/Dialect/Linalg/Transforms/LinalgTransforms.cpp
mlir/lib/Transforms/CMakeLists.txt
mlir/lib/Transforms/Vectorize.cpp
mlir/test/EDSC/CMakeLists.txt
mlir/test/EDSC/builder-api-test.cpp
mlir/test/lib/DeclarativeTransforms/TestVectorTransformPatterns.td
mlir/test/lib/Transforms/CMakeLists.txt
mlir/test/lib/Transforms/TestVectorTransforms.cpp
mlir/test/lib/Transforms/TestVectorizationUtils.cpp
Removed:
mlir/include/mlir/Dialect/VectorOps/CMakeLists.txt
mlir/include/mlir/Dialect/VectorOps/EDSC/Builders.h
mlir/include/mlir/Dialect/VectorOps/EDSC/Intrinsics.h
mlir/include/mlir/Dialect/VectorOps/VectorOps.h
mlir/include/mlir/Dialect/VectorOps/VectorOps.td
mlir/include/mlir/Dialect/VectorOps/VectorTransformPatterns.td
mlir/include/mlir/Dialect/VectorOps/VectorTransforms.h
mlir/include/mlir/Dialect/VectorOps/VectorUtils.h
mlir/lib/Dialect/VectorOps/CMakeLists.txt
mlir/lib/Dialect/VectorOps/EDSC/Builders.cpp
mlir/lib/Dialect/VectorOps/VectorOps.cpp
mlir/lib/Dialect/VectorOps/VectorTransforms.cpp
mlir/lib/Dialect/VectorOps/VectorUtils.cpp
mlir/test/Dialect/VectorOps/canonicalize.mlir
mlir/test/Dialect/VectorOps/invalid.mlir
mlir/test/Dialect/VectorOps/ops.mlir
mlir/test/Dialect/VectorOps/vector-contract-transforms.mlir
mlir/test/Dialect/VectorOps/vector-slices-transforms.mlir
mlir/test/Dialect/VectorOps/vector-transforms.mlir
################################################################################
diff --git a/mlir/docs/Dialects/Vector.md b/mlir/docs/Dialects/Vector.md
index 1c00269c615a..565060795083 100644
--- a/mlir/docs/Dialects/Vector.md
+++ b/mlir/docs/Dialects/Vector.md
@@ -91,7 +91,7 @@ captured by LLVM peephole optimizations of on
diff erent types that core MLIR
supports (e.g. Scalable Vectors) are welcome future extensions.
### Virtual Vector Ops
-Some existing Standard and VectorOps Dialect on `n-D` `vector` types comprise:
+Some existing Standard and Vector Dialect on `n-D` `vector` types comprise:
```
%2 = std.addf %0, %1 : vector<3x7x8xf32> // -> vector<3x7x8xf32>
%2 = std.mulf %0, %1 : vector<3x7x8xf32> // -> vector<3x7x8xf32>
@@ -112,9 +112,9 @@ vector.transfer_write %f1, %A[%i0, %i1, %i2, %i3]
vector<5x4x3xf32>, memref<?x?x?x?xf32>
```
-The list of VectorOps is currently undergoing evolutions and is best kept
+The list of Vector is currently undergoing evolutions and is best kept
track of by following the evolution of the
-[VectorOps.td](https://github.com/llvm/llvm-project/blob/master/mlir/include/mlir/Dialect/VectorOps/VectorOps.td)
+[VectorOps.td](https://github.com/llvm/llvm-project/blob/master/mlir/include/mlir/Dialect/Vector/VectorOps.td)
ODS file (markdown documentation is automatically generated locally when
building and populates the [Vector
doc](https://github.com/llvm/llvm-project/blob/master/mlir/docs/Dialects/Vector.md)). Recent
diff --git a/mlir/include/mlir/Dialect/CMakeLists.txt b/mlir/include/mlir/Dialect/CMakeLists.txt
index c35f68dfcf7d..27cbe9378346 100644
--- a/mlir/include/mlir/Dialect/CMakeLists.txt
+++ b/mlir/include/mlir/Dialect/CMakeLists.txt
@@ -9,4 +9,4 @@ add_subdirectory(Quant)
add_subdirectory(Shape)
add_subdirectory(SPIRV)
add_subdirectory(StandardOps)
-add_subdirectory(VectorOps)
+add_subdirectory(Vector)
diff --git a/mlir/include/mlir/Dialect/VectorOps/CMakeLists.txt b/mlir/include/mlir/Dialect/Vector/CMakeLists.txt
similarity index 100%
rename from mlir/include/mlir/Dialect/VectorOps/CMakeLists.txt
rename to mlir/include/mlir/Dialect/Vector/CMakeLists.txt
diff --git a/mlir/include/mlir/Dialect/VectorOps/EDSC/Builders.h b/mlir/include/mlir/Dialect/Vector/EDSC/Builders.h
similarity index 97%
rename from mlir/include/mlir/Dialect/VectorOps/EDSC/Builders.h
rename to mlir/include/mlir/Dialect/Vector/EDSC/Builders.h
index ba6e6b1ebc9e..024ae93a8f32 100644
--- a/mlir/include/mlir/Dialect/VectorOps/EDSC/Builders.h
+++ b/mlir/include/mlir/Dialect/Vector/EDSC/Builders.h
@@ -14,7 +14,7 @@
#define MLIR_DIALECT_VECTOR_EDSC_BUILDERS_H_
#include "mlir/Dialect/Utils/StructuredOpsUtils.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/EDSC/Builders.h"
#include "mlir/EDSC/Intrinsics.h"
#include "mlir/IR/AffineExpr.h"
diff --git a/mlir/include/mlir/Dialect/VectorOps/EDSC/Intrinsics.h b/mlir/include/mlir/Dialect/Vector/EDSC/Intrinsics.h
similarity index 69%
rename from mlir/include/mlir/Dialect/VectorOps/EDSC/Intrinsics.h
rename to mlir/include/mlir/Dialect/Vector/EDSC/Intrinsics.h
index afa830dc19c9..c307721607df 100644
--- a/mlir/include/mlir/Dialect/VectorOps/EDSC/Intrinsics.h
+++ b/mlir/include/mlir/Dialect/Vector/EDSC/Intrinsics.h
@@ -1,14 +1,14 @@
-//===- Intrinsics.h - MLIR EDSC Intrinsics for VectorOps --------*- C++ -*-===//
+//===- Intrinsics.h - MLIR EDSC Intrinsics for Vector -----------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
-#ifndef MLIR_DIALECT_VECTOROPS_EDSC_INTRINSICS_H_
-#define MLIR_DIALECT_VECTOROPS_EDSC_INTRINSICS_H_
+#ifndef MLIR_DIALECT_VECTOR_EDSC_INTRINSICS_H_
+#define MLIR_DIALECT_VECTOR_EDSC_INTRINSICS_H_
-#include "mlir/Dialect/VectorOps/EDSC/Builders.h"
+#include "mlir/Dialect/Vector/EDSC/Builders.h"
namespace mlir {
namespace edsc {
@@ -22,4 +22,4 @@ using vector_print = OperationBuilder<vector::PrintOp>;
} // namespace edsc
} // namespace mlir
-#endif // MLIR_DIALECT_VECTOROPS_EDSC_INTRINSICS_H_
+#endif // MLIR_DIALECT_VECTOR_EDSC_INTRINSICS_H_
diff --git a/mlir/include/mlir/Dialect/VectorOps/VectorOps.h b/mlir/include/mlir/Dialect/Vector/VectorOps.h
similarity index 91%
rename from mlir/include/mlir/Dialect/VectorOps/VectorOps.h
rename to mlir/include/mlir/Dialect/Vector/VectorOps.h
index e13d480b7a9f..1aaa75290931 100644
--- a/mlir/include/mlir/Dialect/VectorOps/VectorOps.h
+++ b/mlir/include/mlir/Dialect/Vector/VectorOps.h
@@ -10,8 +10,8 @@
//
//===----------------------------------------------------------------------===//
-#ifndef MLIR_DIALECT_VECTOROPS_VECTOROPS_H
-#define MLIR_DIALECT_VECTOROPS_VECTOROPS_H
+#ifndef MLIR_DIALECT_VECTOR_VECTOROPS_H
+#define MLIR_DIALECT_VECTOR_VECTOROPS_H
#include "mlir/IR/Attributes.h"
#include "mlir/IR/Dialect.h"
@@ -61,11 +61,11 @@ IntegerType getVectorSubscriptType(Builder &builder);
ArrayAttr getVectorSubscriptAttr(Builder &b, ArrayRef<int64_t> values);
#define GET_OP_CLASSES
-#include "mlir/Dialect/VectorOps/VectorOps.h.inc"
+#include "mlir/Dialect/Vector/VectorOps.h.inc"
-#include "mlir/Dialect/VectorOps/VectorOpsDialect.h.inc"
+#include "mlir/Dialect/Vector/VectorOpsDialect.h.inc"
} // end namespace vector
} // end namespace mlir
-#endif // MLIR_DIALECT_VECTOROPS_VECTOROPS_H
+#endif // MLIR_DIALECT_VECTOR_VECTOROPS_H
diff --git a/mlir/include/mlir/Dialect/VectorOps/VectorOps.td b/mlir/include/mlir/Dialect/Vector/VectorOps.td
similarity index 99%
rename from mlir/include/mlir/Dialect/VectorOps/VectorOps.td
rename to mlir/include/mlir/Dialect/Vector/VectorOps.td
index 88b6e1e993e6..2a791365db4f 100644
--- a/mlir/include/mlir/Dialect/VectorOps/VectorOps.td
+++ b/mlir/include/mlir/Dialect/Vector/VectorOps.td
@@ -16,7 +16,7 @@
include "mlir/Dialect/AffineOps/AffineOpsBase.td"
include "mlir/Interfaces/SideEffects.td"
-def VectorOps_Dialect : Dialect {
+def Vector_Dialect : Dialect {
let name = "vector";
let cppNamespace = "vector";
let hasConstantMaterializer = 1;
@@ -24,7 +24,7 @@ def VectorOps_Dialect : Dialect {
// Base class for Vector dialect ops.
class Vector_Op<string mnemonic, list<OpTrait> traits = []> :
- Op<VectorOps_Dialect, mnemonic, traits> {
+ Op<Vector_Dialect, mnemonic, traits> {
// For every vector op, there needs to be a:
// * void print(OpAsmPrinter &p, ${C++ class of Op} op)
// * LogicalResult verify(${C++ class of Op} op)
@@ -433,7 +433,7 @@ def Vector_ExtractSlicesOp :
}
def Vector_FMAOp :
- Op<VectorOps_Dialect, "fma", [NoSideEffect,
+ Op<Vector_Dialect, "fma", [NoSideEffect,
AllTypesMatch<["lhs", "rhs", "acc", "result"]>]>,
Arguments<(ins AnyVector:$lhs, AnyVector:$rhs, AnyVector:$acc)>,
Results<(outs AnyVector:$result)> {
diff --git a/mlir/include/mlir/Dialect/VectorOps/VectorTransformPatterns.td b/mlir/include/mlir/Dialect/Vector/VectorTransformPatterns.td
similarity index 100%
rename from mlir/include/mlir/Dialect/VectorOps/VectorTransformPatterns.td
rename to mlir/include/mlir/Dialect/Vector/VectorTransformPatterns.td
diff --git a/mlir/include/mlir/Dialect/VectorOps/VectorTransforms.h b/mlir/include/mlir/Dialect/Vector/VectorTransforms.h
similarity index 95%
rename from mlir/include/mlir/Dialect/VectorOps/VectorTransforms.h
rename to mlir/include/mlir/Dialect/Vector/VectorTransforms.h
index 91cbad4f412b..aa2a94cdfbb0 100644
--- a/mlir/include/mlir/Dialect/VectorOps/VectorTransforms.h
+++ b/mlir/include/mlir/Dialect/Vector/VectorTransforms.h
@@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
-#ifndef DIALECT_VECTOROPS_VECTORTRANSFORMS_H_
-#define DIALECT_VECTOROPS_VECTORTRANSFORMS_H_
+#ifndef DIALECT_VECTOR_VECTORTRANSFORMS_H_
+#define DIALECT_VECTOR_VECTORTRANSFORMS_H_
#include "mlir/IR/PatternMatch.h"
@@ -71,4 +71,4 @@ unrollSingleResultOpMatchingType(PatternRewriter &builder, Operation *op,
} // namespace vector
} // namespace mlir
-#endif // DIALECT_VECTOROPS_VECTORTRANSFORMS_H_
+#endif // DIALECT_VECTOR_VECTORTRANSFORMS_H_
diff --git a/mlir/include/mlir/Dialect/VectorOps/VectorUtils.h b/mlir/include/mlir/Dialect/Vector/VectorUtils.h
similarity index 97%
rename from mlir/include/mlir/Dialect/VectorOps/VectorUtils.h
rename to mlir/include/mlir/Dialect/Vector/VectorUtils.h
index 6d1942837d53..4bc03e4943fd 100644
--- a/mlir/include/mlir/Dialect/VectorOps/VectorUtils.h
+++ b/mlir/include/mlir/Dialect/Vector/VectorUtils.h
@@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
-#ifndef MLIR_DIALECT_VECTOROPS_VECTORUTILS_H_
-#define MLIR_DIALECT_VECTOROPS_VECTORUTILS_H_
+#ifndef MLIR_DIALECT_VECTOR_VECTORUTILS_H_
+#define MLIR_DIALECT_VECTOR_VECTORUTILS_H_
#include "mlir/Support/LLVM.h"
@@ -155,4 +155,4 @@ bool operatesOnSuperVectorsOf(Operation &op, VectorType subVectorType);
} // end namespace matcher
} // end namespace mlir
-#endif // MLIR_DIALECT_VECTOROPS_VECTORUTILS_H_
+#endif // MLIR_DIALECT_VECTOR_VECTORUTILS_H_
diff --git a/mlir/include/mlir/InitAllDialects.h b/mlir/include/mlir/InitAllDialects.h
index 690e421f8abc..c0a7ca04081f 100644
--- a/mlir/include/mlir/InitAllDialects.h
+++ b/mlir/include/mlir/InitAllDialects.h
@@ -28,7 +28,7 @@
#include "mlir/Dialect/SPIRV/SPIRVDialect.h"
#include "mlir/Dialect/Shape/IR/Shape.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/IR/Dialect.h"
namespace mlir {
@@ -47,7 +47,7 @@ inline void registerAllDialects() {
registerDialect<quant::QuantizationDialect>();
registerDialect<spirv::SPIRVDialect>();
registerDialect<StandardOpsDialect>();
- registerDialect<vector::VectorOpsDialect>();
+ registerDialect<vector::VectorDialect>();
registerDialect<NVVM::NVVMDialect>();
registerDialect<ROCDL::ROCDLDialect>();
registerDialect<SDBMDialect>();
diff --git a/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt b/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt
index 0da51e850cc1..734af0b96a39 100644
--- a/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt
+++ b/mlir/lib/Conversion/VectorToLLVM/CMakeLists.txt
@@ -7,7 +7,7 @@ add_mlir_conversion_library(MLIRVectorToLLVM
set(LIBS
MLIRLLVMIR
MLIRStandardToLLVM
- MLIRVectorOps
+ MLIRVector
MLIRTransforms
LLVMCore
LLVMSupport
diff --git a/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp b/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
index f967793c36f0..290fa4c3b109 100644
--- a/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
+++ b/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
@@ -12,7 +12,7 @@
#include "mlir/Conversion/StandardToLLVM/ConvertStandardToLLVMPass.h"
#include "mlir/Dialect/LLVMIR/LLVMDialect.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/IR/Attributes.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/MLIRContext.h"
diff --git a/mlir/lib/Conversion/VectorToLoops/ConvertVectorToLoops.cpp b/mlir/lib/Conversion/VectorToLoops/ConvertVectorToLoops.cpp
index 9414b275e96d..5736c1d747f4 100644
--- a/mlir/lib/Conversion/VectorToLoops/ConvertVectorToLoops.cpp
+++ b/mlir/lib/Conversion/VectorToLoops/ConvertVectorToLoops.cpp
@@ -16,7 +16,7 @@
#include "mlir/Dialect/AffineOps/EDSC/Intrinsics.h"
#include "mlir/Dialect/LoopOps/EDSC/Builders.h"
#include "mlir/Dialect/StandardOps/EDSC/Intrinsics.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/AffineMap.h"
#include "mlir/IR/Attributes.h"
diff --git a/mlir/lib/Dialect/CMakeLists.txt b/mlir/lib/Dialect/CMakeLists.txt
index 1371fcd3baf0..fe99044a90e6 100644
--- a/mlir/lib/Dialect/CMakeLists.txt
+++ b/mlir/lib/Dialect/CMakeLists.txt
@@ -10,7 +10,7 @@ add_subdirectory(SDBM)
add_subdirectory(Shape)
add_subdirectory(SPIRV)
add_subdirectory(StandardOps)
-add_subdirectory(VectorOps)
+add_subdirectory(Vector)
set(LLVM_OPTIONAL_SOURCES
Traits.cpp
diff --git a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
index 7a864ad2def2..82e36f8a00b1 100644
--- a/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
+++ b/mlir/lib/Dialect/Linalg/Transforms/CMakeLists.txt
@@ -27,5 +27,5 @@ target_link_libraries(MLIRLinalgTransforms
MLIRStandardOps
MLIRStandardToLLVM
MLIRTransformUtils
- MLIRVectorOps
+ MLIRVector
)
diff --git a/mlir/lib/Dialect/Linalg/Transforms/LinalgTransforms.cpp b/mlir/lib/Dialect/Linalg/Transforms/LinalgTransforms.cpp
index 2b0654c219a0..8511c8efffce 100644
--- a/mlir/lib/Dialect/Linalg/Transforms/LinalgTransforms.cpp
+++ b/mlir/lib/Dialect/Linalg/Transforms/LinalgTransforms.cpp
@@ -16,7 +16,7 @@
#include "mlir/Dialect/Linalg/Utils/Utils.h"
#include "mlir/Dialect/StandardOps/EDSC/Intrinsics.h"
#include "mlir/Dialect/Utils/StructuredOpsUtils.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/Matchers.h"
#include "mlir/IR/PatternMatch.h"
diff --git a/mlir/lib/Dialect/VectorOps/CMakeLists.txt b/mlir/lib/Dialect/Vector/CMakeLists.txt
similarity index 70%
rename from mlir/lib/Dialect/VectorOps/CMakeLists.txt
rename to mlir/lib/Dialect/Vector/CMakeLists.txt
index ad32f271a90f..3e1d8de0d3ba 100644
--- a/mlir/lib/Dialect/VectorOps/CMakeLists.txt
+++ b/mlir/lib/Dialect/Vector/CMakeLists.txt
@@ -1,17 +1,17 @@
-add_mlir_dialect_library(MLIRVectorOps
+add_mlir_dialect_library(MLIRVector
VectorOps.cpp
VectorTransforms.cpp
VectorUtils.cpp
EDSC/Builders.cpp
ADDITIONAL_HEADER_DIRS
- ${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/VectorOps
+ ${MLIR_MAIN_INCLUDE_DIR}/mlir/Dialect/Vector
DEPENDS
MLIRVectorOpsIncGen
MLIRVectorTransformPatternsIncGen
)
-target_link_libraries(MLIRVectorOps
+target_link_libraries(MLIRVector
PUBLIC
MLIREDSC
MLIRIR
diff --git a/mlir/lib/Dialect/VectorOps/EDSC/Builders.cpp b/mlir/lib/Dialect/Vector/EDSC/Builders.cpp
similarity index 91%
rename from mlir/lib/Dialect/VectorOps/EDSC/Builders.cpp
rename to mlir/lib/Dialect/Vector/EDSC/Builders.cpp
index 163000f1cac1..b1f94655ab28 100644
--- a/mlir/lib/Dialect/VectorOps/EDSC/Builders.cpp
+++ b/mlir/lib/Dialect/Vector/EDSC/Builders.cpp
@@ -6,9 +6,9 @@
//
//===----------------------------------------------------------------------===//
-#include "mlir/Dialect/VectorOps/EDSC/Builders.h"
-#include "mlir/Dialect/VectorOps/EDSC/Intrinsics.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/EDSC/Builders.h"
+#include "mlir/Dialect/Vector/EDSC/Intrinsics.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/EDSC/Builders.h"
#include "mlir/EDSC/Intrinsics.h"
#include "mlir/IR/AffineExpr.h"
diff --git a/mlir/lib/Dialect/VectorOps/VectorOps.cpp b/mlir/lib/Dialect/Vector/VectorOps.cpp
similarity index 99%
rename from mlir/lib/Dialect/VectorOps/VectorOps.cpp
rename to mlir/lib/Dialect/Vector/VectorOps.cpp
index 5afa944c776b..14831b9f38ae 100644
--- a/mlir/lib/Dialect/VectorOps/VectorOps.cpp
+++ b/mlir/lib/Dialect/Vector/VectorOps.cpp
@@ -11,10 +11,10 @@
//
//===----------------------------------------------------------------------===//
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Utils/StructuredOpsUtils.h"
-#include "mlir/Dialect/VectorOps/VectorUtils.h"
+#include "mlir/Dialect/Vector/VectorUtils.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/AffineMap.h"
#include "mlir/IR/Builders.h"
@@ -32,20 +32,20 @@ using namespace mlir;
using namespace mlir::vector;
//===----------------------------------------------------------------------===//
-// VectorOpsDialect
+// VectorDialect
//===----------------------------------------------------------------------===//
-VectorOpsDialect::VectorOpsDialect(MLIRContext *context)
+VectorDialect::VectorDialect(MLIRContext *context)
: Dialect(getDialectNamespace(), context) {
addOperations<
#define GET_OP_LIST
-#include "mlir/Dialect/VectorOps/VectorOps.cpp.inc"
+#include "mlir/Dialect/Vector/VectorOps.cpp.inc"
>();
}
/// Materialize a single constant operation from a given attribute value with
/// the desired resultant type.
-Operation *VectorOpsDialect::materializeConstant(OpBuilder &builder,
+Operation *VectorDialect::materializeConstant(OpBuilder &builder,
Attribute value, Type type,
Location loc) {
return builder.create<ConstantOp>(loc, type, value);
@@ -1249,7 +1249,7 @@ static LogicalResult verifyTransferOp(Operation *op, MemRefType memrefType,
if (memrefVecEltRank > resultVecRank)
return op->emitOpError(
"requires memref vector element and vector result ranks to match.");
- // TODO(b/146516564) Move this to isSuffix in VectorOps/Utils.h.
+ // TODO(b/146516564) Move this to isSuffix in Vector/Utils.h.
unsigned rankOffset = resultVecRank - memrefVecEltRank;
auto memrefVecEltShape = memrefVectorElementType.getShape();
auto resultVecShape = vectorType.getShape();
@@ -1657,7 +1657,7 @@ namespace mlir {
namespace vector {
#define GET_OP_CLASSES
-#include "mlir/Dialect/VectorOps/VectorOps.cpp.inc"
+#include "mlir/Dialect/Vector/VectorOps.cpp.inc"
} // namespace vector
} // namespace mlir
diff --git a/mlir/lib/Dialect/VectorOps/VectorTransforms.cpp b/mlir/lib/Dialect/Vector/VectorTransforms.cpp
similarity index 99%
rename from mlir/lib/Dialect/VectorOps/VectorTransforms.cpp
rename to mlir/lib/Dialect/Vector/VectorTransforms.cpp
index 4f6634d2be27..fb5749cfe727 100644
--- a/mlir/lib/Dialect/VectorOps/VectorTransforms.cpp
+++ b/mlir/lib/Dialect/Vector/VectorTransforms.cpp
@@ -15,9 +15,9 @@
#include "mlir/Dialect/AffineOps/AffineOps.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
#include "mlir/Dialect/Utils/StructuredOpsUtils.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
-#include "mlir/Dialect/VectorOps/VectorTransforms.h"
-#include "mlir/Dialect/VectorOps/VectorUtils.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorTransforms.h"
+#include "mlir/Dialect/Vector/VectorUtils.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/AffineMap.h"
#include "mlir/IR/Attributes.h"
diff --git a/mlir/lib/Dialect/VectorOps/VectorUtils.cpp b/mlir/lib/Dialect/Vector/VectorUtils.cpp
similarity index 98%
rename from mlir/lib/Dialect/VectorOps/VectorUtils.cpp
rename to mlir/lib/Dialect/Vector/VectorUtils.cpp
index 0e76e853f258..1cace25b9835 100644
--- a/mlir/lib/Dialect/VectorOps/VectorUtils.cpp
+++ b/mlir/lib/Dialect/Vector/VectorUtils.cpp
@@ -6,15 +6,15 @@
//
//===----------------------------------------------------------------------===//
//
-// This file implements utility methods for working with the VectorOps dialect.
+// This file implements utility methods for working with the Vector dialect.
//
//===----------------------------------------------------------------------===//
-#include "mlir/Dialect/VectorOps/VectorUtils.h"
+#include "mlir/Dialect/Vector/VectorUtils.h"
#include "mlir/Analysis/LoopAnalysis.h"
#include "mlir/Dialect/AffineOps/AffineOps.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/IntegerSet.h"
#include "mlir/IR/Operation.h"
diff --git a/mlir/lib/Transforms/CMakeLists.txt b/mlir/lib/Transforms/CMakeLists.txt
index 1cd89a334eef..6d1d7b41d568 100644
--- a/mlir/lib/Transforms/CMakeLists.txt
+++ b/mlir/lib/Transforms/CMakeLists.txt
@@ -39,5 +39,5 @@ target_link_libraries(MLIRTransforms
MLIRLoopOps
MLIRPass
MLIRTransformUtils
- MLIRVectorOps
+ MLIRVector
)
diff --git a/mlir/lib/Transforms/Vectorize.cpp b/mlir/lib/Transforms/Vectorize.cpp
index c5d0f57daf36..75a7d4d5cf6b 100644
--- a/mlir/lib/Transforms/Vectorize.cpp
+++ b/mlir/lib/Transforms/Vectorize.cpp
@@ -17,8 +17,8 @@
#include "mlir/Analysis/Utils.h"
#include "mlir/Dialect/AffineOps/AffineOps.h"
#include "mlir/Dialect/StandardOps/IR/Ops.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
-#include "mlir/Dialect/VectorOps/VectorUtils.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorUtils.h"
#include "mlir/IR/AffineExpr.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/Location.h"
diff --git a/mlir/test/Dialect/VectorOps/canonicalize.mlir b/mlir/test/Dialect/Vector/canonicalize.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/canonicalize.mlir
rename to mlir/test/Dialect/Vector/canonicalize.mlir
diff --git a/mlir/test/Dialect/VectorOps/invalid.mlir b/mlir/test/Dialect/Vector/invalid.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/invalid.mlir
rename to mlir/test/Dialect/Vector/invalid.mlir
diff --git a/mlir/test/Dialect/VectorOps/ops.mlir b/mlir/test/Dialect/Vector/ops.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/ops.mlir
rename to mlir/test/Dialect/Vector/ops.mlir
diff --git a/mlir/test/Dialect/VectorOps/vector-contract-transforms.mlir b/mlir/test/Dialect/Vector/vector-contract-transforms.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/vector-contract-transforms.mlir
rename to mlir/test/Dialect/Vector/vector-contract-transforms.mlir
diff --git a/mlir/test/Dialect/VectorOps/vector-slices-transforms.mlir b/mlir/test/Dialect/Vector/vector-slices-transforms.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/vector-slices-transforms.mlir
rename to mlir/test/Dialect/Vector/vector-slices-transforms.mlir
diff --git a/mlir/test/Dialect/VectorOps/vector-transforms.mlir b/mlir/test/Dialect/Vector/vector-transforms.mlir
similarity index 100%
rename from mlir/test/Dialect/VectorOps/vector-transforms.mlir
rename to mlir/test/Dialect/Vector/vector-transforms.mlir
diff --git a/mlir/test/EDSC/CMakeLists.txt b/mlir/test/EDSC/CMakeLists.txt
index b922c594dffd..c3c0cf35497b 100644
--- a/mlir/test/EDSC/CMakeLists.txt
+++ b/mlir/test/EDSC/CMakeLists.txt
@@ -14,7 +14,7 @@ target_link_libraries(mlir-edsc-builder-api-test
MLIRLoopOps
MLIRStandardOps
MLIRTransforms
- MLIRVectorOps
+ MLIRVector
LLVMCore
LLVMSupport
)
@@ -26,6 +26,6 @@ whole_archive_link(mlir-edsc-builder-api-test
MLIRLinalgOps
MLIRLoopOps
MLIRStandardOps
- MLIRVectorOps
+ MLIRVector
MLIRTransforms
)
diff --git a/mlir/test/EDSC/builder-api-test.cpp b/mlir/test/EDSC/builder-api-test.cpp
index 69f615e6434c..b60d5894df03 100644
--- a/mlir/test/EDSC/builder-api-test.cpp
+++ b/mlir/test/EDSC/builder-api-test.cpp
@@ -12,7 +12,7 @@
#include "mlir/Dialect/Linalg/EDSC/Intrinsics.h"
#include "mlir/Dialect/LoopOps/EDSC/Builders.h"
#include "mlir/Dialect/StandardOps/EDSC/Intrinsics.h"
-#include "mlir/Dialect/VectorOps/EDSC/Intrinsics.h"
+#include "mlir/Dialect/Vector/EDSC/Intrinsics.h"
#include "mlir/EDSC/Builders.h"
#include "mlir/EDSC/Intrinsics.h"
#include "mlir/IR/AffineExpr.h"
@@ -42,7 +42,7 @@ static MLIRContext &globalContext() {
registerDialect<linalg::LinalgDialect>();
registerDialect<loop::LoopOpsDialect>();
registerDialect<StandardOpsDialect>();
- registerDialect<vector::VectorOpsDialect>();
+ registerDialect<vector::VectorDialect>();
return true;
}();
(void)init_once;
diff --git a/mlir/test/lib/DeclarativeTransforms/TestVectorTransformPatterns.td b/mlir/test/lib/DeclarativeTransforms/TestVectorTransformPatterns.td
index e75a109376fa..49a3499b0bad 100644
--- a/mlir/test/lib/DeclarativeTransforms/TestVectorTransformPatterns.td
+++ b/mlir/test/lib/DeclarativeTransforms/TestVectorTransformPatterns.td
@@ -15,8 +15,8 @@
#define TEST_VECTOR_TRANSFORMS_PATTERNS
include "mlir/Dialect/StandardOps/IR/Ops.td"
-include "mlir/Dialect/VectorOps/VectorOps.td"
-include "mlir/Dialect/VectorOps/VectorTransformPatterns.td"
+include "mlir/Dialect/Vector/VectorOps.td"
+include "mlir/Dialect/Vector/VectorTransformPatterns.td"
def : Pat<(AddFOp:$op_results $a, $b),
(UnrollVectorOp<[2, 2]> $op_results, $a, $b),
diff --git a/mlir/test/lib/Transforms/CMakeLists.txt b/mlir/test/lib/Transforms/CMakeLists.txt
index e98623c7f1ba..bc737a0a119f 100644
--- a/mlir/test/lib/Transforms/CMakeLists.txt
+++ b/mlir/test/lib/Transforms/CMakeLists.txt
@@ -48,5 +48,5 @@ target_link_libraries(MLIRTestTransforms
MLIRTestDialect
MLIRTransformUtils
MLIRVectorToLoops
- MLIRVectorOps
+ MLIRVector
)
diff --git a/mlir/test/lib/Transforms/TestVectorTransforms.cpp b/mlir/test/lib/Transforms/TestVectorTransforms.cpp
index aa3d960ce090..fc6095fb1fb1 100644
--- a/mlir/test/lib/Transforms/TestVectorTransforms.cpp
+++ b/mlir/test/lib/Transforms/TestVectorTransforms.cpp
@@ -9,8 +9,8 @@
#include <type_traits>
#include "mlir/Dialect/StandardOps/IR/Ops.h"
-#include "mlir/Dialect/VectorOps/VectorOps.h"
-#include "mlir/Dialect/VectorOps/VectorTransforms.h"
+#include "mlir/Dialect/Vector/VectorOps.h"
+#include "mlir/Dialect/Vector/VectorTransforms.h"
#include "mlir/IR/PatternMatch.h"
#include "mlir/Pass/Pass.h"
diff --git a/mlir/test/lib/Transforms/TestVectorizationUtils.cpp b/mlir/test/lib/Transforms/TestVectorizationUtils.cpp
index 50086e5c333a..4ae4509bc56d 100644
--- a/mlir/test/lib/Transforms/TestVectorizationUtils.cpp
+++ b/mlir/test/lib/Transforms/TestVectorizationUtils.cpp
@@ -14,7 +14,7 @@
#include "mlir/Analysis/NestedMatcher.h"
#include "mlir/Analysis/SliceAnalysis.h"
#include "mlir/Dialect/AffineOps/AffineOps.h"
-#include "mlir/Dialect/VectorOps/VectorUtils.h"
+#include "mlir/Dialect/Vector/VectorUtils.h"
#include "mlir/IR/Builders.h"
#include "mlir/IR/Diagnostics.h"
#include "mlir/IR/StandardTypes.h"
More information about the Mlir-commits
mailing list