Closed Bug 913461 Opened 7 years ago Closed 6 years ago

Add asynchronous transactions with replies

Categories

(Core :: Graphics: Layers, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla32

People

(Reporter: nical, Assigned: sotaro)

References

Details

Right now we have two types of transactions:
* A) asynchronous without reply: the transaction is sent to the compositor side and the child thread goes on with his life.
* B) synchronous with reply: the transaction is sent to the compositor side and the compositor side sends back a reply and the child thread is blocked until the reply is received.

I propose to add a new type of transaction
* C) asynchronous with reply: the transaction is sent asynchronously, the compositor sends back a reply asynchronously too and the child thread was not blocked in the meantime.

the current priority of modes is:
B > A (if there is an item that requires sync transaction, the transaction is sync even if other items do not need sync transactions.

the priority would become: B > C > A

Allowing asynchronous transactions with reply would let us make video frame updates asynchronous and which would greatly improve async-video performances.
asynchronous transactions with reply corresponds to what we used to do with async-video before the layers refactoring.

At first we could implement it for ImageBridge where it is most needed, but we could have performance wins from doing that on main-thread transactions too.

What do you guys think?

In term of implementation it is pretty easy: we just move the code that handle replies to it's own function (see http://dxr.mozilla.org/mozilla-central/source/gfx/layers/ipc/ImageBridgeChild.cpp?from=ImageBridgeChild.cpp#l436) and add an async message from compositor to child.
Assignee: nical.bugzilla → nobody
This doable through the AsyncTransaactionTracker mechanism, now.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Assignee: nobody → sotaro.ikeda.g
Depends on: 1000525
Target Milestone: --- → mozilla32
You need to log in before you can comment on or make changes to this bug.