[PATCH] D120559: [flang] Lower integer comparison operation

Diana Picus via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 25 06:13:49 PST 2022


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

LGTM.



================
Comment at: flang/lib/Lower/ConvertExpr.cpp:363
+  template <typename OpTy>
+  mlir::Value createCompareOp(mlir::arith::CmpIPredicate pred,
+                              const ExtValue &left, const ExtValue &right) {
----------------
Nit: Why is this a template if it takes a CmpIPredicate? Can we use anything other than CmpIOp with a CmpIPredicate?


================
Comment at: flang/test/Lower/integer-operations.f90:72
+! CHECK-LABEL:add6_test
+INTEGER(4) FUNCTION add6_test(x0, x1)
+INTEGER(4) :: x0
----------------
I don't mind more tests, but where these supposed to be in a different patch? :)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D120559



More information about the llvm-commits mailing list