[PATCH] D110628: [fir][NFC] Rename operand of EmboxOp
Valentin Clement via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 28 08:01:18 PDT 2021
This revision was automatically updated to reflect the committed changes.
Closed by commit rGb38c04ab7f8f: [fir][NFC] Rename operand of EmboxOp (authored by clementval).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D110628/new/
https://reviews.llvm.org/D110628
Files:
flang/include/flang/Optimizer/Dialect/FIROps.td
flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
flang/lib/Optimizer/Dialect/FIROps.cpp
Index: flang/lib/Optimizer/Dialect/FIROps.cpp
===================================================================
--- flang/lib/Optimizer/Dialect/FIROps.cpp
+++ flang/lib/Optimizer/Dialect/FIROps.cpp
@@ -521,7 +521,7 @@
} else {
return op.emitOpError("LEN parameters require CHARACTER or derived type");
}
- for (auto lp : op.lenParams())
+ for (auto lp : op.typeparams())
if (!fir::isa_integer(lp.getType()))
return op.emitOpError("LEN parameters must be integral type");
}
Index: flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
===================================================================
--- flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
+++ flang/lib/Optimizer/CodeGen/PreCGRewrite.cpp
@@ -99,7 +99,7 @@
}
auto xbox = rewriter.create<cg::XEmboxOp>(
loc, embox.getType(), embox.memref(), shapeOpers, llvm::None,
- llvm::None, llvm::None, embox.lenParams());
+ llvm::None, llvm::None, embox.typeparams());
LLVM_DEBUG(llvm::dbgs() << "rewriting " << embox << " to " << xbox << '\n');
rewriter.replaceOp(embox, xbox.getOperation()->getResults());
return mlir::success();
@@ -128,7 +128,7 @@
}
auto xbox = rewriter.create<cg::XEmboxOp>(
loc, embox.getType(), embox.memref(), shapeOpers, shiftOpers,
- sliceOpers, subcompOpers, embox.lenParams());
+ sliceOpers, subcompOpers, embox.typeparams());
LLVM_DEBUG(llvm::dbgs() << "rewriting " << embox << " to " << xbox << '\n');
rewriter.replaceOp(embox, xbox.getOperation()->getResults());
return mlir::success();
Index: flang/include/flang/Optimizer/Dialect/FIROps.td
===================================================================
--- flang/include/flang/Optimizer/Dialect/FIROps.td
+++ flang/include/flang/Optimizer/Dialect/FIROps.td
@@ -1061,7 +1061,7 @@
- shape: emboxing an array may require shape information (an array's
lower bounds and extents may not be known until runtime),
- slice: an array section can be described with a slice triple,
- - lenParams: for emboxing a derived type with LEN type parameters,
+ - typeparams: for emboxing a derived type with LEN type parameters,
- accessMap: unused/experimental.
}];
@@ -1069,7 +1069,7 @@
AnyReferenceLike:$memref,
Optional<AnyShapeType>:$shape,
Optional<fir_SliceType>:$slice,
- Variadic<AnyIntegerType>:$lenParams,
+ Variadic<AnyIntegerType>:$typeparams,
OptionalAttr<AffineMapAttr>:$accessMap
);
@@ -1085,7 +1085,7 @@
];
let assemblyFormat = [{
- $memref (`(` $shape^ `)`)? (`[` $slice^ `]`)? (`typeparams` $lenParams^)?
+ $memref (`(` $shape^ `)`)? (`[` $slice^ `]`)? (`typeparams` $typeparams^)?
(`map` $accessMap^)? attr-dict `:` functional-type(operands, results)
}];
@@ -1094,8 +1094,8 @@
let extraClassDeclaration = [{
mlir::Value getShape() { return shape(); }
mlir::Value getSlice() { return slice(); }
- bool hasLenParams() { return !lenParams().empty(); }
- unsigned numLenParams() { return lenParams().size(); }
+ bool hasLenParams() { return !typeparams().empty(); }
+ unsigned numLenParams() { return typeparams().size(); }
}];
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D110628.375584.patch
Type: text/x-patch
Size: 3242 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20210928/8c4a3098/attachment.bin>
More information about the llvm-commits
mailing list