Open Bug 1624051 Opened 5 years ago Updated 8 months ago

Warm up uncached shaders during idle render periods

Categories

(Core :: Graphics: WebRender, enhancement, P3)

enhancement

Tracking

()

People

(Reporter: mstange, Unassigned)

References

(Depends on 1 open bug, Blocks 1 open bug)

Details

(Whiteboard: wr-planning)

On macOS, scrolling and other animations can jank when new shaders are encountered for the first time since Firefox was launched. It would be nice to front-load all of this jank.

Maybe we can do this during "idle" times shortly after startup.

On platforms with "program binary" shader disk caching, we could also do this, but only when the cache is empty. This would also help profile conditioning for automated performance tests on Android: it would make sure that cold page load tests don't hit shader compilation because those shaders would already have been cached into the profile during the profile conditioning run.

I'm going to look into this a bit.

Assignee: nobody → mstange
Status: NEW → ASSIGNED

Didn't end up looking into it after all, unassigning for now.

Assignee: mstange → nobody
Status: ASSIGNED → NEW
Priority: -- → P3
Assignee: nobody → dlu
Whiteboard: wr-planning
Status: NEW → ASSIGNED
Blocks: wr-mac-block
No longer blocks: wr-mac

Strategy for idle detection?

Flags: needinfo?(jmuizelaar)

So we can register an idle observer in the parent process:
https://searchfox.org/mozilla-central/source/widget/nsIdleService.cpp#398
and use it to send idle messages to the gpu process/WebRender.

Flags: needinfo?(jmuizelaar)

The bug assignee didn't login in Bugzilla in the last 7 months.
:bhood, could you have a look please?
For more information, please visit auto_nag documentation.

Assignee: dlu → nobody
Status: ASSIGNED → NEW
Flags: needinfo?(bhood)

Daniel appears to have dropped the ball here. Markus, as the reporter, do you think this needs to remain on the back burner?

Flags: needinfo?(bhood) → needinfo?(mstange.moz)

Yes, shader compilation during startup is still very visible in startup profiles and needs to be addressed at some point.

Flags: needinfo?(mstange.moz)
Severity: normal → S3
Blocks: wr-todos
You need to log in before you can comment on or make changes to this bug.