[PATCH] D56032: [ARM] Combine ands+lsls to lsls+lsrs for Thumb1.

Sam Parker via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 15 01:56:25 PST 2019


samparker added inline comments.


================
Comment at: lib/Target/ARM/ARMISelLowering.cpp:10428
+    // for free.)
+    if (N->getOpcode() != ISD::SHL)
+      return true;
----------------
This can be removed and the statement from line 10444 hoisted up.


================
Comment at: lib/Target/ARM/ARMISelLowering.cpp:12474
+      return SDValue();
+    uint32_t ShiftAmt = (uint32_t)ShiftAmtNode->getZExtValue();
+    ConstantSDNode *AndMaskNode = dyn_cast<ConstantSDNode>(N0->getOperand(1));
----------------
I think we should avoid c-style casting.


Repository:
  rL LLVM

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

https://reviews.llvm.org/D56032





More information about the llvm-commits mailing list