diff options
| author | George Karpenkov <ekarpenkov@apple.com> | 2018-02-01 02:38:42 +0000 |
|---|---|---|
| committer | George Karpenkov <ekarpenkov@apple.com> | 2018-02-01 02:38:42 +0000 |
| commit | dece62a7728b2ef1edf5ea039e7043996fe25f9f (patch) | |
| tree | 31ac5cb9e1f90f4e3235cc592058940a7acba348 /clang/utils/analyzer/CmpRuns.py | |
| parent | cdca0730be2af252d1498b752d489bdcbb054681 (diff) | |
| download | bcm5719-llvm-dece62a7728b2ef1edf5ea039e7043996fe25f9f.tar.gz bcm5719-llvm-dece62a7728b2ef1edf5ea039e7043996fe25f9f.zip | |
[analyzer] [tests] Show the number of removed/added bug reports
Differential Revision: https://reviews.llvm.org/D42718
llvm-svn: 323941
Diffstat (limited to 'clang/utils/analyzer/CmpRuns.py')
| -rwxr-xr-x | clang/utils/analyzer/CmpRuns.py | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/clang/utils/analyzer/CmpRuns.py b/clang/utils/analyzer/CmpRuns.py index 2c0ed6aae3a..43016165357 100755 --- a/clang/utils/analyzer/CmpRuns.py +++ b/clang/utils/analyzer/CmpRuns.py @@ -254,17 +254,22 @@ def dumpScanBuildResultsDiff(dirA, dirB, opts, deleteEmpty=True): diff = compareResults(resultsA, resultsB) foundDiffs = 0 + totalAdded = 0 + totalRemoved = 0 + totalChanged = 0 for res in diff: a, b, confidence = res if a is None: print "ADDED: %r" % b.getReadableName() foundDiffs += 1 + totalAdded += 1 if auxLog: print >>auxLog, ("('ADDED', %r, %r)" % (b.getReadableName(), b.getReport())) elif b is None: print "REMOVED: %r" % a.getReadableName() foundDiffs += 1 + totalRemoved += 1 if auxLog: print >>auxLog, ("('REMOVED', %r, %r)" % (a.getReadableName(), a.getReport())) @@ -272,6 +277,7 @@ def dumpScanBuildResultsDiff(dirA, dirB, opts, deleteEmpty=True): print "CHANGED: %r to %r" % (a.getReadableName(), b.getReadableName()) foundDiffs += 1 + totalChanged += 1 if auxLog: print >>auxLog, ("('CHANGED', %r, %r, %r, %r)" % (a.getReadableName(), @@ -284,6 +290,9 @@ def dumpScanBuildResultsDiff(dirA, dirB, opts, deleteEmpty=True): TotalReports = len(resultsB.diagnostics) print "TOTAL REPORTS: %r" % TotalReports print "TOTAL DIFFERENCES: %r" % foundDiffs + print "TOTAL ADDED: %r" % totalAdded + print "TOTAL REMOVED: %r" % totalRemoved + print "TOTAL CHANGED: %r" % totalChanged if auxLog: print >>auxLog, "('TOTAL NEW REPORTS', %r)" % TotalReports print >>auxLog, "('TOTAL DIFFERENCES', %r)" % foundDiffs |

