[llvm-commits] [llvm] r118417 - in /llvm/trunk: lib/Transforms/IPO/FunctionAttrs.cpp test/Analysis/TypeBasedAliasAnalysis/functionattrs.ll
Duncan Sands
baldrick at free.fr
Mon Nov 8 09:46:20 PST 2010
Hi Dan,
> @@ -140,10 +141,14 @@
> for (CallSite::arg_iterator CI = CS.arg_begin(), CE = CS.arg_end();
> CI != CE; ++CI) {
> Value *Arg = *CI;
> - if (Arg->getType()->isPointerTy()&&
> - !AA->pointsToConstantMemory(Arg, /*OrLocal=*/true))
> - // Writes memory. Just give up.
> - return false;
> + if (Arg->getType()->isPointerTy()) {
> + AliasAnalysis::Location Loc(Arg,
> + AliasAnalysis::UnknownSize,
> + I->getMetadata(LLVMContext::MD_tbaa));
> + if (!AA->pointsToConstantMemory(Arg, /*OrLocal=*/true))
Shouldn't it be Loc not Arg in the call to pointsToConstantMemory?
Ciao,
Duncan.
More information about the llvm-commits
mailing list