[Webkit-unassigned] [Bug 56842] Performance regression: Blocking inline scripts on external sheets

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Mar 22 11:02:52 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=56842





--- Comment #2 from Tony Gentilcore <tonyg at chromium.org>  2011-03-22 11:02:52 PST ---
(In reply to comment #1)
> (In reply to comment #0)
> 
> > 2. Rather than blocking scripts on stylesheet loads, we allow them to execute, but then block their execution when they call out for layout. Since this involves hitting the event loop in a new place, this could be tricky or impossible to get right. However, the win would be nice as I suspect this would allow most scripts to not block on stylesheets at all.
> 
> Isn't this how our behavior used to work?

Oh, did this change w/ the html5 parser? Are there any bugs that explain the rationale for the change?

> 
> > 3. Currently we block scripts on styles whether the script is in the head or body. Unless I'm missing something, this blocking behavior should only be required for scripts in the body as layout isn't applicable while parsing the head. If this change works, it would recover the regression from at least one case that I'm aware of.
> 
> Possibly.  But you'd still get incorrect results if you tried to crawl the CSSOM during that script.

Yeah, that is unfortunate because it is presumably a very uncommon operation. Do you think there's any way we could detect calling out to the cssom and safely block in only that case? If not, I'm not sure how to weigh breaking that assumption vs taking a perf hit in so many cases where it isn't necessary.

BTW, do any other approaches happen to come to mind?

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list