[PATCH] D33369: [PowerPC] Eliminate compares - add i64 sext/zext handling for equality

Nemanja Ivanovic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue May 23 05:14:21 PDT 2017


nemanjai added inline comments.


================
Comment at: lib/Target/PowerPC/PPCISelDAGToDAG.cpp:2860
+    // addc.0 = (addcarry (xor %a, %b), -1)
+    // addc.1 = (addcarry (xor %a, %b), -1).1
+    // (sext (setcc %a, %b, seteq)) -> (sube addc.0, addc.0, addc.1)
----------------
inouehrs wrote:
> Do you mean CA bit by `addc.1`?
> IMO, `{addc.reg, addc.CA} = (addcarry (xor %a, %b), -1)` or similar is clearer.
> Someone may misunderstand that we need to execute addcarry twice with the current pseudo-code.
The idea was to use similar notation to that of the SDAG (i.e. result 0, result 1). But I do like your notation better. I'll change it as you suggested.


Repository:
  rL LLVM

https://reviews.llvm.org/D33369





More information about the llvm-commits mailing list