Page 1 of 1

Weird Firefox stutter compared to none in Chrome/Edge

Posted: 05 Aug 2021, 00:59
by Kurt
I've attached screenshots from Firefox (the one with lots of small stutter), and a screenshot from Microsoft Edge (with hardly any stutter.) Why is there such a difference between both of these browsers? I also tested on Chrome, and it has same results as Edge (I'm guessing because they are both on Chromium?)

[Moderator edit -- added image zoom links]
FireFox - download/file.php?id=1724
Chrome - download/file.php?id=1723

Re: Weird Firefox stutter compared to none in Chrome/Edge

Posted: 05 Aug 2021, 02:01
by Chief Blur Buster
They have to do with the differences between the JavaScript performance.now() API which is essentially a floating point (microsecond quality) timestamp.

Unfortunately, Meltdown/Spectre hacks made it necessary for some browser vendors to add intentional random() fuzz to this timestamp. Ideally it should be based on RTDSC or QueryPerformanceCounter() but the precision is often intentionally fuzzed by the browser vendors to make it harder for hackers to detect temporal fingerprints from your system (leakage of information from nanosecond/microsecond jitter).

Also, sometimes Chromium is worse, if you use battery management mode on an older laptop, it often falls to the same millisecond-precision!

Re: Weird Firefox stutter compared to none in Chrome/Edge

Posted: 05 Aug 2021, 13:45
by Kurt
Chief Blur Buster wrote: ↑
05 Aug 2021, 02:01
They have to do with the differences between the [which is essentially a floating point (microsecond quality) timestamp.

Unfortunately, Meltdown/Spectre hacks made it necessary for some browser vendors to add intentional random() fuzz to this timestamp. Ideally it should be based on RTDSC or QueryPerformanceCounter() but the precision is often intentionally fuzzed by the browser vendors to make it harder for hackers to detect temporal fingerprints from your system (leakage of information from nanosecond/microsecond jitter).

Also, sometimes Chromium is worse, if you use battery management mode on an older laptop, it often falls to the same millisecond-precision!
So this is expected and intended behavior? What does this mean for playing games or watching videos within the Firefox browser. Will it affect quality or performance in any regard?

Re: Weird Firefox stutter compared to none in Chrome/Edge

Posted: 05 Aug 2021, 21:39
by Chief Blur Buster
Kurt wrote: ↑
05 Aug 2021, 13:45
So this is expected and intended behavior?
Yes. Browser developer differences.
Kurt wrote: ↑
05 Aug 2021, 13:45
What does this mean for playing games or watching videos within the Firefox browser. Will it affect quality or performance in any regard?
Not really.

Frame rates (24fps = 41.6ms) and refresh cycles (60Hz = 16.7ms and 240Hz = 4.17ms) are so low granularity that these tiny 0.1ms or 1ms noise won't interfere with browser-based games or browser-based video.

And if you mean games in Steam, they are not web browsers, so not applicable...

This stuff is only a problem if you're getting red colored spikes like these at www.testufo.com/animation-time-graph that looks like interference by background processes even though you freshly rebooted the computer and only opened one browser tab directly to Animation Time Graph.

Image

Image

Image

In all cases, this is almost always caused by processing spikes (CPU or GPU), one person traced it to MalwareBytes. Another person traced it to CPU-hungry RGB keyboard software.

It's surprisingly how sensitive TestUFO is to detecting background CPU spikes. Those kind of spikes can interfere with game stutters too.