[llvm] [ARM] Swap sides of cmp/cmn based on folding ability (PR #191915)

via llvm-commits llvm-commits at lists.llvm.org
Mon Jun 29 05:34:15 PDT 2026


================
@@ -13760,8 +13807,6 @@ ARMTargetLowering::isDesirableToCommuteWithShift(const SDNode *N,
     // Avoid making expensive immediates by commuting shifts. (This logic
     // only applies to Thumb1 because ARM and Thumb2 immediates can be shifted
     // for free.)
-    if (N->getOpcode() != ISD::SHL)
----------------
AZero13 wrote:

Redundant. Though I guess can be moved to another PR

https://github.com/llvm/llvm-project/pull/191915


More information about the llvm-commits mailing list