Topic: [Fixed - persists in 3.63] High CPU usage on GNU/Linux  (Read 13085 times)


Vegtamr

« on: October 01, 2020, 08:33:50 PM »
As soon as I launch the game, one of the cores goes up to 100% and it never decreases, no matter what I do. I don't even need to start the game: just opening it is more than enough to have a 100% usage of one of my cores, even in the welcome screen. Quite annoying, I must say, especially on a laptop.

I'm using version 3.61 on a Linux Mint 19.3, but it seems it's a common issue on GNU/Linux OS, as one can see from the following discussion:
https://www.unrealworld.fi/forums/index.php?topic=5757.0

On the plus side, it's easy enough to replicate: launch the desktop version from a GNU/Linux OS, check the system monitor and you'll see one of the cores stuck at 100% for the whole time the game is runnig.
« Last Edit: June 07, 2021, 09:38:33 PM by Sami »

Sami

  • UnReal World creator
  • Administrator
  • Member
  • *****
  • Posts: 1270
  • Total likes: 3177
  • UnReal World creator
    • View Profile
    • UnReal World
« Reply #1 on: October 04, 2020, 03:53:30 PM »
So this seems to have been around for few latest versions at least. Luckily I can reproduce this (on Ubuntu), but can't quite pinpoint the reason.
Maybe it's a library thing.  A quick web search brings up some high CPU usage issues related to Nvidia together with SDL2 screen handling, but this requires more investigation.

PS. If there are any Linux players who don't get high CPU usage please drop a note. We can then probably compare setups.
- Sami | UnReal World creator

Sami

  • UnReal World creator
  • Administrator
  • Member
  • *****
  • Posts: 1270
  • Total likes: 3177
  • UnReal World creator
    • View Profile
    • UnReal World
« Reply #2 on: June 07, 2021, 09:38:15 PM »
We've good reason to believe this is fixed now. The cause was linked to how incoming SDL events are readed. Constant polling of events, which was fine with earlier SDL versions now reaches very high CPU usage especially on Linux and OSX, so we changed the method to patiently waiting for the next event. That seems to work at least on my end.

Fixed - persists in 3.63.
- Sami | UnReal World creator

Kiärme

« Reply #3 on: July 21, 2021, 06:39:04 PM »
We've good reason to believe this is fixed now. The cause was linked to how incoming SDL events are readed. Constant polling of events, which was fine with earlier SDL versions now reaches very high CPU usage especially on Linux and OSX, so we changed the method to patiently waiting for the next event. That seems to work at least on my end.

Fixed - persists in 3.63.

I'm glad to see a fix has been found. Having this issue on 3.63. Particularly bothersome, as it could be the reason I'm seeing major lag in zoomed out (ctrl + -) views. Is an update pending to be released soon?

ineedcords

« Reply #4 on: July 21, 2021, 08:46:14 PM »
<snip>
Is an update pending to be released soon?
I am not sure when the official new version will be ready however if you are suffering badly from this high cpu usage bug on linux, consider the beta option perhaps?

It is already beta3 so it is not bleeding edge anymore and should provide you with a stable-ish gaming experience without eating your cpu non-stop.
Like any other beta it may contain other bugs though so it would be wise to take a back up of your savegame before trying it.

v.3.70beta3 announcement thread:
https://www.unrealworld.fi/forums/index.php?topic=6504.0
This could be a good day to utilize your squirrels hides.

Sami

  • UnReal World creator
  • Administrator
  • Member
  • *****
  • Posts: 1270
  • Total likes: 3177
  • UnReal World creator
    • View Profile
    • UnReal World
« Reply #5 on: July 22, 2021, 04:57:44 PM »
It would be great to hear if people who noticed high CPU usage in previous versions now find it better. Feel free to speak up. I reckon it was mostly Linux and OS X issue.
- Sami | UnReal World creator

Saukko

« Reply #6 on: July 26, 2021, 02:01:47 PM »
It would be great to hear if people who noticed high CPU usage in previous versions now find it better. Feel free to speak up. I reckon it was mostly Linux and OS X issue.

It's better now in Linux with beta 3 (Ubuntu 18.04 LTS). It used to show 100% load on a single core even idle, but now it shows about 25% load when it does LOS calculations while moving around, and <10% at other times.

Sami

  • UnReal World creator
  • Administrator
  • Member
  • *****
  • Posts: 1270
  • Total likes: 3177
  • UnReal World creator
    • View Profile
    • UnReal World
« Reply #7 on: July 28, 2021, 04:49:45 PM »
It would be great to hear if people who noticed high CPU usage in previous versions now find it better. Feel free to speak up. I reckon it was mostly Linux and OS X issue.

It's better now in Linux with beta 3 (Ubuntu 18.04 LTS). It used to show 100% load on a single core even idle, but now it shows about 25% load when it does LOS calculations while moving around, and <10% at other times.

Super! Thanks for this note. So this is confirmed fixed.
- Sami | UnReal World creator

werepacman

« Reply #8 on: January 01, 2022, 07:43:05 AM »
I had same problem in old version.

 

anything