[Webkit-unassigned] [Bug 143239] No way to quickly make non-enumerable instance properties

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 30 16:15:52 PDT 2015


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

--- Comment #4 from Filip Pizlo <fpizlo at apple.com> ---
(In reply to comment #1)
> I've manually enabled symbols in JSC and got results on
> https://jsperf.com/symbol-vs-prop-vs-def-prop:
> 
> property       68,907,822 ±0.30%  fastest
> non-enumerable 4,093,475 ±0.58%   94% slower
> symbol         11,586,795 ±0.36%  83% slower
> weakmap        5,361,775 ±2.15%   92% slower

The best way to benchmark this is to take a medium-sized test that is known to create a lot of objects and access a lot of properties, and modify it to make all of the properties non-enumerable.  Then also make a version that uses symbols.  Then also make a version that uses WeakMap.  That is, uses those things for all of the properties.

I recommend either V8/deltablue or V8/raytrace.  V8/raytrace could be hilarious since in that one we do very aggressive object allocation sinking but we can't do it if you do things we don't optimize (like all of the things you list above).  So, just make three new versions of raytrace:

raytrace-non-enum
raytrace-symbol
raytrace-weakmap

I know it's tedious, but this is what I do when I want to come up with a good story for optimizing a feature.  Like, we have getter-richards for when I was optimizing getters/setters, and now we have deltablue-varargs to help me with my varargs optimization work.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20150330/97dd28ae/attachment-0002.html>


More information about the webkit-unassigned mailing list