Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sync changes from mozilla-central gfx/wr #4015

Merged
merged 4 commits into from Jul 15, 2020
Merged

Conversation

@moz-gfx
Copy link

moz-gfx commented Jul 15, 2020

No description provided.

Lee Salzman and others added 4 commits Jul 15, 2020
This restructures the WR Compositor interface a bit to support compositing
earlier in the frame. An invalidate_tile hook is added that gets called
first to signal that some picture cache tiles will be modified later in the
frame. The renderer then calls add_surface earlier before the picture cache
tiles are updated, so that any tiles that aren't invalid can proceed to
composite early before that. Finally, bind/unbind get called after so that
it can work potentially work in parallel with any tiles that are already
compositing early.

Differential Revision: https://phabricator.services.mozilla.com/D82473

[ghsync] From https://hg.mozilla.org/mozilla-central/rev/fceb25f6286b91d972b6451599002f8f8846f3bc
…hread. r=jrmuizel

This spawns a new SwComposite thread inside SwCompositor. Tile composite jobs
are submitted over a channel to the thread, with a condition being signaled
after all jobs are processed. The SwCompositor computes a dependency order for
the tiles based on whether it overlaps a tile that has been invalidated and
needs to be updated during the current frame. As tiles are gradually updated,
all tiles that would depend on the update as denoted by the dependency order get
submitted so that composition can proceed. Ultimately, this allows tile updates
and compositing to work in parallel, pipelining much of the cost of compositing.

Differential Revision: https://phabricator.services.mozilla.com/D82474

[ghsync] From https://hg.mozilla.org/mozilla-central/rev/b013dfd51ff69a97c2551648ee642b0f7af764b0
SwCompositor needs to send SWGL textures references safely to the SwComposite
thread. However, the SWGL context's texture store may grow and make accessing
these tables unsafe. To work around this, this patch adds a LockedResource
API that locks down access to these textures ahead of time both to ensure that
no table access is necessary and to help detect any unexpected modifications
of these textures while they are locked. These LockedResource objects can then
be composited safely in another thread without interfering with normal SWGL
operation in the original that that isn't simultaneously using these textures.

Differential Revision: https://phabricator.services.mozilla.com/D82666

[ghsync] From https://hg.mozilla.org/mozilla-central/rev/97f04a5dac7c6cb9daeb1e1d32f38111bb922891
@moz-gfx
Copy link
Author

moz-gfx commented Jul 15, 2020

@bors-servo r=auto

@bors-servo
Copy link
Contributor

bors-servo commented Jul 15, 2020

📌 Commit 721959a has been approved by auto

@bors-servo
Copy link
Contributor

bors-servo commented Jul 15, 2020

Testing commit 721959a with merge 4107a23...

@bors-servo
Copy link
Contributor

bors-servo commented Jul 15, 2020

☀️ Test successful - status-taskcluster
Approved by: auto
Pushing 4107a23 to master...

@bors-servo bors-servo merged commit 4107a23 into servo:master Jul 15, 2020
2 checks passed
2 checks passed
Community-TC (pull_request) TaskGroup: success
Details
homu Test successful
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.