[PATCH] D34472: [DAG] Rewrite areNonVolatileConsecutiveLoads to use BaseIndexOffset

Nirav Dave via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 28 08:22:48 PDT 2017


niravd added inline comments.


================
Comment at: lib/CodeGen/SelectionDAG/SelectionDAGAddressAnalysis.cpp:76
+        continue;
+      }
+    }
----------------
RKSimon wrote:
> RKSimon wrote:
> > This LHS test shouldn't be needed - constants in ADD/OR should have been canonicalized to the RHS.
> You still have both of these here, but removing the Base->getOperand(0) doesn't seem to have any effect on the tests. Do you have cases where Base->getOperand(0) is constant?
I don't. This was added to match with isGAPlusOffset which was rewritten similarly in a previous patch which I've dropped for now. I'm not sure if that's actually interesting. Regardless, I'll remove this here and defer that until that patch appears.


https://reviews.llvm.org/D34472





More information about the llvm-commits mailing list