Bug 159708 - High CPU usage UI ribbon/menu
Summary: High CPU usage UI ribbon/menu
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.6.4.1 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: needsDevAdvice
Depends on:
Blocks: HiDPI Notebookbar
  Show dependency treegraph
 
Reported: 2024-02-13 14:42 UTC by jerry
Modified: 2024-04-16 21:25 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description jerry 2024-02-13 14:42:06 UTC
Version: 7.6.4.1 (X86_64) / LibreOffice Community
Build ID: e19e193f88cd6c0525a17fb7a176ed8e6a3e2aa1
CPU threads: 20; OS: Windows 10.0 Build 22621; UI render: default; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded

When I drag Writer from the primary display to an external display the ribbon icons start flashing and the CPU Writer is running on jumps to about 100% utilization.

This may be triggered when Windows changes the rendering to a lower resolution. My particular setup has a high resolution display for the primary display (laptop) and the secondary display is about half the resolution and re-renders the display when the Writer window goes fully to the lower resolution display.

I have been successful preventing this behavior by moving the Writer interface off the edge of the secondary monitor and moving it back again.

In order to reproduce this, you may require a high resolution monitor and lower resolution monitor.
Comment 1 breadsathwik 2024-02-14 06:32:57 UTC
UX Team -- please take a look at this enhancement. Thanks!
Comment 2 Heiko Tietze 2024-02-14 09:07:28 UTC
No issue here but no HiDPI displays (96dpi) and Linux. Ultimately a question for QA to confirm and development to investigate and fix.
Comment 3 m_a_riosv 2024-02-15 12:57:36 UTC
Maybe enable skia could help.
Menu/Tools/LibreOffice/View.
Comment 4 jerry 2024-04-15 15:47:59 UTC
I'm updating this bug report because I'm seeing, what I think are related issues. These all occur when I use an external monitor and the window is on the external monitor.

I updated the version of writer:
Version: 7.6.5.2 (X86_64) / LibreOffice Community
Build ID: 38d5f62f85355c192ef5f1dd47c5c0c0c6d6598b
CPU threads: 20; OS: Windows 10.0 Build 22631; UI render: default; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL threaded

1: Flashing of the ribbon icons.
work around: drag the window off external monitor, then back on.
2: Highlighting text with mouse or keyboard does not display any highlighting
work around: drag the window off external monitor, then back on.
3: Misspell a word, red underline does not appear.
work around: drag the window off external monitor, then back on.

Thank you!
Comment 5 jerry 2024-04-15 15:58:30 UTC
Additional information:

Primary display laptop: 2880 x 1620, 120Hz, 8-bit depth, RGB, landscape, scaling 200%
Color space: Standard (SDR)
HDR cert: VESA HDR

External display: 1920 x 1080, 60 Hz, 8 bit depth, RGB
Color space: Standard (SDR)

Interesting! I thought the mismatched refresh rates may be the problem. Yes, I set the primary monitor to 60Hz and the problem seems to go away.
Comment 6 jerry 2024-04-15 15:59:57 UTC
(In reply to jerry from comment #5)
> Additional information:
> 
> Primary display laptop: 2880 x 1620, 120Hz, 8-bit depth, RGB, landscape,
> scaling 200%
> Color space: Standard (SDR)
> HDR cert: VESA HDR
> 
> External display: 1920 x 1080, 60 Hz, 8 bit depth, RGB
> Color space: Standard (SDR)
> 
> Interesting! I thought the mismatched refresh rates may be the problem. Yes,
> I set the primary monitor to 60Hz and the problem seems to go away.

Sorry. After more experimenting, this has no effect.
Comment 7 Heiko Tietze 2024-04-16 09:07:36 UTC
How about Tools > Options > View > Skia on/off? Has been suggested to try in comment 3.
Comment 8 jerry 2024-04-16 13:26:31 UTC
Turning the Skia option eliminates most of the problems I reported: the highlighting and flashing of the ribbon.

Now I see only delays when trying to select text: the highlight lags behind the mouse by about 2 seconds. The CPU core that LibreWriter is on is nearly maxed out though.
Comment 9 jerry 2024-04-16 14:06:25 UTC
I appologize for all the entries, but I'm fascinated by the behavior of LibreWriter with my setup. When I drag the main window to the built in monitor, the app works as expected. However, merely dragging the main window to my external monitor immediately causes its CPU core to max out. Moving the window back to the built in monitor causes the CPU to basically idle.
Comment 10 Heiko Tietze 2024-04-16 14:22:09 UTC Comment hidden (off-topic)
Comment 11 m_a_riosv 2024-04-16 19:28:12 UTC
Have you tested with other app, doing the same?
Comment 12 jerry 2024-04-16 21:25:59 UTC
(In reply to m_a_riosv from comment #11)
> Have you tested with other app, doing the same?

I performed tests amoung a few applications as listed below. The only thing I noticed was a brief CPU spike as I switch window from one screen to the other. After that, the CPU settled down.

LibreOffice Calc Exhibits the same behavior as LibreOffice Writer with the difference that if you stop interacting with LibreCalc, the CPU settles down. Fascinating behavior. If you move it in the external monitor and don't touch it for a while. The CPU will start to idle. Then you can interact with it OK. If you slightly move the window around on the external monitor, it will then start maxing out the CPU. At some point, the interface freezes. Moving the main window back to the built in monitor unfreezes everything. The Skia is enabled. The other odd behavior with Calc is it seems to heavily use 2 cores, where Writer seemed to use only a single core.

CyberLink PowerDirector 14. This is multicore capable. I use it to render videos. This has a different bug: it doesn't re-render its interface, so it starts on my high res built in monitor and looks fine. After I drag it to my external monitor, it looks ugly because the interface was scaled up. It stays that way :( But it also does not exhibit high CPU usage when I shift monitors.

Notepad++ no noticable change
Arduino IDE no noticable change
Visual Studio 2023 no noticable change
GIMP no noticable change
Paint.net no noticable change
FileZilla no noticable change
Putty no noticable change
Fiddler proxy debugger no noticable change
RealVNC viewer no noticable change

That's about all I ever use. I hope this helps.