[PATCH] Explain in docs that assertions must be enabled to use the -stats flag

Rob Stewart robstewart57 at gmail.com
Sat Feb 21 09:18:04 PST 2015


On llvm-dev there was a recent question about -stats, namely that it did not print out statistics about passes with the -stats `opt` flag.
http://lists.cs.uiuc.edu/pipermail/llvmdev/2015-February/082409.html

The answer is that assertions must be enabled.
http://lists.cs.uiuc.edu/pipermail/llvmdev/2015-February/082461.html

This commit adds that information to the programmers manual document.

http://reviews.llvm.org/D7812

Files:
  docs/ProgrammersManual.rst

Index: docs/ProgrammersManual.rst
===================================================================
--- docs/ProgrammersManual.rst
+++ docs/ProgrammersManual.rst
@@ -488,6 +488,9 @@
   $ opt -stats -mypassname < program.bc > /dev/null
   ... statistics output ...
 
+Note that in order to use the '``-stats``' option, LLVM must be
+compiled with assertions enabled.
+  
 When running ``opt`` on a C file from the SPEC benchmark suite, it gives a
 report that looks like this:

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D7812.20465.patch
Type: text/x-patch
Size: 480 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150221/e18ba2b5/attachment.bin>


More information about the llvm-commits mailing list