[Webkit-unassigned] [Bug 33696] [dom] let's cache nodelists instead of dynamicnodelist::cache

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jan 15 04:22:39 PST 2010


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





--- Comment #3 from anton muhin <antonm at chromium.org>  2010-01-15 04:22:39 PST ---
(In reply to comment #0)
> Current caches lead to creation of new C++ node lists for DOM queries by tag,
> name or class.  That leads to proliferation of JS wrappers for tests like
> Dromaeo/DOM core/DOM query which create lots of nodelists.
> 
> Let's cache nodelists per tag, name or class instead.

And forgotten. FF does some kind of caching, at least at JS level this html:

<html>
<head>
  <script>
    function run() {
      var output = document.getElementById('output');
      var nodeList0 = document.getElementsByTagName('p');
      var nodeList1 = document.getElementsByTagName('p');
      output.innerHTML += '<p>nodeList0 == nodeList1: ' + (nodeList0 ==
nodeList1) + '</p>';
      output.innerHTML += '<p>nodeList0 === nodeList1: ' + (nodeList0 ===
nodeList1) + '</p>';
    }
  </script>
</head>
<body onload="run()">
  <div id="output"></div>
</body>
</html>

Gives true in FF (and false for both Safari and Chromium).

-- 
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