allusive-dev / compfy

A Compositor for X11 based on Picom. No Longer Maintained in favor of Picom v12!
200 stars 24 forks source link

Hardware Utilisation Spikes #46

Open daricoder opened 11 months ago

daricoder commented 11 months ago

I have experienced excessive overload in the compfy process when I change the focus of windows and this overload is maintained all the time, activating the cooling, consuming a large amount of battery. The tests I did were focused on not overloading compfy, running few animations (when compfy was restarted), two to three windows and only focus changes between them. The serious problem is that it remains until you kill the compfy process. Help me knowing what I'm doing wrong or what it is due to.

I expected it not to be maintained for the entire lifetime of compfy. Let him consume what he has to consume only for the time in which great effort is required.

https://github.com/allusive-dev/compfy/assets/64455469/635db93d-ee6b-48cb-b89c-32cd9dd0d4ce

I use the same configuration as in my last issues

allusive-dev commented 11 months ago

Hey @daricoder I have gotten few people saying now about performance issues. From what I know the problem is related to memory leaks in Compfy. It's a bit strange though since I have never had Compfy go above like 5% CPU and never above 500MB of memory.

I'm looking into fixing some of the memory leak issues soon and hopefully that will fix some of these problems. Sorry I couldn't give a more direct answer.

daricoder commented 11 months ago

I was testing a little more and it is really very strange because the overhead decreases when I execute some animation or movement but when I focus on a window it fires, when that should be the other way around. In this test you see the overload at those moments.

https://github.com/allusive-dev/compfy/assets/64455469/1930e960-51fb-4343-a393-37f66b5e3ca5

I hope this information is useful in some way to help you find the problem.

nathansCodes commented 11 months ago

Hey there. I myself have not been experiencing these issues, however I've seen a steady increase in memory usage when constantly switching windows or workspaces. (starts at 67Mb, as of writing it's at 76Mb) That means the memory leaks may be coming from the fading/animation code?

daricoder commented 10 months ago

After some more tests. I can confirm that the overload only occurs in floating windows mode. When I change to the tiled windows the maximum overhead is 2 and the average is 1.2%. Even in tiled when the focus changes, it tries to fire but does not reach more than 50% for a maximum of 1 second, then it is reduced to 1.2%.

So the overload problem is only in floating mode 😕.

allusive-dev commented 10 months ago

Hey @naan187 @daricoder I didn't want to just leave you all hanging but for now I can't say when this will be resolved. I'm waiting for some new information and enough time to work on some revamps within Compfy that should fix these performance issues.