Disable incorrect mustalias code

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7087 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2003-07-02 23:56:51 +00:00
parent 61691c5d85
commit 10c45d6cd5

View File

@ -107,6 +107,7 @@ AliasAnalysis::AliasResult DSAA::alias(const Value *V1, unsigned V1Size,
if (N1 != N2) if (N1 != N2)
return NoAlias; // Completely different nodes. return NoAlias; // Completely different nodes.
#if 0 // This does not correctly handle arrays!
// Both point to the same node and same offset, and there is only one // Both point to the same node and same offset, and there is only one
// physical memory object represented in the node, return must alias. // physical memory object represented in the node, return must alias.
// //
@ -115,6 +116,7 @@ AliasAnalysis::AliasResult DSAA::alias(const Value *V1, unsigned V1Size,
if (O1 == O2 && isSinglePhysicalObject(N1)) if (O1 == O2 && isSinglePhysicalObject(N1))
return MustAlias; // Exactly the same object & offset return MustAlias; // Exactly the same object & offset
#endif
// See if they point to different offsets... if so, we may be able to // See if they point to different offsets... if so, we may be able to
// determine that they do not alias... // determine that they do not alias...
@ -146,6 +148,7 @@ AliasAnalysis::AliasResult DSAA::alias(const Value *V1, unsigned V1Size,
/// specified vector. /// specified vector.
/// ///
void DSAA::getMustAliases(Value *P, std::vector<Value*> &RetVals) { void DSAA::getMustAliases(Value *P, std::vector<Value*> &RetVals) {
#if 0 // This does not correctly handle arrays!
// Currently the only must alias information we can provide is to say that // Currently the only must alias information we can provide is to say that
// something is equal to a global value. If we already have a global value, // something is equal to a global value. If we already have a global value,
// don't get worked up about it. // don't get worked up about it.
@ -163,6 +166,6 @@ void DSAA::getMustAliases(Value *P, std::vector<Value*> &RetVals) {
RetVals.push_back(N->getGlobals()[0]); RetVals.push_back(N->getGlobals()[0]);
} }
} }
#endif
return getAnalysis<AliasAnalysis>().getMustAliases(P, RetVals); return getAnalysis<AliasAnalysis>().getMustAliases(P, RetVals);
} }