From d0345fb4a102912e588974a37093d324bb7a39dd Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Sun, 11 Apr 2004 16:35:30 +0000 Subject: [PATCH] New method to allow more efficient clients llvm-svn: 12829 --- include/llvm/Analysis/AliasAnalysis.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/llvm/Analysis/AliasAnalysis.h b/include/llvm/Analysis/AliasAnalysis.h index 1ac4355f952..c27594171f0 100644 --- a/include/llvm/Analysis/AliasAnalysis.h +++ b/include/llvm/Analysis/AliasAnalysis.h @@ -152,6 +152,15 @@ public: /// virtual ModRefResult getModRefInfo(CallSite CS1, CallSite CS2); + /// hasNoModRefInfoForCalls - Return true if the analysis has no mod/ref + /// information for function calls other than "pure" and "const" functions. + /// This can be used by clients to avoid many pointless queries. Remember + /// that if you override this and chain to another analysis, you must make + /// sure that it doesn't have mod/ref info either. + /// + virtual bool hasNoModRefInfoForCalls() const { return false; } + + /// Convenience functions... ModRefResult getModRefInfo(LoadInst *L, Value *P, unsigned Size); ModRefResult getModRefInfo(StoreInst *S, Value *P, unsigned Size);