[llvm] [RISCV] Add 2^N + 2^M expanding pattern for mul (PR #137954)

Min-Yih Hsu via llvm-commits llvm-commits at lists.llvm.org
Thu May 8 09:35:53 PDT 2025


================
@@ -15694,6 +15703,9 @@ static SDValue expandMul(SDNode *N, SelectionDAG &DAG,
     }
   }
 
+  if (SDValue V = expandMulToAddOrSubOfShl(N, DAG, MulAmt))
----------------
mshockwave wrote:

and is there any reason you moved this below strength reduction via division? (line 15681 ~ 15704)

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


More information about the llvm-commits mailing list