rnote icon indicating copy to clipboard operation
rnote copied to clipboard

Windows: Long starting time

Open PhilDevProg opened this issue 9 months ago • 2 comments

Describe the bug
On my Surface Go 3, Rnote takes about 20 seconds to start on Windows, while starting in only a couple of seconds on Fedora.

To Reproduce
Steps to reproduce the behavior:

  1. Start Rnote on Windows

Expected behavior
Rnote shouldn't take that long to simply start.

Desktop (please complete the following information):

  • OS: Windows 11 23H2
  • App Version: Rnote v0.11.0

PhilDevProg avatar Mar 20 '25 21:03 PhilDevProg

Not sure how to debug this.

At the very least I can get some stack trace from intel vtune on windows to see where time is spent on the app start (in mingw for now) but this doesn't necessarily mean I can track the relation between rnote's code and the function calls I see. (We might need to have debug builds with symbol info to really have more details)

Doublonmousse avatar Mar 21 '25 17:03 Doublonmousse

Anyway I'll show the few things I managed to get for a boot on windows with vtune with some comments

Top Hotspots
    Function	Module	CPU Time	% of CPU Time
    DescribePixelFormat	gdi32full.dll	0.927s	10.6%
    func@0x1800176e0	Windows.ApplicationModel.dll	0.840s	9.6% -- https://learn.microsoft.com/en-us/uwp/api/windows.applicationmodel.core?view=winrt-26100
    func@0x18002c5ef	KERNELBASE.dll	0.589s	6.7%
    [pincrt.dll]	pincrt.dll	0.510s	5.8%
    RegOpenKeyExW	KERNELBASE.dll	0.440s	5.0% -- gtk stores the settings in regedit, and that include the engine settings
    [Others]	N/A*	5.439s	62.2%

Maybe we spent some time on loading settings. The application model from https://learn.microsoft.com/en-us/uwp/api/windows.applicationmodel.core?view=winrt-26100 seems more of a gtk issue

Effective CPU Utilization Histogram
    Simultaneously Utilized Logical CPUs	Elapsed Time	Utilization threshold
    0	5.7367668001	Idle
    1	4.2090134	Poor
    2	1.7446777	Poor
    3	0.0290417	Poor
    4	0.0165533	Poor
    5	0.0107762	Poor
    6	0	Poor
    7	0	Ok
    8	0	Ideal

Image

Doublonmousse avatar Mar 22 '25 09:03 Doublonmousse