On Oct 29, 2009, at 2:30 PM, Jens Alfke wrote:

 Is there any reason this couldn't be optimized to use a HashMap

Memory consumption is much greater.

or at least binary search?

Would make lookups faster but parsing slower.

(I thought the answer might be that the order of attributes is significant; but I just checked the DOM spec, and NamedNodeMap is explicitly unordered.)

The DOM specification is not what matters here. Behavior of actual browsers is what determines website compatibility. So you will need to do more research on that.

I think there could be some real room for improvement here, but also plenty of opportunity to unwittingly make things worse.

    -- Darin

_______________________________________________
webkit-dev mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-dev

Reply via email to