Closed Bug 1765713 Opened 2 years ago Closed 2 years ago

High CPU usage and freeze when tooltip outside of screen

Categories

(Core :: Widget: Win32, defect)

Firefox 99
x86_64
Windows 10
defect

Tracking

()

RESOLVED DUPLICATE of bug 1764312
Performance Impact medium
Tracking Status
firefox-esr91 --- unaffected
firefox99 + wontfix
firefox100 + fixed
firefox101 + fixed

People

(Reporter: steely.wing, Unassigned)

References

(Regression)

Details

(Keywords: perf:responsiveness, regression)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:99.0) Gecko/20100101 Firefox/99.0

Steps to reproduce:

Short description

High CPU usage and freeze when mouse over item

Only happen when

  • Sidebar on right side
  • The tab title too long, and tooltip of title appear

Steps to reproduce

  1. Start Firefox with clean profile.
  2. Open a tab with long title
  3. Open Windows Task Manager
  4. Open History sidebar
  5. Move sidebar to right side
  6. Mouse over the "https://www.mozilla.org/en-US/firefox/" item and stop moving mouse (wait the title tooltip)
  7. The CPU will be very high and sometimes Firefox freeze
  8. Move mouse to outside of sidebar will resume normal

Environment

Windows 10, Firefox after 99

I can reproduce on 2 PC, so I think this is not display driver issue

Actual results:

The CPU will be very high and sometimes Firefox freeze

Update

Not all item will trigger this issue, but most of them will ( include https://www.mozilla.org/en-US/firefox/ )

This bug affect add-on like Sidebery, TST

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

Component: Untriaged → Performance
Product: Firefox → Core
OS: Unspecified → Windows 10
Hardware: Unspecified → x86_64

Hi,

Can you please collect a performance profile by using https://profiler.firefox.com/, so that we can see what is happening there?

Thanks!

Flags: needinfo?(steely.wing)

Here is it

(In reply to Sean Feng [:sefeng] from comment #4)

Hi,

Can you please collect a performance profile by using https://profiler.firefox.com/, so that we can see what is happening there?

Thanks!

Flags: needinfo?(steely.wing)

You see there have 2 periods have high CPU

Thanks! It looks like there's a burst of WM_PAINT events after every mouseover: 3000 events over the course of 2 seconds, each triggering a DisplayList build: https://share.firefox.dev/3K5itVX

Could you try to get a regression range using mozregression? https://mozilla.github.io/mozregression/install.html

Flags: needinfo?(steely.wing)
Status: UNCONFIRMED → NEW
Performance Impact: --- → P2
Component: Performance → Widget: Win32
Ever confirmed: true

This bug is trigger when the tooltip is out of screen, that mean tooltip.right > screen.width.

This not only affect sidebar, you just need to max firefox window, and move to top right menu icon, wait the tooltip to show.

Flags: needinfo?(steely.wing)
2022-04-22T15:52:21.026000: INFO : application_remotingname: firefox-nightly-autoland
2022-04-22T15:52:21.026000: INFO : application_repository: https://hg.mozilla.org/integration/autoland
2022-04-22T15:52:21.026000: INFO : application_vendor: Mozilla
2022-04-22T15:52:21.026000: INFO : application_version: 99.0a1
2022-04-22T15:52:21.026000: INFO : platform_buildid: 20220228210646
2022-04-22T15:52:21.026000: INFO : platform_changeset: cc587b2497a49af2943127c11013a4e9ed4bfbae
2022-04-22T15:52:21.027000: INFO : platform_repository: https://hg.mozilla.org/integration/autoland
2022-04-22T15:52:21.027000: INFO : platform_version: 99.0a1
2022-04-22T15:53:51.926000: INFO : Narrowed integration regression window from [92b8d062, 373efe54] (3 builds) to [cc587b24, 373efe54] (2 builds) (~1 steps left)
2022-04-22T15:53:51.933000: DEBUG : Starting merge handling...
2022-04-22T15:53:51.933000: DEBUG : Using url: https://hg.mozilla.org/integration/autoland/json-pushes?changeset=373efe5435b7ea1b0bcb96f939be32ffca256a1f&full=1
2022-04-22T15:53:51.933000: DEBUG : redo: attempt 1/3
2022-04-22T15:53:51.933000: DEBUG : redo: retry: calling _default_get with args: ('https://hg.mozilla.org/integration/autoland/json-pushes?changeset=373efe5435b7ea1b0bcb96f939be32ffca256a1f&full=1',), kwargs: {}, attempt #1
2022-04-22T15:53:51.937000: DEBUG : urllib3.connectionpool: Resetting dropped connection: hg.mozilla.org
2022-04-22T15:53:53.221000: DEBUG : urllib3.connectionpool: https://hg.mozilla.org:443 "GET /integration/autoland/json-pushes?changeset=373efe5435b7ea1b0bcb96f939be32ffca256a1f&full=1 HTTP/1.1" 200 None
2022-04-22T15:53:53.240000: DEBUG : Found commit message:
Bug 1688998: Replace empty BeginPaint/EndPaint calls with GetUpdateRect/ValidateRect. r=handyman

Differential Revision: https://phabricator.services.mozilla.com/D139776

2022-04-22T15:53:53.240000: DEBUG : Did not find a branch, checking all integration branches
2022-04-22T15:53:53.241000: INFO : The bisection is done.
2022-04-22T15:53:53.243000: INFO : Stopped

(In reply to Markus Stange [:mstange] from comment #7)

Thanks! It looks like there's a burst of WM_PAINT events after every mouseover: 3000 events over the course of 2 seconds, each triggering a DisplayList build: https://share.firefox.dev/3K5itVX

Could you try to get a regression range using mozregression? https://mozilla.github.io/mozregression/install.html

(In reply to steely.wing from comment #8)

This bug is trigger when the tooltip is out of screen, that mean tooltip.right > screen.width.

This not only affect sidebar, you just need to max firefox window, and move to top right menu icon, wait the tooltip to show.

Should I change the title of this bug?

Summary: High CPU usage and freeze when mouse over sidebar item → High CPU usage and freeze when tooltip outside of screen

Steps to reproduce

  • Max Firefox window
  • Mouse over the top-right menu button
  • Wait the tooltip to show
  • CPU usage is high

[Tracking Requested - why for this release]: Large performance regression on some Windows systems

(In reply to steely.wing from comment #9)

Bug 1688998: Replace empty BeginPaint/EndPaint calls with GetUpdateRect/ValidateRect. r=handyman

Differential Revision: https://phabricator.services.mozilla.com/D139776

Perfect, thanks! It looks like bug 1764312 is a similar regression from the same bug.

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

Flags: needinfo?(spohl.mozilla.bugs)

I am backing the offending patch out in bug 1764312.

Flags: needinfo?(spohl.mozilla.bugs)
Has Regression Range: --- → yes

Should this be resolved as a duplicate of https://bugzilla.mozilla.org/show_bug.cgi?id=1764312 ? If not, but the issue is resolved by that patch, I guess we should set the tracking flags to match.

Flags: needinfo?(mstange.moz)

It should be resolved by it, yes. I'll mark it as a duplicate.

Status: NEW → RESOLVED
Closed: 2 years ago
Flags: needinfo?(mstange.moz)
Resolution: --- → DUPLICATE

steely.wing, could you verify that the problem is fixed in the Firefox 100 RC build? You can find it at https://ftp.mozilla.org/pub/firefox/candidates/100.0-candidates/build1/

Flags: needinfo?(steely.wing)

(In reply to Markus Stange [:mstange] from comment #18)

steely.wing, could you verify that the problem is fixed in the Firefox 100 RC build? You can find it at https://ftp.mozilla.org/pub/firefox/candidates/100.0-candidates/build1/

That's working normal, thanks

Flags: needinfo?(steely.wing)
You need to log in before you can comment on or make changes to this bug.