[PATCH] D63227: [analyzer] Better timers.

Artem Dergachev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Jun 12 14:05:16 PDT 2019


NoQ created this revision.
NoQ added reviewers: dcoughlin, xazax.hun, a_sidorin, rnkovacs, Szelethus, baloghadamsoftware, Charusso.
Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, szepet.
Herald added a project: clang.

`-analyzer-stats` now allows you to find out how much time was spent on AST-based analysis and on path-sensitive analysis and, separately, on bug visitors, as they're occasionally a performance problem on their own.

The total timer wasn't useful because there's anyway a total time printed out, so i removed it.

Accidentally remove the `ExprEngine`'s destructor because it's not really useful: reports are flushed manually anyway, which i've noticed while adding a timer.

Sample output:

  ===-------------------------------------------------------------------------===
                                  Analyzer timers
  ===-------------------------------------------------------------------------===
    Total Execution Time: 7.4278 seconds (7.4293 wall clock)
  
     ---User Time---   --System Time--   --User+System--   ---Wall Time---  --- Name ---
     7.2345 ( 99.0%)   0.1140 ( 96.9%)   7.3485 ( 98.9%)   7.3500 ( 98.9%)  Path exploration time
     0.0456 (  0.6%)   0.0026 (  2.2%)   0.0482 (  0.6%)   0.0482 (  0.6%)  Path-sensitive report post-processing time
     0.0300 (  0.4%)   0.0011 (  1.0%)   0.0311 (  0.4%)   0.0312 (  0.4%)  Syntax-based analysis time
     7.3101 (100.0%)   0.1177 (100.0%)   7.4278 (100.0%)   7.4293 (100.0%)  Total


Repository:
  rC Clang

https://reviews.llvm.org/D63227

Files:
  clang/include/clang/StaticAnalyzer/Core/PathSensitive/ExprEngine.h
  clang/lib/StaticAnalyzer/Core/ExprEngine.cpp
  clang/lib/StaticAnalyzer/Frontend/AnalysisConsumer.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D63227.204353.patch
Type: text/x-patch
Size: 5433 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20190612/bd842cc7/attachment.bin>


More information about the cfe-commits mailing list