Skip to content

Commit 2e35188

Browse files
authored
[wasm] Let browser-bench post bootstrap flag (#79573)
This helps our perf measurements infrastructure to detect successful bootstrap of the bench run
1 parent 52e86d8 commit 2e35188

File tree

1 file changed

+8
-0
lines changed
  • src/mono/sample/wasm/browser-bench

1 file changed

+8
-0
lines changed

src/mono/sample/wasm/browser-bench/main.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,18 @@ class MainApp {
101101
this.yieldBench();
102102
}
103103

104+
bootstraped = false;
104105

105106
yieldBench() {
106107
let promise = runBenchmark();
107108
promise.then(ret => {
109+
if (!this.bootstraped) {
110+
fetch("/bootstrap.flag", {
111+
method: 'POST',
112+
body: "ok"
113+
}).then(r => { console.log("bootstrap post request complete, response: ", r); });
114+
this.bootstraped = true;
115+
}
108116
document.getElementById("out").innerHTML += ret;
109117
if (ret.length > 0) {
110118
setTimeout(() => { this.yieldBench(); }, 0);

0 commit comments

Comments
 (0)