Re: Using microtask checkpoints for resetting the slow script dialog timer
Bobby Holley <[email protected]> Wed, 10 Jul 2013 22:15:48 -0700
| Newsgroups | gmane.comp.mozilla.devel.dom |
|---|---|
| Message-ID | <CAKBxTcL3CGgSsJVvTFSKkZWy-sOt46-kvPQSv6v3EQTkJ45jkg@mail.gmail.com> |
On Wed, Jul 10, 2013 at 2:16 PM, Boris Zbarsky <[email protected]> wrote: > Microtasks are clearly defined in the spec, is the idea, so we shouldn't > have any issues in terms of where microtask checkpoints happen. > > Basically there are two places they happen: when the JS stack completely > unwinds and when the event loop spins. Ok. They seem pretty wack-a-mole in Gecko, though. There are important divergences. If I do a dispatchEvent, there is a > script entry point for each event listener that fires, but we don't really > want to be resetting the slow script timer each time an event listener > completes, I believe. That's basically the setup we have right now and one > I'd like to move away from. But CallbackObject constructs an AutoMicroTask, right? So doesn't that lend us to the same problem? Or is the idea that the 'checkpoint' only happens when the microtask depth hits zero? If so, how do we handle nested event loops? bholley