Skip to content

Commit 453f8ed

Browse files
authored
Fix update-ui performance.measure nesting (#307)
The mark and measure calls were out of sync and caused unclosed scopes.
1 parent de88e36 commit 453f8ed

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

‎JetStreamDriver.js‎

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,8 @@ class Driver {
347347
performance.mark("update-ui-start");
348348
const start = performance.now();
349349
for (const benchmark of this.benchmarks) {
350-
await benchmark.updateUIBeforeRun();
350+
performance.mark("update-ui-start");
351+
benchmark.updateUIBeforeRun();
351352
await updateUI();
352353
performance.measure("runner update-ui", "update-ui-start");
353354

@@ -358,14 +359,14 @@ class Driver {
358359
throw e;
359360
}
360361

361-
performance.mark("update-ui");
362+
performance.mark("update-ui-start");
362363
benchmark.updateUIAfterRun();
364+
performance.measure("runner update-ui", "update-ui-start");
363365

364366
if (isInBrowser) {
365367
browserFileLoader.free(benchmark.files);
366368
}
367369
}
368-
performance.measure("runner update-ui", "update-ui-start");
369370

370371
const totalTime = performance.now() - start;
371372
if (measureTotalTimeAsSubtest) {

0 commit comments

Comments
 (0)