Commit Graph
24 Commits
Author SHA1 Message Date
Sylvestre Ledru e1fe74e9e3 Bug 2023419 - Remove Emacs/Vim modelines from gfx/ r=emilio
replaced by .editorconfig
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D287846
2026-03-16 12:52:50 +00:00
Lando 524ec90c1a Bug 1996124, 1996186: apply code formatting via Lando
# ignore-this-changeset
2025-10-27 02:58:08 +00:00
Lee Salzman eb2a933234 Bug 1996186 - Remove Remote Canvas. r=aosmond
Remote canvas only works with Direct2D (which has been removed) and has been superceded by Accelerated Canvas2D.
Thus, it is safe to remove remote canvas since it can no longer be enabled.

Differential Revision: https://phabricator.services.mozilla.com/D269928
2025-10-27 02:57:56 +00:00
Andrew McCreight b3623f30a2 Bug 1931877, part 2 - Replace 2 arg MOZ_DIAGNOSTIC_ASSERT(false) with MOZ_DIAGNOSTIC_CRASH. r=necko-reviewers,win-reviewers,glandium,rkraesig,valentin
Differential Revision: https://phabricator.services.mozilla.com/D229361
2024-11-20 16:37:50 +00:00
Lee Salzman 6cb99d0b64 Bug 1910138 - Disable Direct2D in Nightly. r=jrmuizel,aosmond
This disables the legacy Direct2D backend in Windows Nightly in favor
of using Accelerated Canvas2D instead. The goal of this experiment
is to collect performance and other bug feedback on AC2D versus Direct2D.

In general, AC2D has been fairly stable on other platforms, so it would be
nice to gradually move towards using AC2D on Windows as well so that we
are using one consistent acceleration solution.

This experiment is the first step towards that end.

Differential Revision: https://phabricator.services.mozilla.com/D217851
2024-07-27 09:25:23 +00:00
Sandor Molnar 43188bc6ac Backed out changeset 2f15b6efa248 (bug 1910138) for causing reftest failures CLOSED TREE 2024-07-27 12:13:07 +03:00
Lee Salzman 9a0663a779 Bug 1910138 - Disable Direct2D in Nightly. r=jrmuizel,aosmond
This disables the legacy Direct2D backend in Windows Nightly in favor
of using Accelerated Canvas2D instead. The goal of this experiment
is to collect performance and other bug feedback on AC2D versus Direct2D.

In general, AC2D has been fairly stable on other platforms, so it would be
nice to gradually move towards using AC2D on Windows as well so that we
are using one consistent acceleration solution.

This experiment is the first step towards that end.

Differential Revision: https://phabricator.services.mozilla.com/D217851
2024-07-27 07:46:02 +00:00
Lee Salzman c328b18386 Bug 1888338 - Use a single SharedContextWebgl. r=aosmond
This shares a global SharedContextWebgl among all instances of CanvasTranslator.
The goal is that regardless of how many windows are open, we only have to pay the
startup costs and shader compilation times for SharedContextWebgl once. In the
event that all CanvasTranslators are gone, the SharedContextWebgl is kept around
while its internal caches and textures are discarded to avoid significant memory
usage when no canvases are in use, while at the same time saving on startup
costs the next time a first live CanvasTranslator is created.

Differential Revision: https://phabricator.services.mozilla.com/D205977
2024-03-28 17:33:58 +00:00
Andrew Osmond 62d98779e8 Bug 1875661 - Refactor shutdown for remote canvas. r=gfx-reviewers,lsalzman
This patch makes it so that we always shutdown gracefully by making
us flush the event queue for CanvasRenderThread, after blocking on the
task queues draining. This allows our dependencies like RemoteTextureMap
to shutdown successfully.

It also fixes a bug where CanvasTranslator::CanSend would still return
true on Windows, while blocked on in CanvasTranslator::ActorDestroy
waiting for the task queue to shutdown. The CanSend status is only
updated after ActorDestroy is called from IProtocol::DestroySubtree.

Differential Revision: https://phabricator.services.mozilla.com/D199186
2024-01-25 22:22:49 +00:00
Stanca Serban 23e0c2fccc Backed out changeset e22428605dbb (bug 1875661) for causing bp-nu bustages in RefPtr.h and for causing mochitests assertion failures in WeakPtr.h. CLOSED TREE 2024-01-24 21:11:11 +02:00
Andrew Osmond 1a1d67cae3 Bug 1875661 - Refactor task queue utilization for remote canvas. r=gfx-reviewers,lsalzman
This patch makes it so that we always shutdown gracefully by making
accelerated canvas also use a TaskQueue, albeit one that just uses the
CanvasRenderThread directly. This allows us to block shutdown on the
task queues draining before advancing to shutting down other
dependencies like RemoteTextureMap.

It also fixes a bug where CanvasTranslator::CanSend would still return
true on Windows, while blocked on in CanvasTranslator::ActorDestroy
waiting for the task queue to shutdown. The CanSend status is only
updated after ActorDestroy is called from IProtocol::DestroySubtree.

Differential Revision: https://phabricator.services.mozilla.com/D199186
2024-01-24 17:58:53 +00:00
Andrew Osmond 6808c7a469 Bug 1860677 - Do not create task queue for CanvasTranslator if not using workers. r=gfx-reviewers,lsalzman
The task queue makes NS_DECL_OWNINGEVENTTARGET confusing for single
threaded uses, when the canvas expects it can just dispatch to the
CanvasRenderThread directly.

Differential Revision: https://phabricator.services.mozilla.com/D191697
2023-10-24 12:43:37 +00:00
Andrew Osmond 34d151f7e6 Bug 1852145 - Part 3. Make PCanvasManager manage PCanvas. r=gfx-reviewers,lsalzman
This patch makes the PCanvasManager protocol manage the PCanvas
protocol. This allows us to share a top level protocol and message
channel, as well as use the same thread as we need for WebGL. This will
allow future patches to do record/replay for WebGL, particularly for
configurations that do not support threadsafe GL.

Differential Revision: https://phabricator.services.mozilla.com/D187721
2023-09-25 16:18:36 +00:00
Andrew Osmond 001f5ad3b3 Bug 1852145 - Part 2. Spawn worker threads in CanvasRenderThread. r=gfx-reviewers,lsalzman
In preparation for moving PCanvas to be instantiated from
PCanvasManager, and running its IPDL objects on the virtual thread
chosen by CanvasRenderThread, this patch adds the necessary plumbing for
utilizing worker threads for PCanvas rendering.

A future patch in the series will make use of it.

Differential Revision: https://phabricator.services.mozilla.com/D187720
2023-09-25 16:18:36 +00:00
Andrew Osmond 3aaff058e3 Bug 1852145 - Part 1. Refactor CanvasRenderThread to represent a virtual thread. r=gfx-reviewers,lsalzman
Prior to this patch, CanvasRenderThread represents the concrete thread
we would spawn if gfxVars::UseCanvasRenderThread() returned true.
CanvasManagerParent was responsible for checking our state and deciding
between using the Compositor, Renderer and CanvasRender threads.

This patch makes the CanvasRenderThread class represent a virtual
thread. It will spawn a CanvasRender thread if necessary. Other classes
may use the abstraction to run on the correct thread without having to
duplicate the selection logic.

Differential Revision: https://phabricator.services.mozilla.com/D187719
2023-09-25 16:18:35 +00:00
Erich Gubler 53d3bcb40c Bug 1753349 (6/9): fix: increase CanvasRendererThread stack size to 4k r=jgilbert,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D167037
2023-01-19 04:47:53 +00:00
Stanca Serban 2120570aef Backed out 9 changesets (bug 1753349) for causing failures in PoolAlloc.cpp. CLOSED TREE
Backed out changeset 84a5f26fe60b (bug 1753349)
Backed out changeset 28e0175becf4 (bug 1753349)
Backed out changeset 0ffcaedc8046 (bug 1753349)
Backed out changeset 2043cc15deec (bug 1753349)
Backed out changeset 556557955d59 (bug 1753349)
Backed out changeset cbb9e6545343 (bug 1753349)
Backed out changeset bed90cd9beb6 (bug 1753349)
Backed out changeset 1b71f995ae95 (bug 1753349)
Backed out changeset 1ad75c8ea7a4 (bug 1753349)
2023-01-18 23:58:22 +02:00
Erich Gubler ec6965183c Bug 1753349 (6/9): fix: increase CanvasRendererThread stack size to 4k r=jgilbert,gfx-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D167037
2023-01-18 20:56:10 +00:00
Nika Layzell 119713a821 Bug 1799222 - Part 1: Prevent accidental dispatches to threadpool and timer threads, r=xpcom-reviewers,necko-reviewers,geckoview-reviewers,media-playback-reviewers,jesup,m_kato,padenot,kmag
Differential Revision: https://phabricator.services.mozilla.com/D161349
2022-12-16 17:09:16 +00:00
Cristian Tuns de12c42c7f Backed out changeset 42315c023471 (bug 1799222) for causing multiple failures CLOSED TREE 2022-12-06 16:35:58 -05:00
Nika Layzell e8f474cee1 Bug 1799222 - Prevent accidental dispatches to threadpool and timer threads, r=xpcom-reviewers,necko-reviewers,geckoview-reviewers,media-playback-reviewers,jesup,m_kato,padenot,kmag
Differential Revision: https://phabricator.services.mozilla.com/D161349
2022-12-06 20:44:15 +00:00
Jens Stutte c0d466dd8d Bug 1798298 - Use nsThread::Shutdown to shut down the CanvasRenderThread. r=gfx-reviewers,sotaro
Differential Revision: https://phabricator.services.mozilla.com/D160799
2022-11-01 10:11:27 +00:00
Jens Stutte 05e39a61b2 Bug 1797980 - Adjust CanvasRenderThread BHM and Task name, correct typo. r=gfx-reviewers,aosmond
Differential Revision: https://phabricator.services.mozilla.com/D160780
2022-10-31 12:23:51 +00:00
sotaro 9320802842 Bug 1778431 - Allocate canvas render thread for out-of-process WebGL r=gfx-reviewers,aosmond
If dedicated thread for out-of-process WebGL exists, compositor thread tasks are not delayed by WebGL tasks.

And Bug 1712486 requests that WebGL run on non-compositor thread.

Differential Revision: https://phabricator.services.mozilla.com/D151210
2022-07-08 04:02:41 +00:00