mozilla / shumway

Shumway is a Flash VM and runtime written in JavaScript
Apache License 2.0
3.68k stars 396 forks source link

Slow performance #1043

Open oladunk65 opened 10 years ago

oladunk65 commented 10 years ago

OS : 32 bit debian unstable distro Browser : Latest nightly holly build Shumway 0.7.907

I did try the Box2DFlashAS3 demo on a old computer. Excellent for the purpose of testing.

Firefox used around 80 to 85% of the cpu and 33% of memory Rest of the cpu was used by the xserver.

I would love to get rid of Adobe Flash but for the moment it is not possible. I am looking forward to any improvements.

tschneidereit commented 10 years ago

As I just said in the other issue, we're aware of many issues. Shumway isn't ready for prime time, which is the reason why it's disabled by default, and can only be enabled through either a hidden preference, or through installing the extension.

oladunk65 commented 10 years ago

In addition to the other old machine I gave the demo a try on an old laptop. Equipped with
Display controller: Intel Corporation Mobile 915GM/GMS/910GML Express Graphics Controller

Not the hottest one around, but for testing it is a good thing to have. The demo did run a bit better on that one.

I hope that shumway would succeed before Adobe flash stop working. Otherwise Firefox would be of no use and I am forced to use chrome.

yurydelendik commented 10 years ago

@oladunk65 the issue is lacking the expected performance details. Please publish metrics in simular environment (e.g. without the inspector running) for Adobe Player (in chrome?) so we will know when this issue is not an issue anymore. Otherwise this issue will be closed as incomplete.

oladunk65 commented 10 years ago

You may close the issue immediately or do what ever you like.

On monday I will be at my office, with a more powerful machine I will repeate what I done and post what I observe.

But I will give you one performance metric. The "arrow" on the page
http://mozilla.github.io/shumway is spinning nice with google-chrome (flash 11.9...) and firefox(11.2.202.310)

With shumway the spinning arrow goes around very slow. Less than half the speed compared to the adobe plugin.

From the webconsole I got the following output.

"url=http://mozilla.github.io/shumway/main.swf;params=({})" avm-sandbox.js:99 "Compiler settings: {"appCompiler":true,"sysCompiler":false,"verifier":true}" avm-sandbox.js:239 "Parsing http://mozilla.github.io/shumway/main.swf..." avm-sandbox.js:240 "{"counts":{"ApplicationDomain: findDefiningScript":15,"Analysis":230,"Interpret Method":41,"Runtime: Memoizers":394,"Executing Trampoline":5,"Bind Scope - Slow Path":82}}" shumway.js:1093 Initialize Renderer: timer started avm-sandbox.js:249 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::EventDispatcher count: 1" shumway.js:804 "Compiling: undefined count: 2" shumway.js:804 "Session #1: loading http://mozilla.github.io/shumway/main.swf" avm-sandbox.js:189 "Session #1: loaded 31178/31178" avm-sandbox.js:206 "Session #1: closed" avm-sandbox.js:200 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::Event count: 3" shumway.js:804 "Compiling: undefined count: 4" shumway.js:804 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::ProgressEvent count: 5" shumway.js:804 "Compiling: undefined count: 6" shumway.js:804 Initialize Renderer: 1465.06ms shumway.js:201

oladunk65 commented 10 years ago

At my office I have an an Linux, Debian unstable distro 64bit, Dell Precision T3500, 12GB RAM, Quadro FX 3800, NVIDIA driver from www.nivida.com

"http://mozilla.github.io/shumway/main.swf" is running better compared to the old hardware at home. But the adobe flash plugin is faster.

webconsole

"Compiler settings: {"appCompiler":true,"sysCompiler":false,"verifier":true}" avm-sandbox.js:239 "Parsing http://mozilla.github.io/shumway/main.swf..." avm-sandbox.js:240 "{"counts":{"ApplicationDomain: findDefiningScript":15,"Analysis":230,"Interpret Method":41,"Runtime: Memoizers":394,"Executing Trampoline":5,"Bind Scope - Slow Path":82}}" shumway.js:1093 Initialize Renderer: timer started avm-sandbox.js:249 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::EventDispatcher count: 1" shumway.js:804 "Compiling: undefined count: 2" shumway.js:804 "Session #1: loading http://mozilla.github.io/shumway/main.swf" avm-sandbox.js:189 "Session #1: loaded 31178/31178" avm-sandbox.js:206 "Session #1: closed" avm-sandbox.js:200 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::Event count: 3" shumway.js:804 "Compiling: undefined count: 4" shumway.js:804 "Compiling: HAS_OPTIONAL HAS_PARAM_NAMES public flash.events::ProgressEvent count: 5" shumway.js:804 "Compiling: undefined count: 6" shumway.js:804 Initialize Renderer: 639.77ms shumway.js:201

yurydelendik commented 10 years ago

Hmmm, I'm confused is Box2DFlashAS3 located at http://mozilla.github.io/shumway/main.swf ? Could you also define "faster" in terms of CPU usage or percent from normal rate?