ferdium-app: Bug: High CPU usage caused by ProtonMail (and possibly other services?)

Avoid duplicates

  • I have searched the issues tracker for a bug report similar to mine, in vain

Ferdium Version

6.0.0.nightly.31

What Operating System are you using?

Other Linux

Operating System Version

5.17.5-arch1

What arch are you using?

x64

Last Known Working Ferdium version

No response

Expected Behavior

Ferdium on wayland utilizes as much CPU as chromium on wayland with a few tabs open.

Actual Behavior

When I open ferdium and add a few services, after a short while my fan springs into action and when I check htop, it reveals that ferdium utilizes an entire thread, for reasons unknown to me.

Steps to reproduce

It should be noted that I run ferdium with the --enable-features=UseOzonePlatform --ozone-platform=wayland --enable-features-WaylandWindowDecorations options. The bug does not appear to affect non-wayland instances. (Edit: It does, it just doesn’t do so as fast)

  1. Run ferdium
  2. Open htop
  3. Sort by maximum CPU utilization

Debug link

https://debug.ferdium.org/735bad7f-3a58-46dd-b297-b9adc4f5df6f

Screenshots

No response

Additional information

No response

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 3
  • Comments: 18 (3 by maintainers)

Most upvoted comments

I noticed that this seems to have been resolved from version 56 and up. I am currently on 58 and have about 12 services open, and my CPU is averaging at about 1%, none of the ferdium services appear at the top of the list, they appear to be at 0%. Once in a while one of them will “spike” up to about 1 or 2 percent for a moment and then go back down to 0.

I have a feeling that this was resolved on proton’s infrastructure, or coding in their webapp backend.

@palepinkdot are you still experiencing this issue?

@vraravam If no one is having this problem anymore, I think it would be safe to close this one off…

After taking a bit of a dive into it it looks like it might (I say might because I don’t have to dive into these kinds of use cases in my daily work) have to go with JVM GC major collections and rendering… Here are some screenshots of the Arch task manager and Chrome Devtools from beta 1…

I’m having a hard time believing this is a Ferdium issue, but I could be wrong. On Chromium, using the web app, the same processes are at play but seem to be less of an issue.

TL;DR - Garbage collection is CPU intensive and it looks like Proton is doing quite large cleanups.

image Screenshot_2022-06-08_23-22-47

@vraravam do you think my assumption here is correct?

I got somewhat a workaround for this. After starting Ferdium, check htop and choose the Ferdium process with the highest cpu usage, then kill it with SIGTERM.

It doesn’t affect Ferdium so far, and the app still can run normally. Might be some bug in electron. I’m using sway and running it with the corresponding args

I did that, and I found out that the process utilizing so much of my CPU is actually just the ProtonMail service, as the ProtonMail service tab crashes when I kill the process… I’d love to know why 😄