Thanks Sunny for the analysis.
Reading through the document, I think lowering the priority of OOPIF renderer process and bumping up GPU process priority is something we should experiment with.
Bumping up GPU process priority is justifiable, since it is at the end of the pipeline and would not starve other process because it would be throttled by inputs to it being generated by lower priority process. This is also similar in mental model to DWM running at high priority 13.
Bumping priority of the process vs individual threads – it appears almost all threads in the GPU process are valuable “GPU IO thread, GPU main thread, viz display compositor thread, and the vsync thread" any other threads in the GPU process are going to be workers like the shader compilation thread that we would like to have at higher priority for the same reasons.
Rather than bumping up individual renderer process threads, which has the potential to starve something else in the system that the user cares about – bumping down the priority of OOPIF renderers especially ones classified as Ads is appealing to me.
For example with the current approach for a main page with ticking CSS animations, will giving the compositor thread higher priority prioritize this animation over everything else in the system even when the renderer is not the active tab or if the window is minimized.
If we are pursuing bumping up Renderer process threads, I think it should be tied to input. The mental model here would be similar to how windows bumps up the priority of the thread corresponding to the window receiving input messages.
Perhaps it makes sense to stage these changes, especially if just prioritizing GPU process offers wins in some cases.
--
To unsubscribe from this group and stop receiving emails from it, send an email to
graphics-dev...@chromium.org.
--
You received this message because you are subscribed to the Google Groups "scheduler-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scheduler-de...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/scheduler-dev/DM6PR00MB04730B3A4857AFE451667A77FDFC0%40DM6PR00MB0473.namprd00.prod.outlook.com.
Also see +Chris Hamilton 's https://docs.google.com/document/d/1BYLWbxPreoK2Ml6qhWqThnRDjDQjfCL_DmeB1qtzBjY/edit?usp=drivesdkLe ven. 28 juin 2019 15 h 16, Gabriel Charette <g...@chromium.org> a écrit :Awesome analysis Sunny!Priority boosting has bitten us in the past too and I've been meaning to investigate disabling it : crbug.com/879097.Increasing priority of the GPU process isn't crazy either. Assuming it uses base::ThreadPool: it's BEST_EFFORT tasks, if any, would still run at low thread priority.
Making ThreadPriority::DISPLAY to THREAD_PRIORITY_HIGHEST seems slightly more dangerous. Especially since I'd like us to unify our usage of ThreadPriority::DISPLAY on all platforms (no reason to only use it on Android/CrOS IMO -- it's either right on all platforms or wrong on all platforms, platform-specific policies just make priority inversion bugs harder to spot).
PS: I don't have comment rights on the doc. Typical recommendation is to give comment access to chromi...@chromium.org (untick "send message"!) and view access to the world.
On Fri, Jun 28, 2019 at 1:41 PM 'Sushanth Rajasankar' via scheduler-dev <schedu...@chromium.org> wrote:Thanks Sunny for the analysis.
Reading through the document, I think lowering the priority of OOPIF renderer process and bumping up GPU process priority is something we should experiment with.
Bumping up GPU process priority is justifiable, since it is at the end of the pipeline and would not starve other process because it would be throttled by inputs to it being generated by lower priority process. This is also similar in mental model to DWM running at high priority 13.
Bumping priority of the process vs individual threads – it appears almost all threads in the GPU process are valuable “GPU IO thread, GPU main thread, viz display compositor thread, and the vsync thread" any other threads in the GPU process are going to be workers like the shader compilation thread that we would like to have at higher priority for the same reasons.
Rather than bumping up individual renderer process threads, which has the potential to starve something else in the system that the user cares about – bumping down the priority of OOPIF renderers especially ones classified as Ads is appealing to me.
For example with the current approach for a main page with ticking CSS animations, will giving the compositor thread higher priority prioritize this animation over everything else in the system even when the renderer is not the active tab or if the window is minimized.
If we are pursuing bumping up Renderer process threads, I think it should be tied to input. The mental model here would be similar to how windows bumps up the priority of the thread corresponding to the window receiving input messages.