Live data from Hacker News

Actual JavaScript Engine Performance

crockford.com

31–40 of 65 posts

Re: Actual JavaScript Engine Performance

#31
Definitely a valid point, that benchmarks can be misleading and real-world code is more important.

One complaint, though - the tested browsers are all released versions, except for IE10. Why test a single unreleased browser, and not unreleased versions of all the browsers?

With the unreleased IE10 included, it comes out fastest - but then perhaps other unreleased browsers would have done better. Ignoring IE10, which would have been more fair, Firefox 4 is the fastest, closely followed by Safari.

Re: Actual JavaScript Engine Performance

#32
post #6

Wow, IE10 has some legs. I'm shocked to see how Chrome performance compares. If Chrome is on the slower side, I think the real winner is everyone who uses the web, because that means all of these modern browsers are FAST.

Comparing IE10 to Chrome 10 isn't exactly apples to apples. Chrome 11 or 12 should be compared to IE10 since those are the development versions.

> Comparing IE10 to Chrome 10 isn't exactly apples to apples. Chrome 11 or 12 should be compared to IE10 since those are the development versions.

That is true - comparing an unreleased IE to a released Chrome isn't fair.

However, the released Chrome was much slower than all other released browsers - Firefox, Safari, Opera, even IE9. Chrome usually does well on benchmarks, so it is interesting to see it doing so poorly on real-world code.

Re: Actual JavaScript Engine Performance

#33
post #31

Definitely a valid point, that benchmarks can be misleading and real-world code is more important. One complaint, though - the tested browsers are all released versions, except for IE10. Why test a single unreleased browser, and not unreleased versions of all the browsers? With the unreleased IE10 included, it comes out fastest - but then perhaps other unreleased browsers would have done better. Ignoring IE10, which…

I think it's more interesting than anything that an IE release is that fast. I'm glad he included it and I don't think it's unfair at all.

Re: Actual JavaScript Engine Performance

#34
post #17

Earlier quoted context omitted.

I study visualization websites frequently, and found Chrome much faster than other browsers (among all stable releases). Example page (not sure how well written): http://vis.stanford.edu/protovis/ex/force.html

Chrome 10.0.648 certainly does better than Firefox 4.0.1, when running on Ubuntu, for the example you gave. This has also been my experience; I don't know what these benchmarks are doing, but Chrome is still the fastest in my perception. Also, the article doesn't mention OS used for the tests. It is certainly of importance since the performance on Firefox 4.0.1 certainly suffers on Linux and Win XP, versus Windows 7…

It shouldn't matter much.

The test was just a javascript-engine test, this test does not do any rendering by itself.

Re: Actual JavaScript Engine Performance

#35

If I was trying to think of something less representative of large well written javascript application I would have a hard time thinking of something better than JSLint. It doesnt touch the dom, is not event driven, doesnt involve loading lots of files and does not render anything

You are 100% correct. Benchmarking Javascript on "well-written Javascript applications" doesn't even make sense to do. When benchmarking stuff, we should be worried about things where speed actually matters.

For instance:

What FPS rate can your browser can get when performing certain rendering operations on an HTML5 canvas?

Or how well does it perform with WebGL? Oh wait, IE10 won't even have WebGL.

Re: Actual JavaScript Engine Performance

#36

If I was trying to think of something less representative of large well written javascript application I would have a hard time thinking of something better than JSLint. It doesnt touch the dom, is not event driven, doesnt involve loading lots of files and does not render anything

There are many server-side applications that do exactly what you just described and JavaScript is starting to move into that space. So this is quite relevant and will become even more so over time.

Re: Actual JavaScript Engine Performance

#37

If I was trying to think of something less representative of large well written javascript application I would have a hard time thinking of something better than JSLint. It doesnt touch the dom, is not event driven, doesnt involve loading lots of files and does not render anything

There are many server-side applications that do exactly what you just described and JavaScript is starting to move into that space. So this is quite relevant and will become even more so over time.

The original post was comparing client-side browsers, not server-side javascript engines.

Re: Actual JavaScript Engine Performance

#38
post #24

Earlier quoted context omitted.

Crockford claims that JSLint is more indicative of true JS performance, but doesn't really explain why. I think we're all predisposed to take him at his word, but I'd still like an explanation "So I have come up with a benchmark that should be more representative of large, well-written JavaScript applications. It is in fact a popular, large, well-written JavaScript application"

That doesn't fly. It's missing an explanation of the characteristics of JSLint, and how those characteristics are often shared with other large JavaScript applications. My own personal intuition is that JSLint is not representative of typical web applications, so I need convincing. To get an idea of where I come from regarding this, check out "The Landscape of Parallel Computing Research: A View from Berkeley": http:…

I would recommend that anybody interested in parallelism check out the article you linked to. It can be a tad verbose, but it's got a lot of really good insights.

Re: Actual JavaScript Engine Performance

#39
post #6

Wow, IE10 has some legs. I'm shocked to see how Chrome performance compares. If Chrome is on the slower side, I think the real winner is everyone who uses the web, because that means all of these modern browsers are FAST.

Comparing IE10 to Chrome 10 isn't exactly apples to apples. Chrome 11 or 12 should be compared to IE10 since those are the development versions.

What about comparing Chrome10 against IE6? They are both installed on my work computer. I think that is more fair.

Re: Actual JavaScript Engine Performance

#40
V8/Chrome uses the constructor as a big part of the heuristic that determines the 'hidden class' of an object. The other part of the heuristic is the names and ordering of the properties on the object.

Unfortunately, JSlint creates all its objects with Object.create and not with a constructor function. This causes objects with a similar structure to have a different 'hidden class'. This causes most of the optimizations in V8 to break down.

This is definitely a fixable problem and the benchmark is a good illustratiom of the issue. I'm not sure if the benchmark illustrates 'actual performance' more than any other benchmark, but it does seem to illustrate something that should go fast. In this respect it is ahead of Kraken 1.0 which illustrates how fast you can multiply NaN with undefined.

Post reply on HN