[PATCH] D22652: GVH-hoist: only clone GEPs (PR28606)
Eli Friedman via llvm-commits
llvm-commits at lists.llvm.org
Thu Jul 21 15:28:09 PDT 2016
eli.friedman added a subscriber: eli.friedman.
================
Comment at: llvm/lib/Transforms/Scalar/GVNHoist.cpp:588
@@ +587,3 @@
+ // Check that the stored value is available.
+ if (Val && !allOperandsAvailable(Val, HoistPt))
+ return false;
----------------
I think you want "Val && !DT->dominates(Val->getParent(), HoistPt)", or something like that? You care whether the value itself is available, not its operands.
https://reviews.llvm.org/D22652
More information about the llvm-commits
mailing list