The browser mochitest in this change causes a timeout without this fix since
the overscroll gutter gets stuck thus we will never get "APZ:TransformEnd".
Differential Revision: https://phabricator.services.mozilla.com/D171421
In bug 1787520 and bug 1795614 we added a workaround for a driver bug
on Mali G78 and G710 GPUs. It turns out this also affects the G77, now
that some devices have received software updates containing an updated
driver version. This patch applies the workaround to the G77 as well,
as long as the driver version is affected.
Differential Revision: https://phabricator.services.mozilla.com/D171740
There was a case that RDD process was shut down during WebRender rendering. It happens by RDDProcess shutdown during XPCOMShutdown event. In this case, there could be a widget that nsBaseWidget::Shutdown() has not yet been called.
RDD process must be shutdown after all nsBaseWidget::Shutdown()s are called. gfxPlatform::ShutdownLayersIPC() is called immediately after XPCOMShutdown event in ShutdownXPCOM(). Then the ShutdownLayersIPC() is a good place to handle RDDProcess shutdown.
Differential Revision: https://phabricator.services.mozilla.com/D171313
This is currently used mostly for calculations related to scrollbars,
which are an example of content outside the scroll frame (and in
particular not subject to the zoom of a zoomable scroll frame).
As part of this change, FrameMetrics::
CalculateCompositionBoundsInCssPixelsOfSurroundingContent() is
renamed to CalculateCompositionBoundsInOuterCSSPixels() for brevity.
Differential Revision: https://phabricator.services.mozilla.com/D171142
In principle, the calculated scale should be 1.0 if we are not async-zoomed,
but sometimes things like rounding error can cause the scale to be slightly
off.
Differential Revision: https://phabricator.services.mozilla.com/D171437
There were two problems:
* The line scroll amount was queried in LayoutDevice pixels
and used as CSS pixels without applying the device scale.
* The thumb length was rounded in CSS pixels. To match main
thread behaviour, it needs to be rounded in LayoutDevice
pixels.
Differential Revision: https://phabricator.services.mozilla.com/D171435
Now that NotifySurfaceReady will clean up a 1-pixel strip invalid region,
this change makes HandlePartialUpdate allow a 1-pixel strip invalid
region. This should hopefully make HandlePartialUpdate only crash on the
cases that will also crash NotifySurfaceReady.
Differential Revision: https://phabricator.services.mozilla.com/D171500
There was a case that RDD process was shut down during WebRender rendering. It happens by RDDProcess shutdown during XPCOMShutdown event. In this case, there could be a widget that nsBaseWidget::Shutdown() has not yet been called.
RDD process must be shutdown after all nsBaseWidget::Shutdown()s are called. gfxPlatform::ShutdownLayersIPC() is called immediately after XPCOMShutdown event in ShutdownXPCOM(). Then the ShutdownLayersIPC() is a good place to handle RDDProcess shutdown.
Differential Revision: https://phabricator.services.mozilla.com/D171313
Now that NotifySurfaceReady will clean up a 1-pixel strip invalid region,
this change makes HandlePartialUpdate allow a 1-pixel strip invalid
region. This should hopefully make HandlePartialUpdate only crash on the
cases that will also crash NotifySurfaceReady.
Differential Revision: https://phabricator.services.mozilla.com/D171500
The problem happened by ProcessWebRenderParentCommands() handling with invalid transaction message. When a Tab is moved between Windows, WebRenderBridgeParent::UpdateWebRender() is called. It update mApi and mIdNamespace. Then all WebRender related resources are freed. Then a message with old mIdNamespace from WebRenderBridgeChild becomes invalid. Then we should not handle the obsoleted message.
Differential Revision: https://phabricator.services.mozilla.com/D170563
There are only a few things that could cause the video layer to be
rebuilt:
1) The mMutatedSpecializeVideo flag being set.
2) A new layer object being created to host for the video.
This patch more thoroughly documents instances of case 1 by adding
VIDEO_LOG message to anything that sets the mMutatedSpecializeVideo flag.
It also makes some attempt to identify case 2 by adding a VIDEO_LOG
message whenever we destroy a layer that has ever displayed a video
texture. If a log message like this is followed by a message that a new
video layer is created, it is a strong signal that we are unexpectedly
throwing away our external surface handles when we'd like to keep using
them.
Differential Revision: https://phabricator.services.mozilla.com/D171301
We're headed for a crash, so this change makes gfxCriticalError have more
information that will help us understand the crash. Unlike some other
error-checking code in this class, it is not NIGHTLY_BUILD because the
crash signatures in this Bug are reported in Beta and beyond.
Differential Revision: https://phabricator.services.mozilla.com/D171390
Lock handling is borrowed from D3D11YCbCrImage::SetData(). But ID3D11Texture2D of D3D11TextureData does not use keyed mutex. Since if D3D11_RESOURCE_MISC_SHARED_KEYEDMUTEX is used, ID3D11Texture2D could not be used for video overlay. Then D3D11TextureData uses manual synchronization with sync object like D3D11DXVA2Manager::CopyToImage().
Differential Revision: https://phabricator.services.mozilla.com/D171056
Newer Android supports multiple refresh rate that is dynamically changed.
Actually, GeckoView will always pass the refresh rate value to vsync when
getting it first time.
So this fix changes that GeckoView gets the refresh rate when vsync is started.
Differential Revision: https://phabricator.services.mozilla.com/D168665
These crashtests rely upon either a requestAnimationFrame callback or a
MozAfterPaint event. Those currently won't happen when the compositor is
paused, and on Windows these crashtests are occluded, which will now pause
the compositor. To deal with this, we disable the occlusion tracking pref
on Windows. Other platforms seem not to treat the crashtests as occluded,
so their compositors keep running.
Differential Revision: https://phabricator.services.mozilla.com/D171137
The main goal of this is to fix an implementation detail where the
WR code had to read every primitive in the tile even when checking
if a small sub-tile was valid (as the advance amounts of the
primitive dependency array vectors was stored in each primitive).
However, this patch itself is quite a significant optimization, it
improves displaylist_mutate by ~16%.
Instead of maintaining separate arrays for each dependency, use
a single byte array and use peek-poke to store these dependencies.
This simplifies the code for comparing dependencies, and makes the
traversal of sparse index buffers of the primitive array much faster.
Differential Revision: https://phabricator.services.mozilla.com/D170710
Also update some FOG tests that are now incorrect (label limits have been
lifted).
The `default_features = false` on `env_logger` are to avoid a new, duplicate
dependency on hermit-abi.
Differential Revision: https://phabricator.services.mozilla.com/D170816
During font-list initialization, we call Core Text to "activate" the supplemental language fonts,
and potentially any bundled fonts shipped with the app. But this generates an OS notification,
which if we process it will cause a redundant rebuild of our list. So to avoid this, set a flag
when we activate the fonts, telling us that the upcoming notification can be ignored.
Differential Revision: https://phabricator.services.mozilla.com/D171205
Running WebGL on the Renderer thread is causing inexplicable browsertime harness failures. Since there is
still contention with the main thread, moving WebGL work from the CanvasRenderer thread to the Renderer
thread probably has only a small impact on the incidence of bug 1777849.
However, there were other stack size issues fixed there, so we want to leave the stack size fixes in
place.
Differential Revision: https://phabricator.services.mozilla.com/D171147