

Resig: Javascript Performance Rundown - johns
http://ejohn.org/blog/javascript-performance-rundown/

======
andreyf
_We already see TraceMonkey (under development for about 2 months) performing
better than V8 (under development for about 2 years)._

Zinger.

On the other hand, it's impressive that people at Google saw JS VM's coming
two years ago and already shipped it with Chrome, while Mozilla still has it
as an about:config use-at-your-own-risk feature in an unreleased version of FF
;)

But I like that people are taking this personally :) browser wars rock on!

~~~
DocSavage
It's an unfair zinger from what I've read. TraceMonkey may have been in
development at Mozilla for 2 months, but significant portions of it came from
Adobe and their Tamarin Tracing team. You can't dismiss the development time
of the nanojit contribution just for hyperbole's sake. When I saw John Resig,
who I very much respect for his work on javascript, make that statement, I
realized there's a PR war going on here.

This was a cool article on TraceMonkey development:
<http://andreasgal.com/2008/08/22/tracing-the-web/>

~~~
andreyf
It would appear that TraceMonkey does optimization differently, and they both
have a long way to go:

Here is what feng (@chromium.org) said on the v8-users list:

 _V8 has a simple compiler that generates dummy code ;-), there are a lot of
rooms to improve from traditional compiler optimization perspective. It does
not even have a register allocator.

What V8 focuses on is the bottleneck of JavaScript: property lookups. You can
read papers about inline caches (small-talk, Java, etc).

Some background in GC is helpful too, currently V8 has a generational GC.

From I knew, TraceMonkey is quite different, it does speculative
optimizations, which is a very interesting subject of VM and compiler
development/research. It requires a interpreter/dummy compiler to fallback
when speculation goes wrong. In some sense, both does runtime speculation, but
inline cache patches the code if it speculates wrong, and trace jit falls back
to safe solution._

------
waynep
Since John's site is down temporarily I'll link my tests here
[http://waynepan.com/2008/09/02/v8-tracemonkey-
squirrelfish-i...](http://waynepan.com/2008/09/02/v8-tracemonkey-squirrelfish-
ie8-benchmarks/)

PS. I didn't know the secret v2 Dromaeo tests... running and updating now.

------
KirinDave
These numbers are not at all what I got, testing yesterday. Especially the
Dromera tests, where the latest webkit nightly didn't finish even close to
that.

I wonder where the discrepancy comes from?

~~~
etal
Apparently there's a secret v2 test, did you use that?
<http://v2.dromaeo.com/>

He also says he used Safari without Squirrelfish in these tests, due to
compilation issues on Windows.

~~~
maximilian
I'm pretty sure Squirrelfish is still under pretty heavy windows development.
For non-windows, they use some special GCC things that aren't supported under
VC++, which they use to compile the windows version (AFAIK). Even if it ran,
Squirrelfish is slower under windows because they have to cut out some of the
optimizations.

------
thomasmallen
404.

~~~
johns
It's back

