Join the Mozilla’s Test Days event from 9–15 Jan to test the new Firefox address bar on Firefox Beta 135 and get a chance to win Mozilla swag vouchers! 🎁

Този сайт ще има ограничена функционалност, докато се извършва тече неговата поддръжка. Ако дадена статия не може реши проблема ви и искате да зададете въпрос, нашата общност е готова да ви помогне на @firefox в Twitter и /r/firefox в Reddit.

Търсене в помощните статии

Избягвайте измамите при поддръжката. Никога няма да ви помолим да се обадите или изпратите SMS на телефонен номер или да споделите лична информация. Моля, докладвайте подозрителна активност на "Докладване за злоупотреба".

Научете повече

Why is computation with Javascript drastically slower in Firefox?

  • 2 отговора
  • 3 имат този проблем
  • 1 изглед
  • Последен отговор от patrickmc

more options

Out of curiosity I tested this website in Google Chrome 31 and to my surprise it runs twice as fast as it does in firefox while maintaining fluid interaction with the interface. It doesn't drop a sweat so to speak while my Firefox struggles.

http://cs.stanford.edu/people/karpathy/convnetjs/demo/autoencoder.html

I've had same results with Firefox 29 and the 32 nightly, both with new profiles and no addons on windows 7. Also PaleMoon is a bit faster than these two but still a lot slower than Google Chrome. Is there some volatile hack I can apply in about:config for some experimental Javascript Engine? The difference in Javascript performance seems unrealistic, Google Chrome 31 is half a year old.

Out of curiosity I tested this website in Google Chrome 31 and to my surprise it runs twice as fast as it does in firefox while maintaining fluid interaction with the interface. It doesn't drop a sweat so to speak while my Firefox struggles. http://cs.stanford.edu/people/karpathy/convnetjs/demo/autoencoder.html I've had same results with Firefox 29 and the 32 nightly, both with new profiles and no addons on windows 7. Also PaleMoon is a bit faster than these two but still a lot slower than Google Chrome. Is there some volatile hack I can apply in about:config for some experimental Javascript Engine? The difference in Javascript performance seems unrealistic, Google Chrome 31 is half a year old.

Всички отговори (2)

more options

There isn't some experimental JS engine to enable in Firefox, sorry.

This is just a case where Chrome really is faster. Sometimes Firefox is faster. The two browsers have different execution styles, optimization strategies, and feature sets, so they are bound to be different. I would recommend using the Javascript Profiler to find hot spots in the code to optimize.

I took a quick look, and I noticed a few low hanging fruit for optimization. For example it seems like a new canvas element is being created every frame, instead of re-using the same canvas and context. This is sure to make things slower. There are probably lots of thing that could be done to speed this up, as the code looks fairly un-optimized.

If you are the developer for this, I would recommend spending some time with the profiler to speed things up.

more options

Hello member7,

Thank you for contacting Mozilla Support. I've been doing some research and was not able to come up with a good answer for your question.

I was able to find another resource that might be a better location to get a response.

Ask Mo

These are a group of engineers that are answering more technical questions on the guts of the Firefox browser.

Please post your question there and they may have an answer for you.

Cheers, Patrick