[Webkit-unassigned] [Bug 86165] HTML parser should yield more to improve perceived page load time

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jun 11 13:18:23 PDT 2012


Shrey Banga <banga at google.com> changed:

           What    |Removed                     |Added
                 CC|                            |banga at google.com

--- Comment #11 from Shrey Banga <banga at google.com>  2012-06-11 13:18:22 PST ---
(In reply to comment #9)
> BTW, don't do anything in this patch, but have you considered whether 500ms is a reasonable constant?
I saw the FIXME and used some sites after setting it to 200ms and they seemed to work fine, but I thought it might require more rigorous testing, possibly on slower machines.

> > Source/WebCore/html/parser/HTMLParserScheduler.h:79
> > +            if (session.processedTokens > m_parserChunkSize)
> I'm not sure we need this. At the point of yielding, it should be fine to reset processedTokens, right?

I realized that processedTokens becomes redundant once didSeeScript is true because then we check for elapsedTime at every call to checkForYieldBeforeToken. So now I've modified the patch to clear didSeeScript every time we yield so that we go back to the default behavior after yielding to a script. Otherwise we would be doing the expensive currentTime() check all the time.

> > LayoutTests/fast/events/event-yield-timing.html:1
> > +<html>
> It doesn't seem right for a test which takes 2s to live in fast/, but I can't find a better place and I know we haven't been strict about what goes in fast/. In any case, putting this in fast/parser would be much more appropriate than fast/events.
> > LayoutTests/fast/events/event-yield-timing.html:6
> > +        window.layoutTestController.dumpAsText();
> Recommend including ../js/resources/js-test-pre.js. It will call dumpAsText() for you and provide some helper methods like testPassed(), testFailed() and shouldBeGreaterThanOrEqual().


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