Are frozen Objects faster ?
David Bruant
bruant.d at gmail.com
Thu Feb 14 10:22:44 PST 2013
Le 14/02/2013 19:08, Mark S. Miller a écrit :
> On Thu, Feb 14, 2013 at 10:01 AM, Kevin Gadd <kevin.gadd at gmail.com
> <mailto:kevin.gadd at gmail.com>> wrote:
>
> Frozen and sealed objects are both dramatically slower in most JS
> engines I've tested. In the ones where they're not dramatically slower
> they are never faster.
>
> The last time I asked on the mozilla and v8 bug trackers I was
> informed that there is no plan to optimize for these features and that
> the design of the respective JS engines would make such optimizations
> difficult anyway.
>
> (I find this extremely unfortunate.)
>
>
> Likewise. And unlikely.
>
> Based on history, I suggest that the best way to get this situation
> fixed is benchmarks.
Agreed 100%
> Either create a new benchmark or a variation of an existing benchmark.
> For example, if someone created a variant of SunSpider in which all
> objects that don't need to not be frozen were frozen, and posted the
> measurements, that would help get everyone's attention. The situation
> might then improve rapidly.
Choice of the specific benchmark aside, this is a very good idea. This
could also be applied to strict mode.
David
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.mozilla.org/pipermail/es-discuss/attachments/20130214/353a9027/attachment.html>
More information about the es-discuss
mailing list