[PATCH] D12066: Introduce the ScopExpander as a SCEVExpander replacement

Sanjoy Das via llvm-commits llvm-commits at lists.llvm.org
Sun Aug 16 14:24:23 PDT 2015


sanjoy added inline comments.

================
Comment at: lib/Support/ScopHelper.cpp:292
@@ +291,3 @@
+
+    Value *LHS = Expander.expandCodeFor(LHSScev, E->getType(), StartIP);
+    Value *RHS = Expander.expandCodeFor(RHSScev, E->getType(), StartIP);
----------------
I don't grok how Polly uses SCEVs, but won't `LHS` be identical to `Inst->getOperand(0)` here?  Likewise for `RHS` and `Inst->getOperand(1)`?  Why can't this function just `return E->getValue()` (after which `ScopExpander::expandCodeFor` should become equivalent to `SCEVExpander::expandCodeFor`)?


http://reviews.llvm.org/D12066





More information about the llvm-commits mailing list