W3C home > Mailing lists > Public > public-webapps@w3.org > October to December 2011

Re: QSA, the problem with ":scope", and naming

From: Boris Zbarsky <bzbarsky@MIT.EDU>
Date: Tue, 18 Oct 2011 21:26:22 -0400
Message-ID: <4E9E273E.7010206@mit.edu>
To: Alex Russell <slightlyoff@google.com>
CC: public-webapps@w3.org
On 10/18/11 8:08 PM, Alex Russell wrote:
>> The other "excuse" is that adding special cases (which is what you're asking
>> for) slows down all the non-special-case codepaths.  That may be fine for
>> _your_ usage of querySelectorAll, where you use it with a particular limited
>> set of selectors, but it's not obvious that this is always a win.
>
> Most browsers try to optimize what is common.

Yes, but what is common for Yehuda may well not be globally common.

There's also the question of premature optimization.  Again, I'd love to 
see a non-synthetic situation where any of this matters.  That would be 
a much more useful point to reason from than some sort of hypothetical 
faith-based optimization.

-Boris
Received on Wednesday, 19 October 2011 01:27:01 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:48 GMT