[flang-commits] [PATCH] D138190: [flang] Lower ArrayRef to hlfir.designate
Slava Zakharin via Phabricator via flang-commits
flang-commits at lists.llvm.org
Thu Nov 17 13:09:43 PST 2022
vzakhari added inline comments.
================
Comment at: flang/lib/Lower/ConvertExprToHLFIR.cpp:63
private:
- hlfir::EntityWithAttributes
+ using LoweredSubscripts = llvm::SmallVector<hlfir::DesignateOp::Subscript>;
+
----------------
Can you please use some static size for `SmallVector`? There is an assertion in `SmallVector` implementation that may kick in if size of `Subsctipt` type increases or if the constant limit in `SmallVector` is changed for whatever reason.
================
Comment at: flang/lib/Lower/ConvertExprToHLFIR.cpp:71
+ fir::FortranVariableOpInterface base;
+ llvm::SmallVector<hlfir::DesignateOp::Subscript> subscripts;
+ mlir::Value resultShape;
----------------
I guess you may use `LoweredSubscripts` here.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D138190/new/
https://reviews.llvm.org/D138190
More information about the flang-commits
mailing list