Closed Bug 1533735 Opened 2 years ago Closed 2 years ago

Support reading the output of a render task in several render tasks


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




Tracking Status
firefox68 --- fixed


(Reporter: nical, Assigned: nical)


(Blocks 1 open bug)



(1 file)

As far as I can tell currently when assigning render tasks to passes we expect that a render task will be encountered only once (in other words, the expectation is that each task is a child of at most one render task).

In order to optimize stacks of drop shadows we want to allow several blur tasks to read from the same down-scaled intermediate results. We'll also need this to implement the rest of the SVG filter specification.

Priority: -- → P3

I toyed with various render task graph strategies in this repository during the last few days in PTO.

The code is here

I didn't have internet access so there are pieces of webrender and euclid that ended up copy-pasted in there and the code is not cleaned up but it's generally rather simple and documented.

For render pass creation there is a simple "linear" strategy that corresponds to what webrender does (I think) and a more advanced strategy that generates the minimum amount of render passes.

For render target allocations the code currently implements webrender's current "ping-pong" strategy as well as a more "traditional" strategy that figures out the minimum amount of targets needed without adding blit tasks.

Allocating each task render target rect is done using WebRender's former guillotine allocator implementation. The graph builder computes the lifetime of each rect and allow aliasing (which webrender currently doesn't support).

I want to add a measurement of texture memory usage and CPU time and try it on a bunch of test cases but this already pretty simple to play with (just modify the test graph in

Blocks: 1521015
Assignee: nobody → nical.bugzilla

In addition, batch together render tasks for the cached render tasks.

Attachment #9051655 - Attachment description: Bug 1533735 - Allow several render tasks to read from the output of the same task. r=gw,kvark → Bug 1533735 - Refactor render task pass assignment in preparation for the render graph work. r=gw,kvark
Depends on: 1547290
Pushed by
Refactor render task pass assignment in preparation for the render graph work. r=gw,kvark
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla68
You need to log in before you can comment on or make changes to this bug.