[webkit-reviews] review requested: [Bug 8177] Javascript search incredibly slow : [Attachment 8882] proposed patch

bugzilla-request-daemon at opendarwin.org bugzilla-request-daemon at opendarwin.org
Sat Jun 17 06:02:15 PDT 2006

Alexey Proskuryakov <ap at nypop.com> has asked  for review:
Bug 8177: Javascript search incredibly slow

Attachment 8882: proposed patch

------- Additional Comments from Alexey Proskuryakov <ap at nypop.com>
Use shared CollectionInfos for HTMLOptionsCollection and HTMLNameCollection,

The test runs perfectly fast now. A test with 2000 options also runs fast (no
visible delay, a nice change from tens of seconds), but it still takes several
seconds to open, because the DOM version keeps changing, which defeats caching:

   for (var i=0; i < 2000; i++)
	document.fmain.user.options[i] = new Option("User " + i, i);

I couldn't understand why the other collections (images, applets, all etc.)
were returned from Document, but were only shared for HTMLDocuments. I just did
the same.

More information about the webkit-reviews mailing list