[PATCH] D29977: AssumptionCache: Update documentation comment.

Peter Collingbourne via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 14 17:56:19 PST 2017


pcc created this revision.

The comment was somewhat misleading in that it implied that passes were not
responsible for updating the assumption cache. This new wording now
explicitly mentions that they are required to do so.


https://reviews.llvm.org/D29977

Files:
  llvm/include/llvm/Analysis/AssumptionCache.h


Index: llvm/include/llvm/Analysis/AssumptionCache.h
===================================================================
--- llvm/include/llvm/Analysis/AssumptionCache.h
+++ llvm/include/llvm/Analysis/AssumptionCache.h
@@ -31,11 +31,9 @@
 /// \brief A cache of @llvm.assume calls within a function.
 ///
 /// This cache provides fast lookup of assumptions within a function by caching
-/// them and amortizing the cost of scanning for them across all queries. The
-/// cache is also conservatively self-updating so that it will never return
-/// incorrect results about a function even as the function is being mutated.
-/// However, flushing the cache and rebuilding it (or explicitly updating it)
-/// may allow it to discover new assumptions.
+/// them and amortizing the cost of scanning for them across all queries. Passes
+/// that use the assumption cache are required to call registerAssumption() to
+/// register any new @llvm.assume calls that they create.
 class AssumptionCache {
   /// \brief The function for which this cache is handling assumptions.
   ///


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D29977.88472.patch
Type: text/x-patch
Size: 1071 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170215/b12ff507/attachment.bin>


More information about the llvm-commits mailing list