[PATCH] D113434: [fir] Add complex operations conversion from FIR LLVM IR

Diana Picus via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 9 00:45:31 PST 2021


rovka accepted this revision.
rovka added a comment.
This revision is now accepted and ready to land.

LGTM



================
Comment at: flang/lib/Optimizer/CodeGen/CodeGen.cpp:532
+                  mlir::ConversionPatternRewriter &rewriter) const override {
+    // given: (x + iy) * (x' + iy')
+    // result: (x + x') + i(y + y')
----------------
Nit: s/*/+


================
Comment at: flang/lib/Optimizer/CodeGen/CodeGen.cpp:547
+                  mlir::ConversionPatternRewriter &rewriter) const override {
+    // given: (x + iy) * (x' + iy')
+    // result: (x - x') + i(y - y')
----------------
Nit: s/*/-


================
Comment at: flang/test/Fir/convert-to-llvm.fir:383
+// Test FIR complex addition conversion
+// given: (x + iy) * (x' + iy')
+// result: (x + x') + i(y + y')
----------------
s/*/+


================
Comment at: flang/test/Fir/convert-to-llvm.fir:408
+// Test FIR complex substraction conversion
+// given: (x + iy) * (x' + iy')
+// result: (x - x') + i(y - y')
----------------
s/*/-


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D113434/new/

https://reviews.llvm.org/D113434



More information about the llvm-commits mailing list