Optimize ScreenResources::{enabled_crtcs, crtc}#14
Optimize ScreenResources::{enabled_crtcs, crtc}#14Erk- wants to merge 2 commits intodzfranklin:mainfrom
Conversation
ScreenResources::enabled_crtcs: This method would cause a unnecessary allocation through ScreenResources::crtcs. crtc: This would call Crtc::from_xid on all XId's this would cause a massive amount of spam in the Xorg log files. This will now only instantiate the Crtc that is asked for.
|
Good changes, avoiding the Your change to Perhaps it would be nice to check whether the Your thoughts? |
I have added that.
Yeah I thought the same, though I attempted to not introduce any breaking changes in this pr, though it could be something to look into in the future. |
|
Sorry this issue has turned out to reveal a major oversight. I looked into the libxrandr source and found the source of the confusion here. This crate therefore should also make sure that this timestamp is properly passed to the Perhaps it is best if I fix this first, and then we continue with this PR. |
ScreenResources::enabled_crtcs: This method would cause a unnecessary allocation throughScreenResources::crtcs.ScreenResources::crtc: This would callCrtc::from_xidon allXId's this would cause a massive amount of spam in the Xorg log files. This will now only instantiate theCrtcthat is asked for.