[llvm] [X86] matchAddressRecursively - move ZERO_EXTEND patterns into matchIndexRecursively (PR #85081)

Simon Pilgrim via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 13 07:28:21 PDT 2024


================
@@ -2670,97 +2766,14 @@ bool X86DAGToDAGISel::matchAddressRecursively(SDValue N, X86ISelAddressMode &AM,
     break;
   }
   case ISD::ZERO_EXTEND: {
-    // Try to widen a zexted shift left to the same size as its use, so we can
-    // match the shift as a scale factor.
     if (AM.IndexReg.getNode() != nullptr || AM.Scale != 1)
----------------
RKSimon wrote:

Can we remove the `AM.Scale != 1`? matchIndexRecursively needs to be able to accumulate scale

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


More information about the llvm-commits mailing list