[flang-commits] [flang] 60527ce - [fir][NFC] Rename operand of ArrayCoorOp
Valentin Clement via flang-commits
flang-commits at lists.llvm.org
Wed Sep 29 01:38:44 PDT 2021
Author: Eric Schweitz
Date: 2021-09-29T10:31:38+02:00
New Revision: 60527cee95da028dc06771e1ed1e17f6c78d3f1a
URL: https://github.com/llvm/llvm-project/commit/60527cee95da028dc06771e1ed1e17f6c78d3f1a
DIFF: https://github.com/llvm/llvm-project/commit/60527cee95da028dc06771e1ed1e17f6c78d3f1a.diff
LOG: [fir][NFC] Rename operand of ArrayCoorOp
Rename `lenParams` to `typeparams` to be in sync with fir-dev.
This patch is part of the upstreaming effort from fir-dev branch.
Co-authored-by: Jean Perier <jperier at nvidia.com>
Co-authored-by: Valentin Clement <clementval at gmail.com>
Reviewed By: jeanPerier
Differential Revision: https://reviews.llvm.org/D110645
Added:
Modified:
flang/include/flang/Optimizer/Dialect/FIROps.td
flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
Removed:
################################################################################
diff --git a/flang/include/flang/Optimizer/Dialect/FIROps.td b/flang/include/flang/Optimizer/Dialect/FIROps.td
index cb0bee24a0902..279699b97df95 100644
--- a/flang/include/flang/Optimizer/Dialect/FIROps.td
+++ b/flang/include/flang/Optimizer/Dialect/FIROps.td
@@ -1849,16 +1849,17 @@ def fir_ArrayCoorOp : fir_Op<"array_coor",
Optional<AnyShapeOrShiftType>:$shape,
Optional<fir_SliceType>:$slice,
Variadic<AnyCoordinateType>:$indices,
- Variadic<AnyIntegerType>:$lenParams
+ Variadic<AnyIntegerType>:$typeparams
);
let results = (outs fir_ReferenceType);
let assemblyFormat = [{
- $memref (`(`$shape^`)`)? (`[`$slice^`]`)? $indices (`typeparams` $lenParams^)? attr-dict `:` functional-type(operands, results)
+ $memref (`(`$shape^`)`)? (`[`$slice^`]`)? $indices (`typeparams`
+ $typeparams^)? attr-dict `:` functional-type(operands, results)
}];
- let verifier = [{ return ::verify(*this); }];
+ let verifier = "return ::verify(*this);";
}
def fir_CoordinateOp : fir_Op<"coordinate_of", [NoSideEffect]> {
diff --git a/flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp b/flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
index 448d5459db56a..f77685de913ae 100644
--- a/flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
+++ b/flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
@@ -222,7 +222,7 @@ class ArrayCoorConversion : public mlir::OpRewritePattern<ArrayCoorOp> {
}
auto xArrCoor = rewriter.create<cg::XArrayCoorOp>(
loc, arrCoor.getType(), arrCoor.memref(), shapeOpers, shiftOpers,
- sliceOpers, subcompOpers, arrCoor.indices(), arrCoor.lenParams());
+ sliceOpers, subcompOpers, arrCoor.indices(), arrCoor.typeparams());
LLVM_DEBUG(llvm::dbgs()
<< "rewriting " << arrCoor << " to " << xArrCoor << '\n');
rewriter.replaceOp(arrCoor, xArrCoor.getOperation()->getResults());
More information about the flang-commits
mailing list