-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reporting work outside of event loop can cause leaks #77
Comments
This is meant to capture work that occurs in the process which does not correspond to event loop tasks or update the rendering. Can you clarify how the processing model does not account for update the rendering? I think the problem you're referring to is that |
Event loop begin not always being updated seems like a problem as well, yes. I don't see how moving this to the beginning of the loop helps with capturing that nothing happened during the loop. |
I'm confused about the problem you see then. There already is "Report the duration of the update the rendering step" which accounts for update the rendering. |
I don't see how this is measuring idle time. How do you get through an entire loop without running any script, and then end up here again knowing that nothing executed during the loop? |
That's just idle time because we're checking whether there are tasks and there's none. No longtasks are expected when the browser is idle? What we're interested in is 'time during which the user agent does not execute this loop'. When performing a task outside of the event loop, you're not doing an event loop run. The duration of this task is estimated using the delta between when the previous event loop run ended and when the current event loop run began. |
What kind of task would be performed outside the event loop? Also, how is that not a cross-process information leak? |
Garbage collection and in general any tasks which a browser generally does but are not spec'd because they are implementation details. Although I'm not actually sure if there are tasks which can be 'attributed' to a frame but run outside of the event loop. @domenic do you know of any example? Otherwise I think it should be fine to remove this one and assume every long task comes from an event loop task + microtasks or from update the rendering. |
I'm not sure myself. @dtapuska did a survey of all of the task types at one point and might know better... |
It seems there could be plenty of execution, but because they're not tasks it's counted as idle time?
The text was updated successfully, but these errors were encountered: