[Mlir-commits] [mlir] 609f5e0 - [mlir] Rename 'setInsertionPointAfter' to avoid ambiguity

Diego Caballero llvmlistbot at llvm.org
Tue Sep 15 14:17:42 PDT 2020


Author: Diego Caballero
Date: 2020-09-15T13:58:42-07:00
New Revision: 609f5e050cea760694a46e126e5aa3f62660cae9

URL: https://github.com/llvm/llvm-project/commit/609f5e050cea760694a46e126e5aa3f62660cae9
DIFF: https://github.com/llvm/llvm-project/commit/609f5e050cea760694a46e126e5aa3f62660cae9.diff

LOG: [mlir] Rename 'setInsertionPointAfter' to avoid ambiguity

Rename 'setInsertionPointAfter(Value)' API to avoid ambiguity with
'setInsertionPointAfter(Operation *)' for SingleResult operations which
implicitly convert to Value (see D86756).

Differential Revision: https://reviews.llvm.org/D87155

Added: 
    

Modified: 
    mlir/include/mlir/IR/Builders.h
    mlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/include/mlir/IR/Builders.h b/mlir/include/mlir/IR/Builders.h
index 0c30869752ea3..ccf11489add07 100644
--- a/mlir/include/mlir/IR/Builders.h
+++ b/mlir/include/mlir/IR/Builders.h
@@ -333,7 +333,7 @@ class OpBuilder : public Builder {
   /// defining operation. This will cause subsequent insertions to go right
   /// after it. Otherwise, value is a BlockArgumen. Sets the insertion point to
   /// the start of its block.
-  void setInsertionPointAfter(Value val) {
+  void setInsertionPointAfterValue(Value val) {
     if (Operation *op = val.getDefiningOp()) {
       setInsertionPointAfter(op);
     } else {

diff  --git a/mlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp b/mlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp
index 1de7b8957711a..ee52fe44830c4 100644
--- a/mlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp
+++ b/mlir/lib/Dialect/Affine/Transforms/SuperVectorize.cpp
@@ -945,7 +945,7 @@ static bool isUniformDefinition(Value value,
 /// vectorization strategy in 'state'.
 static Value vectorizeUniform(Value value, VectorizationState *state) {
   OpBuilder builder(value.getContext());
-  builder.setInsertionPointAfter(value);
+  builder.setInsertionPointAfterValue(value);
 
   auto vectorTy = getVectorType(value.getType(), state->strategy);
   auto bcast = builder.create<BroadcastOp>(value.getLoc(), vectorTy, value);


        


More information about the Mlir-commits mailing list