ZeroK-RTS / Chobby

Spring RTS Ingame lobby project
16 stars 37 forks source link

chobby constantly takes up ~22% of CPU #465

Open Fealthas opened 6 years ago

Fealthas commented 6 years ago

Idling in lobby, doing nothing. I have a 4 core system, so its about maxing out one of the cores.

Complementary bitcoin miner included with install?

Licho1 commented 6 years ago

Is your settings default? Could you try moving it to empty fodler and trying again? Is there any sort of spam in infolog_full.txt?

Fealthas commented 6 years ago

Settings mostly default. No spam in infolog_full. Same problem with moving chobby.exe and doing fresh install.

Licho1 commented 6 years ago

Similar here, ihave stornger CPU but still: When lobby window active (even under other window) CPU 11% GPU 10-25%

When lobby window minimized properly CPU 1.4% GPU 1%

When lobby window active and full speed drawn is set CPU 17%, GPU 10-30%

Licho1 commented 6 years ago

Seems highly rotten to me especially if it also drains from running game. Why does it need to use ANY CPU or GPU for static window with community?

Why is window minimized so different from window inactive? It should be possible to run with the same efficiency if nothing happens.

GoogleFrog commented 6 years ago

I am fairly sure that it barely drains from running game.

lagerspetz commented 6 years ago

When I played on the Dev Engine Testing server, a new Spring is launched, and the performance impact of the lobby running in the window behind it is noticeable.

GoogleFrog commented 5 years ago

That isn't relevant to my previous statement. The overhead of running a new Spring instance is distinct from the overhead of running an additional lua state on top of an ingame spring.

Fealthas commented 5 years ago

Just to clarify, the issue here is that the lobby maxes CPU cores, not that in-game performance is affected in any way.

Porkch0p commented 4 years ago

The FPS limiter seems to have had an update shortly before this issue was posted. After some testing that update appears to make a large number of draw calls, including while idle. If it's entirely Draw calls, that might explain why fully minimized doesn't show Chobby draining additional CPU. https://github.com/Spring-Chobby/Chobby/pull/429/commits/b81e21b9c2345a97d524727b8e825c8b07588a78

On current build, seeing lobby CPU usage hovering around 20% if left on the community tab. A workaround to give that fix reduced priority allows CPU usage to idle, and I'm not noticing any side effects on a quad core Intel+Nvidia system.

https://github.com/Porkch0p/Chobby/commit/bf0b9a7628683f2b629662f19282892dae5230ad#

Lobby Window (Active w/ user input): CPU 22% Lobby Window (Active w/ no user input): CPU 18%

Lobby Window w/ Hotfix (Active w/ user input): CPU 22% Lobby Window w/ Hotfix (Active w/ no user input): CPU 4%

Later Edit: Though it is interesting that report #269 had high idle CPU happening even before that commit, this change seems to make a difference on the current build.

GoogleFrog commented 4 years ago

Interesting. I don't recall the flicker bug. You would have to ask hokomoko to say what it was about and possibly test the PR.

GoogleFrog commented 4 years ago

@Porkch0p make a PR with your change and a lobby setting to enable it. Once the lobby update is released we can ask people to enable it and report if they see a flicker bug.

Porkch0p commented 4 years ago

Direct link to flicker bug: https://springrts.com/mantis/view.php?id=5625