dotnet / runtimelab

This repo is for experimentation and exploring new ideas that may or may not make it into the main dotnet/runtime repo.
MIT License
1.37k stars 189 forks source link

[NativeAOT-LLVM] Implement timers on Browser #2505

Open SingleAccretion opened 5 months ago

SingleAccretion commented 5 months ago

https://github.com/dotnet/runtimelab/pull/2502 takes the PNSE version for TimerQueue with the expectation that it will be replaced by its functional Browser cousin. It is a matter of deciding where/how to put the little bit of JS that sets the 'native' timer.

Mono reference: sheduling.ts. Point of note: prevent callbacks from executing if the runtime has already exited (via abort or otherwise).

SingleAccretion commented 4 months ago

https://github.com/dotnet/runtimelab/pull/2521 adds the code but doesn't enable the tests because they need async main to work first.