From: Ted Kremenek Date: Fri, 18 Jul 2008 17:39:56 +0000 (+0000) Subject: Fix caching bug. X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2d1086cec05137a77f0779afe7b3a2fb4f034414;p=clang Fix caching bug. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@53759 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Analysis/CFRefCount.cpp b/lib/Analysis/CFRefCount.cpp index 27c5fe33fc..de048eb4be 100644 --- a/lib/Analysis/CFRefCount.cpp +++ b/lib/Analysis/CFRefCount.cpp @@ -265,15 +265,16 @@ public: static void Profile(llvm::FoldingSetNodeID& ID, ArgEffects* A, RetEffect RetEff, ArgEffect DefaultEff, - ArgEffect ReceiverEff) { + ArgEffect ReceiverEff, bool EndPath) { ID.AddPointer(A); ID.Add(RetEff); ID.AddInteger((unsigned) DefaultEff); ID.AddInteger((unsigned) ReceiverEff); + ID.AddInteger((unsigned) EndPath); } void Profile(llvm::FoldingSetNodeID& ID) const { - Profile(ID, Args, Ret, DefaultArgEffect, Receiver); + Profile(ID, Args, Ret, DefaultArgEffect, Receiver, EndPath); } }; } // end anonymous namespace @@ -643,7 +644,8 @@ RetainSummaryManager::getPersistentSummary(ArgEffects* AE, RetEffect RetEff, // Generate a profile for the summary. llvm::FoldingSetNodeID profile; - RetainSummary::Profile(profile, AE, RetEff, DefaultEff, ReceiverEff); + RetainSummary::Profile(profile, AE, RetEff, DefaultEff, ReceiverEff, + isEndPath); // Look up the uniqued summary, or create one if it doesn't exist. void* InsertPos; @@ -1010,7 +1012,7 @@ void RetainSummaryManager::InitializeMethodSummaries() { getPersistentSummary(RetEffect::MakeReceiverAlias(), SelfOwn); // Create the "initWithContentRect:styleMask:backing:defer:" selector. - llvm::SmallVector II; + llvm::SmallVector II; II.push_back(&Ctx.Idents.get("initWithContentRect")); II.push_back(&Ctx.Idents.get("styleMask")); II.push_back(&Ctx.Idents.get("backing"));