On 2015/04/14 14:53:44, caitp wrote:
I made a little benchmark, the results aren't super-promising:
```
=== With @@toStringTag in prototype ===
Runs: 100000
Total: 655.3990000000385ms
Average: 0.006553990000000385ms
=== No @@toStringTag ===
Runs: 100000
Total: 180.22799999993367ms
Average: 0.0018022799999993368ms
```
(a bunch of functions are created, each subsequent function inherits
prototypically from the previous one, prototypes are mutated with a
series of
properties and elements with different value types --- in one set of
runs, the
top function's prototype has @@toStringTag set --- in the second run,
@@toStringTag is not set anywhere).
It's impressive, but it seems to go faster when the property isn't there
at
all.
Maybe something can be done about that
The source for the little benchmark is at
https://gist.github.com/caitp/41d2a0fed5d6fe6a5f84 --- it's entirely
possible
that the test causes problems for the optimizing compiler)
https://codereview.chromium.org/1063703005/
--
--
v8-dev mailing list
v8-dev@googlegroups.com
http://groups.google.com/group/v8-dev
---
You received this message because you are subscribed to the Google Groups "v8-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to v8-dev+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.