Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

web animations are killing my gpu #1318

Open
tx46 opened this issue Aug 20, 2024 · 3 comments
Open

web animations are killing my gpu #1318

tx46 opened this issue Aug 20, 2024 · 3 comments

Comments

@tx46
Copy link

tx46 commented Aug 20, 2024

not sure if this is a configuration error or what.

even the smallest animations in my browser (happens to be firefox) cause about 50% gpu activity.

I have a GTX 1080 with nvidia proprietary drivers, vsync is on, backend is glx.

small animations, 24x24 pixels in my browser in this case, causes my gpu to go directly to 50%, spin up the fans and start working hard.

I suspect this is because the entire screen gets rerendered at 60hz continuously with the browser-animation running, which I thought was mitigated by use-damage (which I have set to true). killing picom reduces the gpu usage to 6-7%.

did I configure something incorrectly or what's going on?

@absolutelynothelix
Copy link
Collaborator

absolutelynothelix commented Aug 20, 2024

we use the x damage extension to know what parts of the screen have changed. however, it's mostly up to an application to report the damage. for example, xterm reports damage for each character while xfce4-terminal prefers to report damage for each line. i believe it's hard for browsers to report damage regions correctly as they display web pages so maybe the browser marks itself as entirely damaged when this small part changes. actually, you can see the damage if you use --monitor-repaint.

as for you, it's possible that damage support gets disabled as it requires some things to be available and some options not to be used. it'd be useful if you give picom's output with --log-level=info and your configuration. and maybe share your config too.

@tx46
Copy link
Author

tx46 commented Aug 20, 2024

thanks. after a bit of googling, the glx setup with nvidia seems to have issues with lag. i switched to xrender, turned vsync off, turned xrender-sync-fence on and enabled ForceCompositionPipeline in nvidia-settings for both monitors, which improved the situation drastically, but it's still too impressive and I feel like the monitors now have some input lag instead

@yshui
Copy link
Owner

yshui commented Aug 21, 2024

I think unless you can do some GPU profiling, we don't have enough information to know what's going on here. even without use-damage, i think 50% usage is abnormal (unless you have multiple high resolution monitors?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants