Closed Bug 1759147 Opened 4 years ago Closed 4 years ago

Firefox - bad scrolling performance since update to 98.0

Categories

(Core :: Panning and Zooming, defect)

Firefox 98
Desktop
Linux
defect

Tracking

()

RESOLVED DUPLICATE of bug 1759017
Tracking Status
firefox-esr91 --- unaffected
firefox98 --- wontfix
firefox99 --- affected
firefox100 --- affected

People

(Reporter: Alexey104, Unassigned)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

Attached file about_support —

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:98.0) Gecko/20100101 Firefox/98.0

Steps to reproduce:

Update Firefox to 98.0.

Actual results:

Scrolling performance is really bad, there are a lot of lags/freezes/stutters when scrolling. All webpages are affected. The same is in firefox-nightly(100.0a1). However, scrolling is totally smooth in 97.0.2 and earlier versions of Firefox.

These are two brand new Firefox profiles - the first is 97.0.2, where the are no problems with scrolling, the second is 98.0, where scrolling is laggy and choppy:

97.0.2 - https://share.firefox.dev/3MGpQ8S
98.0 - https://share.firefox.dev/3MFhf6h

I've also attached about:support.

These are the only changes in about:config were made by me:

gfx.webrender.all = true (used according to `about:support`)
general.smoothScroll.mouseWheel.durationMaxMS = 400
general.smoothScroll.mouseWheel.durationMinMS = 200
mousewheel.min_line_scroll_amount = 40
mousewheel.system_scroll_override.enabled = false

Expected results:

Scrolling should be smooth.

Component: Untriaged → General
OS: Unspecified → Linux
Hardware: Unspecified → Desktop

Possible duplicate of bug 1759017

@vladkosi, #1759017 seems to be exactly what I am describing, thank you for pointing it out.

Thanks for the profiles. In the 98 profile is there a specific time when you are experiencing the stuttering? Or throughout the whole profile?

Would you be willing to use https://mozilla.github.io/mozregression/ to see which changeset caused the problem for you? Assuming it is consistent enough to reproduce for you.

Thank you for the reply!

(In reply to Timothy Nikkel (:tnikkel) from comment #3)

In the 98 profile is there a specific time when you are experiencing the stuttering?

No, on that particular webpage stutters are constant throughout the whole profile. On some webpages, when start to scroll, it might be smooth for a while, but suddenly "lag mode" turns on, and everything becomes slow and laggy.

Would you be willing to use https://mozilla.github.io/mozregression/ to see which changeset caused the problem for you?

Sure. I've performed tests and my results are exactly the same as @vladkosi(bug 1759017, comment 48):
395f90b6e8803ec3663a7c2356ad4affd450cd6d -> good
c55e3a40a4de20482f056a3de9e9823fb8c82768 -> bad

(In reply to Alexey104 from comment #4)

Sure. I've performed tests and my results are exactly the same as @vladkosi(bug 1759017, comment 48):
395f90b6e8803ec3663a7c2356ad4affd450cd6d -> good
c55e3a40a4de20482f056a3de9e9823fb8c82768 -> bad

In link form: https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=395f90b6e8803ec3663a7c2356ad4affd450cd6d&tochange=c55e3a40a4de20482f056a3de9e9823fb8c82768

This is bug 1571758.

Regressed by: 1571758

Set release status flags based on info from the regressing bug 1571758

:hiro, since you are the author of the regressor, bug 1571758, could you take a look?
For more information, please visit auto_nag documentation.

Flags: needinfo?(hikezoe.birchill)

(In reply to Alexey104 from comment #4)

On some webpages, when start to scroll, it might be smooth for a while, but suddenly "lag mode" turns on, and everything becomes slow and laggy.

Interesting. That's exactly same as what the other bug reporter said in bug 1759017 comment 60. I don't see any lag-ish thing in the profile in comment 0. The only difference between the profiles I noticed is that in the problematic result (on 98) I see periodic "Render reason APZ" markers in the renderer thread, but I do only see two markers in the 97 result.

Alexey104, just to confirm, did you use the same preference values for the both results, right? If it's true, then I guess bug 1571758 stops WheelScrollAnimation accidentally, I mean I suspect the markers were triggered in AsyncPanZoomController::StartAnimation.

Flags: needinfo?(hikezoe.birchill) → needinfo?(Alexey104)
Flags: needinfo?(hikezoe.birchill)

That said, a user in a Reddit thread said that scrolling on Reddit is smooth whereas it's not smooth on Google search results, there's a screen recording for those two sites, as far as I can tell, in the Reddit one doesn't have scroll linked effects, Google one does have it. So the difference should come from this offset function, but as per bug 1759017 comment 60, it seems to not be culprit. Weird.

(In reply to Hiroyuki Ikezoe (:hiro) from comment #8)

Alexey104, just to confirm, did you use the same preference values for the both results, right?

Yes. Preferences are the same for both profiles.

Flags: needinfo?(Alexey104)
Has Regression Range: --- → yes

Looks like most of users confirmed bug 1760222 mitigates the scroll shuttering. I'd hope it also mitigates this.

Flags: needinfo?(hikezoe.birchill)
See Also: → 1760222

:hiro, First of all, thank you for spending your precious time working on this, I really appreciate your passion! But my problem differs from bug 1760222. My English is terrible, but let me try to explain:

bug 1760222 is more about the visual perception of scrolling animation. But my report is specifically about the performance. I have had bug 1760222 even before Firefox 98, since updating to Quantum, but I have easily solved it by just using higher values for general.smoothScroll.mouseWheel.durationMaxMS and general.smoothScroll.mouseWheel.durationMaxMS. I confirm that 45c5738a57eb solves this issue making scrolling animation smooth with the default settings, without the need of changing anything in about:config. But what I am describing is poor performance, not just visually "graduated" scrolling animation. If I were gamer, I would call it significant "FPS drops", lags, freezes. Unfortunately, 45c5738a57eb doesn't solve my problem. Maybe this is something Nvidia related, not sure, but everything was good before c55e3a40a4de. I have tried free nouveau driver, but I have to enable software vsync in a compositor like Compton for using free driver, which makes things even worse.

Thanks for the clarification. If the profile result on 98 in comment 0 catches the performance issue you meant, there's no performance issue at all as far as I can tell. I mean "performance issues" for me is, say we do something over a vsync time, 16ms etc. there's no such things in the profile result. (I may be missing some though)

(In reply to Alexey104 from comment #12)

bug 1760222 is more about the visual perception of scrolling animation. But my report is specifically about the performance. I have had bug 1760222 even before Firefox 98, since updating to Quantum,

That sounds odd. Bug 1760222 is trying to solve an issue introduced in bug 1571758, so it shouldn't be in Quantum era.

But what I am describing is poor performance, not just visually "graduated" scrolling animation. If I were gamer, I would call it significant "FPS drops", lags, freezes.

The issue that bug 1760222 is trying to solve is, actually it looks like frame drops, if there's any scroll linked effect, in a certain condition we do composite same scroll position at two different frames, say 10px at frame 1, and 10px at frame 2 again, then 20px at frame 3, etc. etc.

The issue that bug 1760222 is trying to solve is, actually it looks like frame drops...

Honestly, I am totally inexperienced in using Bugzilla, so could you please look at the screenshot below and confirm if I downloaded the right changeset:

https://snipboard.io/m9BErp.jpg

Dear :hiro, please, ignore my yesterday response. That was my stupid fault, I apologize for misleading you. Yesterday, when I tested your build, I unpacked the archive, went into the build directory, but instead of running ./firefox I run firefox. Thus, I tested wrong version :) I confirm that the problem is gone in 45c5738a57eb changeset, scrolling is smooth again.

Thank you for your work!

Hmmm...
I've been using it for 5-7 minutes - everything was good. But suddenly it started lagging again after a while. Still observe freezes.

Especially noticible on the pages with a lot of images.

The Bugbug bot thinks this bug should belong to the 'Core::Graphics: WebRender' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: General → Graphics: WebRender
Product: Firefox → Core
Severity: -- → S3
Component: Graphics: WebRender → Panning and Zooming

Alexey104, is this still reproducible in the latest Firefox Nightly?

Flags: needinfo?(Alexey104)

I can definitely see big improvements, it is much, much better now. But there are still some stutters occur, especially at the very bottom of this page, when scrolling through the "Latest blogs" and "Latest articles" sections:
https://www.imperva.com/learn/application-security/buffer-overflow/

Although the problem still exists, the improvements are significant, the amount and frequency of lags are much less compared to 98 build, and many pages became perfectly smooth now.

Flags: needinfo?(Alexey104)

(In reply to Alexey104 from comment #20)

I can definitely see big improvements, it is much, much better now. But there are still some stutters occur, especially at the very bottom of this page, when scrolling through the "Latest blogs" and "Latest articles" sections:
https://www.imperva.com/learn/application-security/buffer-overflow/

Although the problem still exists, the improvements are significant, the amount and frequency of lags are much less compared to 98 build, and many pages became perfectly smooth now.

I agree, I am also able to reproduce lag when scrolling through the "Latest blogs" and "Latest articles" sections. In my opinion, you should close this as a duplicate of bug 1759017 and file a new one with a title like "Scrolling still stutters in some cases after landing bug 1760222", thank you.

Thank you, I'll do it.

Status: UNCONFIRMED → RESOLVED
Closed: 4 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: