Chore: event loop wall build time tracking

This commit is contained in:
SukkaW
2026-09-02 16:03:38 +08:00
parent 3e03018bbe
commit 68ab592d76
4 changed files with 454 additions and 210 deletions

View File

@@ -49,8 +49,7 @@ export function makeSpan(rawSpan: RawSpan): Span {
}
traceResult.end = time ?? performance.now();
if (rawSpan.eluStart) {
const elu = performance.eventLoopUtilization(rawSpan.eluStart);
traceResult.elu = { idle: elu.idle, active: elu.active };
traceResult.loopIdle = { atStart: rawSpan.eluStart.idle, atEnd: performance.eventLoopUtilization().idle };
}
rawSpan.status = SPAN_STATUS_END;
};