enable code to handle un-phi-translatable cases more aggressively:

if we don't have an address expression available in a predecessor,
then model this as the value being clobbered at the end of the pred
block instead of being modeled as a complete phi translation failure.
This is important for PRE of loads because we want to see that the
load is available in all but this predecessor, and complete phi
translation failure results in not getting any information about
predecessors.

This doesn't do anything until I renable code insertion since PRE
now sees that it is available in all but one predecessors, but can't
insert the addressing in the predecessor that is missing it to 
eliminate the redundancy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90037 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2009-11-28 14:54:10 +00:00
parent 971fd57f7d
commit af7a28939e

View File

@ -1132,12 +1132,9 @@ getNonLocalPointerDepFromBB(Value *Pointer, uint64_t PointeeSize,
// that predecessor. We can still do PRE of the load, which would insert
// a computation of the pointer in this predecessor.
if (PredPtr == 0) {
goto PredTranslationFailure;
#if 0 // TODO.
Result.push_back(NonLocalDepEntry(Pred,
MemDepResult::getClobber(Pred->getTerminator())));
continue;
#endif
}
// FIXME: it is entirely possible that PHI translating will end up with