Thread const correctness through a bunch of AliasAnalysis interfaces and

eliminate several const_casts.

Make CallSite implicitly convertible to ImmutableCallSite.

Rename the getModRefBehavior for intrinsic IDs to
getIntrinsicModRefBehavior to avoid overload ambiguity with CallSite,
which happens to be implicitly convertible to bool.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@110155 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Dan Gohman
2010-08-03 21:48:53 +00:00
parent d1fb583128
commit 79fca6fea8
13 changed files with 133 additions and 103 deletions

View File

@@ -155,7 +155,7 @@ bool AliasSet::aliasesPointer(const Value *Ptr, unsigned Size,
// Check the call sites list and invoke list...
if (!CallSites.empty()) {
for (unsigned i = 0, e = CallSites.size(); i != e; ++i)
if (AA.getModRefInfo(CallSites[i], const_cast<Value*>(Ptr), Size)
if (AA.getModRefInfo(CallSites[i], Ptr, Size)
!= AliasAnalysis::NoModRef)
return true;
}