[PATCH] D120672: [flang][NFC] Add complex operations lowering tests
Valentin Clement via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 28 12:37:44 PST 2022
This revision was automatically updated to reflect the committed changes.
Closed by commit rG89080b84146f: [flang][NFC] Add complex operations lowering tests (authored by clementval).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D120672/new/
https://reviews.llvm.org/D120672
Files:
flang/test/Lower/complex-operations.f90
Index: flang/test/Lower/complex-operations.f90
===================================================================
--- /dev/null
+++ flang/test/Lower/complex-operations.f90
@@ -0,0 +1,37 @@
+! RUN: bbc %s -o - | FileCheck %s
+
+! CHECK-LABEL: @_QPadd_test
+subroutine add_test(a,b,c)
+ complex :: a, b, c
+ ! CHECK-NOT: fir.extract_value
+ ! CHECK-NOT: fir.insert_value
+ ! CHECK: fir.addc {{.*}}: !fir.complex
+ a = b + c
+end subroutine add_test
+
+! CHECK-LABEL: @_QPsub_test
+subroutine sub_test(a,b,c)
+ complex :: a, b, c
+ ! CHECK-NOT: fir.extract_value
+ ! CHECK-NOT: fir.insert_value
+ ! CHECK: fir.subc {{.*}}: !fir.complex
+ a = b - c
+end subroutine sub_test
+
+! CHECK-LABEL: @_QPmul_test
+subroutine mul_test(a,b,c)
+ complex :: a, b, c
+ ! CHECK-NOT: fir.extract_value
+ ! CHECK-NOT: fir.insert_value
+ ! CHECK: fir.mulc {{.*}}: !fir.complex
+ a = b * c
+end subroutine mul_test
+
+! CHECK-LABEL: @_QPdiv_test
+subroutine div_test(a,b,c)
+ complex :: a, b, c
+ ! CHECK-NOT: fir.extract_value
+ ! CHECK-NOT: fir.insert_value
+ ! CHECK: fir.divc {{.*}}: !fir.complex
+ a = b / c
+end subroutine div_test
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D120672.411866.patch
Type: text/x-patch
Size: 1137 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220228/91e7f04b/attachment.bin>
More information about the llvm-commits
mailing list