[flang-commits] [PATCH] D113273: [fir] TargetRewrite: Rewrite COMPLEX values
Kiran Chandramohan via Phabricator via flang-commits
flang-commits at lists.llvm.org
Mon Nov 8 02:02:58 PST 2021
kiranchandramohan added a comment.
In D113273#3114736 <https://reviews.llvm.org/D113273#3114736>, @rovka wrote:
> Good point, thanks for the link. I see that upstream it's fir::ComplexType: https://github.com/llvm/llvm-project/blob/9b6f264d2b09ab5e970e54f77119eb823f0fcc50/flang/lib/Lower/RTBuilder.h#L169
> The IR you posted is confusing because it contains both complex<f32> and fir.complex<4>. Are both valid, or are we moving away from one of them?
It seems the upstream llvm-project/flang link that you are pointing to here refers to `getModel<c_float_complex_t>()`. You can see that the fir-dev branch also uses `fir::ComplexType` for this function. It is for `getModel<std::complex<float>>()` that fir-dev uses `mlir::ComplexType()`.
https://github.com/flang-compiler/f18-llvm-project/blob/3aa4ab214082e718804d431139f59eb45df1f71d/flang/include/flang/Optimizer/Builder/Runtime/RTBuilder.h#L238
Regarding your question, I guess the FIR core team can provide an authoritative answer.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D113273/new/
https://reviews.llvm.org/D113273
More information about the flang-commits
mailing list