Why do you think that Flash running the same Ecmascript code would be an order of magnitude faster?
Flash may (currently) have more capabilities than browsers, but when matched point for point (e.g. video vs video, SVG vs vectors, Canvas vs procedural bitmap generation) I've not seen any evidence of spectacular performance differences, despite browser code running in a secure sandbox. And when there is it's rarely something fundamental, like you'd see comparing HTML5 or Flash video against a simple video playback system, just bugs and/or unoptimized code.