tijlleenders / ZinZen

Better together - an app to realize dreams together.
https://ZinZen.me
GNU Affero General Public License v3.0
43 stars 60 forks source link

Add timing logs for scheduler #2068

Closed tijlleenders closed 2 hours ago

tijlleenders commented 2 hours ago

Is your feature request related to a problem? Please describe. It's very annoying when the scheduler takes a long time to calculate.

Describe the solution you'd like Console.log the total between:

Describe alternatives you've considered

Additional context None.

tijlleenders commented 2 hours ago

Not actually needed - it's built-in to some browsers: image

tijlleenders commented 1 hour ago

Might still be useful to have this in the console log: Console Timing Use console.time() and console.timeEnd() to measure specific operations:

console.time('WASM Operation');
wasmModule.someOperation();
console.timeEnd('WASM Operation');

Custom Performance Markers Utilize the Performance API for more granular timing:

performance.mark('wasmStart');
await wasmModule.heavyComputation();
performance.mark('wasmEnd');
performance.measure('WASM Execution', 'wasmStart', 'wasmEnd');
tijlleenders commented 1 hour ago

In Firefox:
image