[PATCH] D69499: [X86] Narrow i64 compares with constant to i32 when the upper 32-bits are known zero.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 28 22:41:09 PDT 2019


craig.topper marked an inline comment as done.
craig.topper added inline comments.


================
Comment at: llvm/lib/Target/X86/X86ISelLowering.cpp:20187
+      cast<ConstantSDNode>(Op1)->getAPIntValue().getActiveBits() <= 32 &&
+      DAG.MaskedValueIsZero(Op0, APInt::getHighBitsSet(64, 32))) {
+    CmpVT = MVT::i32;
----------------
RKSimon wrote:
> Do the equivalent for signed with ComputeNumSignBits?
I tried, but it affected no lit tests.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D69499





More information about the llvm-commits mailing list