Index: pkg/analyzer_cli/lib/src/perf_report.dart |
diff --git a/pkg/analyzer_cli/lib/src/perf_report.dart b/pkg/analyzer_cli/lib/src/perf_report.dart |
index 208e56012c1c20103162e787c15db74fe9b83a79..1270e7ce18b56aa3d2ca79facd4d74542c350452 100644 |
--- a/pkg/analyzer_cli/lib/src/perf_report.dart |
+++ b/pkg/analyzer_cli/lib/src/perf_report.dart |
@@ -10,7 +10,9 @@ import 'dart:io' show File, Platform; |
import 'package:analyzer/src/generated/utilities_general.dart' |
show PerformanceTag; |
import 'package:analyzer/task/model.dart' show AnalysisTask; |
+import 'package:analyzer_cli/src/error_formatter.dart'; |
import 'package:analyzer_cli/src/options.dart' show CommandLineOptions; |
+import 'package:analyzer/src/generated/engine.dart' show AnalysisContext; |
const _JSON = const JsonEncoder.withIndent(" "); |
@@ -39,7 +41,8 @@ String _osType = () { |
} |
}(); |
-String makePerfReport(int startTime, int endTime, CommandLineOptions options) { |
+String makePerfReport(int startTime, int endTime, CommandLineOptions options, |
+ AnalysisContext context) { |
int totalTime = endTime - startTime; |
int otherTime = totalTime; |
@@ -53,6 +56,7 @@ String makePerfReport(int startTime, int endTime, CommandLineOptions options) { |
'dartSdkPath': options.dartSdkPath, |
'strongMode': options.strongMode, |
'showPackageWarnings': options.showPackageWarnings, |
+ 'showPackageWarningsPrefix': options.showPackageWarningsPrefix, |
'showSdkWarnings': options.showSdkWarnings, |
'definedVariables': options.definedVariables, |
'packageRootPath': options.packageRootPath, |
@@ -89,6 +93,8 @@ String makePerfReport(int startTime, int endTime, CommandLineOptions options) { |
'options': optionsJson, |
'totalElapsedTime': totalTime, |
'totalTaskTime': totalTaskTime, |
+ 'analyzedFiles': context.sources.length, |
+ 'generatedDiagnostics': ErrorFormatter.inputErrorCount, |
'performanceTags': perfTagsJson, |
'tasks': taskRows.map((r) => r.toJson()).toList(), |
}; |