3 ms·
This article feels like it ends 10% of the way to actually answering the question it asks. "Hey, this thing is slow. I'll write something that might be equivale
by kevingadd 14y ago
This article feels like it ends 10% of the way to actually answering the question it asks. "Hey, this thing is slow. I'll write something that might be equivalent, and see if it's not slow, and then I'll stop." If you're going to accuse someone of 'cheating' or otherwise rigging a benchmark, maybe you should at least do a proper benchmark yourself, or figure out how they cheated?
EDIT: Some basic digging reveals that this is using web workers, and V8's profiler does't record samples for web workers. It appears to be much slower in the current Release build of Chrome than it is in Canary, so whatever is causing it to be slow in V8 is actively being worked on by Chrome's developers.
Unfortunately Firefox's profiler only profiles the main thread as well. Furthermore the mandelbrot demo doesn't work right in Aurora or Nightly, so uh, yeah.
Given the use of workers, one guess would be that IE10 offers a much faster implementation of postMessage, making it cheaper to send the rendered pixel data back from the workers when it's done. Another obvious candidate would be a much faster implementation of putImageData for rendering the pixels to the canvas. A third candidate would be the use of something that IE10's JIT optimizes that V8 doesn't and Firefox struggles with slightly. Try/catch would be an obvious one; floats would be another.
The code for the demo is there, and it's got comments, so if you really think they're cheating, read it. It looks fine to me and it looks like something that V8 should be able to turn into highly performant assembly, so if it's not, the fault probably lies with V8, not Microsoft.
- Trezoid 14y agoFirefox nightly 20.0a1 (released today) runs the test...very well, actually.