Switched 'ts.performance' to a mixed mode only uses native performance APIs when necessary (#42586)

* Partially revert native performance

* Fix bug in measure

* Conditionally enable native perf events
This commit is contained in:
Ron Buckton
2021-02-01 15:33:34 -08:00
committed by GitHub
parent 66ecfcbd04
commit c953969698
4 changed files with 67 additions and 42 deletions

View File

@@ -662,7 +662,7 @@ namespace ts {
function enableStatisticsAndTracing(system: System, compilerOptions: CompilerOptions, isBuildMode: boolean) {
if (canReportDiagnostics(system, compilerOptions)) {
performance.enable();
performance.enable(system);
}
if (canTrace(system, compilerOptions)) {