Commit Graph

36027 Commits

Author SHA1 Message Date
Glenn Watson
31585fc1e6 Bug 1608717 - Support per-tile clip (valid) region for native compositor implementations. r=sotaro,mstange
For Draw (non-native) and CA modes, we include the per-tile
valid rect in the clip rect from the surface.

For DC (non-virtual) mode, a per-tile clip rect is set on the
visual for each tile, separate from the overall clip rect that
is set on the surface visual.

For DC (virtual) mode, the Trim API is used to remove pixels
in the virtual tile area that are outside the valid / clipped
region.

Note: Although the valid rect is now applied in the native
compositors, it's currently only based on the overall picture
cache bounding rect. Thus, with this patch there isn't any
noticeable performance improvement. Once this lands and is
working correctly, the follow up patch to calculate a smaller
valid region per-tile is a small amount of work.

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

--HG--
extra : moz-landing-system : lando
2020-02-12 04:27:15 +00:00
Timothy Nikkel
f4658e4672 Bug 1613143. Don't allow an empty transaction to succeed with webrender if we haven't sent a display list to the parent. r=mattwoodrow
I think this probably only shows up with fission oop iframes, tabs probably avoid this path.

The problem occurs when we reconstruct the containing iframe for a style change, we briefly hide the child document, clearing the display list on the parent via ClearCachedResources. Then show it again, we attempt an empty transaction and this succeeds because there is nothing to stop it. (The non-wr case fails because the layer contents are missing and that causes the empty transaction to fail.)

So keep track if we have sent a display list to the parent to allow/disallow an empty transaction.

This fixes a couple webrender+fission reftest failures but it's also a general rendering bug in webrender+fission reproducible in a regular browser.

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

--HG--
extra : moz-landing-system : lando
2020-02-12 01:40:51 +00:00
Ciure Andrei
410dc434d0 Backed out changeset d46cb79a9b55 (bug 1613143)for causing reftest fission failures CLOSED TREE 2020-02-12 03:20:15 +02:00
Timothy Nikkel
68c2b57363 Bug 1613143. Don't allow an empty transaction to succeed with webrender if we haven't sent a display list to the parent. r=mattwoodrow
I think this probably only shows up with fission oop iframes, tabs probably avoid this path.

The problem occurs when we reconstruct the containing iframe for a style change, we briefly hide the child document, clearing the display list on the parent via ClearCachedResources. Then show it again, we attempt an empty transaction and this succeeds because there is nothing to stop it. (The non-wr case fails because the layer contents are missing and that causes the empty transaction to fail.)

So keep track if we have sent a display list to the parent to allow/disallow an empty transaction.

This fixes a couple webrender+fission reftest failures but it's also a general rendering bug in webrender+fission reproducible in a regular browser.

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

--HG--
extra : moz-landing-system : lando
2020-02-11 19:01:30 +00:00
Emilio Cobos Álvarez
6311bc2129 Bug 1614512 - Give mozilla::Side and mozilla::Corner a fixed underlying type. r=froydnj
So as to avoid UB. It is somewhat unfortunate/dumb the fact that we need to do
this and we can't detect when we forget to do it :(

Give it uint8_t as it's type as that's enough and consistent with LogicalSide.

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

--HG--
extra : moz-landing-system : lando
2020-02-11 14:11:06 +00:00
Brindusan Cristian
615e78b5fc Backed out changeset a91870b97f09 (bug 1611886) for xpcshell failures at test_browserid_identity.js. CLOSED TREE 2020-02-11 09:03:03 +02:00
Hiroyuki Ikezoe
1c0f15006d Bug 1599795 - Rename BrowserChild::GetRemoteDocumentRect to GetTopLevelViewportVisibleRectInBrowserCoords. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62183

--HG--
extra : moz-landing-system : lando
2020-02-11 03:35:56 +00:00
Hiroyuki Ikezoe
d4fa8f4fad Bug 1599795 - Change the remote document rect to size in gfx. r=emilio
What we really needed in the first place was the size not the rect.

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

--HG--
extra : moz-landing-system : lando
2020-02-11 03:57:14 +00:00
sotaro
c3615f343f Bug 1611886 - Add VRManagerParent::Shutdown() r=nical
Differential Revision: https://phabricator.services.mozilla.com/D61144

--HG--
extra : moz-landing-system : lando
2020-02-05 09:42:37 +00:00
sotaro
b23e6dbb81 Bug 1554610 - Destroy CompositorWindow if BasicCompositor is used r=nical
When BasicCompositor is used, BasicCompositor does not use CompositorWindow.

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

--HG--
extra : moz-landing-system : lando
2020-02-04 09:07:57 +00:00
Emilio Cobos Álvarez
f4734a4dca Bug 1614208 - Stop including nsStyleConsts.h from WebRenderTypes.h. r=jrmuizel
This is another one which is included everywhere. If the OOL call mattered we
could move these to a different header or something, but I suspect it won't.

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

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:41 +00:00
Emilio Cobos Álvarez
d7841a5f17 Bug 1614208 - Remove some include dependencies in nsStyleConsts.h. r=jfkthame,jgilbert
We include it everywhere because it's included from gfxTypes.h.

This should avoid including all the generated bindings _everywhere_.

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

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:37 +00:00
Andrew Osmond
9b47c699df Bug 1613683 - Ship WebRender on Intel/AMD devices with small screens and a battery to beta. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D62321

--HG--
extra : moz-landing-system : lando
2020-02-10 20:27:12 +00:00
Gerald Squelart
fbbc5d66db Bug 1614013 - Fix RAII Profiler object scopes - r=gregtatum
In bug 1578329 I introduced two scoping mistakes:
- A marker was made to have a shorter duration.
- A label was scoped too short and so would most likely be missed during
  sampling.
This patch reverts to the original wider scope.

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

--HG--
extra : moz-landing-system : lando
2020-02-10 20:44:33 +00:00
Mihai Alexandru Michis
0044ed8301 Backed out changeset 85ffb2302070 (bug 1600793) for causing crashes regarding DeadlockDetector
CLOSED TREE
2020-02-10 22:41:38 +02:00
Sean Feng
7c81402e17 Bug 1600793 - Make the scrolling input telemetry work for WebRender r=botond,jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D60046

--HG--
extra : moz-landing-system : lando
2020-02-10 17:41:45 +00:00
Bert Peers
0c4b6be182 Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Fourth iteration: improve the detail in reported tile invalidations.

The invalidation enum stores the old and new values for lightweight
types.  For a change in PrimCount, the old and new list of ItemUids is
stored (if logging is enabled); the tool can then diff the two to see
what was added and removed.  To convert that back into friendly strings,
the interning activity is used to build up a map of ItemUid to a string.

A similar special-casing of Content Descriptor will print the item
that's invalidating the tile, plus the origin and/or rectangle.

Also adding zoom and pan command line options both to fix high-DPI
issues and also to allow zooming out far enough to see out-of-viewport
cache lifetime and prefetching due to scrolling.

Also fix a bug where interning updates get lost if more than one update
happens without building a frame: switch to a vector of serialized
updatelists (one per type) instead of allowing just one string (per
type).

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

--HG--
extra : moz-landing-system : lando
2020-02-10 17:35:05 +00:00
Bert Peers
6713755841 Bug 1603274 - Move unsafe inside wr_thread_pool_new r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D61763

--HG--
extra : moz-landing-system : lando
2020-02-06 00:47:51 +00:00
Nicolas Silva
21cc009300 Bug 1612988 - Fix warning in a peek_poke test. r=jrmuizel
The test is meant to check that tupes work and a tuple of a single element needs a comma to differentiate it from just being the element.

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

--HG--
extra : moz-landing-system : lando
2020-02-10 14:10:26 +00:00
Botond Ballo
5a714b45fa Bug 1612750 - Use the main thread's visual viewport offset as the fallback scroll offset when APZ is force-disabled. r=tnikkel
This ensures that even if APZ is force-disabled, the permanent offset between
the visual and layout viewports is preserved during rendering.

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

--HG--
extra : moz-landing-system : lando
2020-02-10 15:20:08 +00:00
Botond Ballo
659489f090 Bug 1612750 - Move handling of IsApzForceDisabled() into the GetEffective*() functions where possible. r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D62091

--HG--
extra : moz-landing-system : lando
2020-02-10 15:19:29 +00:00
Botond Ballo
9d2b7b80cb Bug 1612750 - Simplify a misleading calculation in AsyncPanZoomController::GetCurrentAsyncTransform(). r=tnikkel
Differential Revision: https://phabricator.services.mozilla.com/D62090

--HG--
extra : moz-landing-system : lando
2020-02-10 15:19:16 +00:00
Jonathan Kew
e7b074c98a Bug 1613996 - Try to avoid instantiating an FT_Face just to read the font's charmap for FindFontForChar. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D62152

--HG--
extra : moz-landing-system : lando
2020-02-09 04:18:22 +00:00
Jeff Muizelaar
3dd8739d15 Bug 1613485. Add a new COMPOSITE_SWAP_TIME metric. r=aosmond
This should help us narrow down the regression in COMPOSITE_TIME

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

--HG--
extra : moz-landing-system : lando
2020-02-06 19:49:25 +00:00
Jamie Nicol
ec3f3be37b Bug 1613144 - Ensure async scroll offset is in correct coordinate space whilst async zooming. r=botond
Bug 1609002 made it so that the async scroll offset sent to webrender
is taken from only the layout component of the async transform, rather
than the combined layout and visual components. The consequence of
this is that the layout-only transform is in LayerPixel space (and
unnaffected by the async zoom) rather than ParentLayerPixel
space (which is affected by async zoom).

To convert the value to LayoutDevicePixel space, as webrender expects,
we were dividing by the pinch zoom scale, which includes the async
zoom. This was causing content to jump around whilst async panning and
zooming, as the scroll offset was incorrectly scaled. This is fixed
by instead dividing by the cumulative resolution, which does not
include the async zoom.

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

--HG--
extra : moz-landing-system : lando
2020-02-07 20:45:31 +00:00
David Major
7fc89d3fa3 Bug 1577236 - clang-10: Fix a -Wimplicit-int-float-conversion warning in ExtendInputEffectD2D1 r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D60998

--HG--
extra : moz-landing-system : lando
2020-02-07 18:06:11 +00:00
shindli
441a09145b Backed out 2 changesets (bug 1613144) for causing reftest failures CLOSED TREE
Backed out changeset 8124309e0bbe (bug 1613144)
Backed out changeset d5d9bf5b8d20 (bug 1613144)
2020-02-07 22:36:52 +02:00
Jamie Nicol
0a3b925a51 Bug 1613144 - Ensure async scroll offset is in correct coordinate space whilst async zooming. r=botond
Bug 1609002 made it so that the async scroll offset sent to webrender
is taken from only the layout component of the async transform, rather
than the combined layout and visual components. The consequence of
this is that the layout-only transform is in LayerPixel space (and
unnaffected by the async zoom) rather than ParentLayerPixel
space (which is affected by async zoom).

To convert the value to LayoutDevicePixel space, as webrender expects,
we were dividing by the pinch zoom scale, which includes the async
zoom. This was causing content to jump around whilst async panning and
zooming, as the scroll offset was incorrectly scaled. This is fixed
by instead dividing by the cumulative resolution, which does not
include the async zoom.

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

--HG--
extra : moz-landing-system : lando
2020-02-07 13:43:23 +00:00
Emilio Cobos Álvarez
61d0c10572 Bug 1613490 - Cleanup usage of ReferenceBox. r=miko
To avoid computing transform bounds over and over. It is generally just better.

Replace the various "overridebounds" thingies by using the "fallback" of the
transform-reference-box code which we need anyway.

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

--HG--
extra : moz-landing-system : lando
2020-02-07 13:34:42 +00:00
Marco Castelluccio
74dcb8afb2 Bug 1613514 - Disable gfx/layers/apz/test/mochitest/browser_test_group_fission.js on Linux coverage builds as it consistently times out. r=aryx
Differential Revision: https://phabricator.services.mozilla.com/D61993

--HG--
extra : moz-landing-system : lando
2020-02-07 11:13:46 +00:00
Glenn Watson
256e1fae96 Bug 1613316 - Fix panic in TileCache::pre_update. r=Bert
Differential Revision: https://phabricator.services.mozilla.com/D61922

--HG--
extra : moz-landing-system : lando
2020-02-06 21:44:44 +00:00
Nika Layzell
c56289e054 Bug 1557739 - Be more consistent with IPC Transport APIs, r=jld
Differential Revision: https://phabricator.services.mozilla.com/D60285

--HG--
extra : moz-landing-system : lando
2020-02-06 22:41:56 +00:00
Emilio Cobos Álvarez
dacbb30683 Bug 1613349 - Address one review comment I missed.
Differential Revision: https://phabricator.services.mozilla.com/D61841

--HG--
extra : moz-landing-system : lando
2020-02-06 16:11:34 +00:00
Martin Stransky
7e18aeed6a Bug 1613358 [Wayland] Implement WaylandDMABUFSurfaceImage dmabuf image, r=sotaro
Implement WaylandDMABUFSurfaceImage which is backed by dma buf memory on Wayland and it holds
decoded video images produced by ffmpeg va-api decoder.

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

--HG--
extra : moz-landing-system : lando
2020-02-06 15:15:02 +00:00
Emilio Cobos Álvarez
c5c0ef9787 Bug 1613349 - Rename nsIFrame::DeleteProperty to RemoveProperty. r=dholbert
As it doesn't necessarily call delete and that may be confusing.

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

--HG--
extra : moz-landing-system : lando
2020-02-06 16:06:49 +00:00
Emilio Cobos Álvarez
bf6256b1fc Bug 1613349 - Make nsIFrame::TakeProperty MOZ_MUST_USE. r=dholbert
Depends on D61756

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

--HG--
extra : moz-landing-system : lando
2020-02-06 00:39:10 +00:00
Brindusan Cristian
443b32771a Backed out changeset 6381c1f2aedc (bug 1613358) for build bustages at GLBlitHelper.cpp. CLOSED TREE 2020-02-06 16:15:27 +02:00
Martin Stransky
f6d5f48d74 Bug 1613358 [Wayland] Implement WaylandDMABUFSurfaceImage dmabuf image, r=sotaro
Implement WaylandDMABUFSurfaceImage which is backed by dma buf memory on Wayland and it holds
decoded video images produced by ffmpeg va-api decoder.

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

--HG--
extra : moz-landing-system : lando
2020-02-06 12:10:57 +00:00
Andrew Osmond
52c022a178 Bug 1612589 - Improve image memory reporting even further. r=tnikkel
This patch adds reporting the surface types used by the image frame in a
bit mask (such if it is a CAPTURE including a DATA_SHARED, the mask will
be 1 << CAPTURE | 1 << DATA_SHARED), as well as an estimated size
included in the report as decoded-unknown for when we do not know if the
surface is on the heap or the non-heap specifically. This is the default
implementation for a SourceSurface as well, so we should no longer have
the case where surfaces appear empty despite being in the cache. It also
makes requests being validated as always notable for reporting purposes.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 22:22:13 +00:00
Lee Salzman
4d55e5ebdb Bug 1613402 - avoid redundant adding of blob font data. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D61752

--HG--
extra : moz-landing-system : lando
2020-02-06 01:08:46 +00:00
Andrew Osmond
0173964fde Bug 1604535 - Disable OMTP on some 32-bit systems due to memory pressure. r=jrmuizel
We will no longer allow OMTP on 32-bit systems with less than 2GB of RAM
and 2 or fewer cores. These systems are unlikely to realize a benefit
from OMTP and see a higher than normal incidence of OOM crashes in the
content process due to OMTP having a higher memory footprint.

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

--HG--
extra : moz-landing-system : lando
2020-02-03 11:39:06 +00:00
shindli
0c932bb6d4 Backed out changeset f020ddf90621 (bug 1612988) for causing webrender bustage CLOSED TREE 2020-02-05 18:09:15 +02:00
Andrew Osmond
94bd8af992 Bug 1613375 - Always use reference frame origin offset in snapping transforms. r=nical
We incorporate the reference frame origin offset for non-animated
transforms, but forgot for animated transforms. Since the offset itself
is not animated, we should still incorporate it into the snapping
transform.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 15:42:20 +00:00
Nicolas Silva
e584e41b84 Bug 1612988 - Fix warning in a peek_poke test. r=jrmuizel
The test is meant to check that tupes work and a tuple of a single element needs a comma to differentiate it from just being the element.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 15:10:16 +00:00
Nicolas Silva
2c4937a4cf Bug 1612437 - Remove ipc-channel from WebRender. r=gw
Original patch from Josh Mattews

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

--HG--
extra : moz-landing-system : lando
2020-02-05 11:09:43 +00:00
sotaro
aa001195aa Bug 1612665 - Backout Bug 1596630 r=nical
SyncObjectD3D11Host::Synchronize() calling in RenderCompositorANGLE::BeginFrame() is still necessary for D3D11DXVA2Manager::CopyToImage(). Then backout Bug 1596630.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 09:39:28 +00:00
Nicolas Silva
4269e36963 Bug 1613167 - Enable/Disable rayon in WebRender via pref. r=gw
We need a way to switch it on and off to compare the performance and power usage of various test cases.
The new pref is "webrender.enable-multithreading" and does not require a restart.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 09:51:14 +00:00
Martin Stransky
c8f1770150 Bug 1613052 [Wayland] Don't release textures at WaylandDMABUFTextureHostOGL as they're owned by texture source, r=sotaro
Depends on D61547

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

--HG--
extra : moz-landing-system : lando
2020-02-05 08:31:08 +00:00
Martin Stransky
06c955cfc2 Bug 1613052 [Wayland] Use texture handle from WaylandDMABUFSurface directly at WebRender, r=sotaro
Depends on D61546

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

--HG--
extra : moz-landing-system : lando
2020-02-05 08:31:01 +00:00
Bert Peers
b2596b3344 Bug 1599327 - Use cluster scrollbar flags to select picture cache tile size. r=gw
(cherry picked from commit 348b45266ac2c2c65dcc26705dc7cf144f5e0051)

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

--HG--
extra : moz-landing-system : lando
2020-02-05 07:39:42 +00:00
Martin Stransky
849ffb22b3 Bug 1586696 [Wayland] Use wayland dmabuf as WebGL backend, r=jgilbert
- Create new SharedSurfaceType called EGLSurfaceDMABUF
- Implement EGLSurfaceDMABUF by SharedSurfaceDMABUF which is backed by WaylandDMABufSurface.
  It can be used by Wayland/EGL WebGL backend.
- It's disabled by default, can be enabled by widget.wayland_dmabuf_webgl.enabled pref.

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

--HG--
extra : moz-landing-system : lando
2020-02-05 06:32:25 +00:00
Andrew Osmond
9d3a8108a7 Bug 1613114 - Remove rounding the backdrop filter bounds during WR display list building. r=jrmuizel
No other items need to round their bounds/clips, and backdrop filters
should be no exception. They should trust scene building (and to a
lesser extent, frame building) to perform any necessary snapping. This
patch also removes the ToRoundedLayoutPoint/Rect methods as there are no
more users of the APIs, nor should there ever be.

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

--HG--
extra : moz-landing-system : lando
2020-02-04 20:24:55 +00:00
Markus Stange
19bbc2e73c Bug 1607777 - Clear areas that CARenderer repaints, so that old content doesn't accomulate in transparent areas such as the tab bar. r=jrmuizel
I consider this to be a bug in CARenderer. According to https://stackoverflow.com/questions/56150363/rendering-animated-calayer-off-screen-using-carenderer-with-mtltexture the Metal implementation has the same bug.

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

--HG--
extra : moz-landing-system : lando
2020-01-29 12:48:03 +00:00
Markus Stange
0a370169dc Bug 1607777 - Fix CARenderer invalidation when the buffer size changes. r=jrmuizel
addUpdateRect needs to be called after beginFrame, otherwise it doesn't do anything.

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

--HG--
extra : moz-landing-system : lando
2020-01-29 12:47:22 +00:00
Markus Stange
40367ae22a Bug 1607777 - When using CARenderer on HiDPI, pass device pixels to the glOrtho call and use a sublayerTransform on the root CALayer. r=jrmuizel
The CARenderer documentation does not provide any guidance on how to use CARenderer with different resolutions.
In the initial implementation I simply tried the following: Make a device-pixel sized framebuffer, call glViewport with the device pixel size, and then call glOrtho with the "point" size. And this seemed to work.
However, it doesn't always work. When hooking up profiler screenshots, I noticed that in some cases, some layers would just not be rendered. Sometimes I even saw layers show up in wrong places.
After this patch, these problems no longer appear.

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

--HG--
extra : moz-landing-system : lando
2020-01-29 12:46:44 +00:00
Andrew Osmond
c3d9e31934 Bug 1611601 - Stop snapping when calculating uv rects on the CPU side. r=gw
In bug 1574493, we moved most snapping to scene building and a minority
to frame building. No snapping is done in the shader. However there was
some left over code that still tried to replicate the past behaviour and
this caused wobbling during the rendering. This patch removes the extra
snapping on the CPU side and trusts scene/frame building to do the job.

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

--HG--
extra : moz-landing-system : lando
2020-02-04 19:06:01 +00:00
Jamie Nicol
dcf72a8a69 Bug 1569339 - Handle position: sticky correctly in webrender whilst zoomed. r=botond
Webrender positions sticky items relative to the viewport rect set on
their ancestor scroll frame, which it expects to be in local
space. The viewport should be set to what gecko calls the scroll
frame's "scroll port" (relative to its reference frame).

Previously we were setting this to be `composition bounds /
resolution`, which gives the correct results at the initial zoom
level, but causes sticky items to jump around when the zoom
changes. This occurs because the composition bounds of the RCD-RSF do
not change as the zoom changes, and instead remain equal to the
widget's size.

The layout viewport remains at the correct size when zoomed, but
unfortunately doesn't have the correct origin. And FrameMetrics does
not provide the constant "initial zoom" value we require to obtain the
desired viewport rect from the composition bounds. To fix this we
therefore must query the scroll port and offset directly from the
scrollable frame, meaning the value remains correct even as the zoom
changes.

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

--HG--
extra : moz-landing-system : lando
2020-02-04 16:40:48 +00:00
Lee Salzman
5b627ad6ad Bug 1612973 - allow opaque images to use the fast image shader. r=nical
Differential Revision: https://phabricator.services.mozilla.com/D61508

--HG--
extra : moz-landing-system : lando
2020-02-04 09:14:52 +00:00
Glenn Watson
adbb5ec13d Bug 1601865 - Fix scrollbar cache slices having extra primitives. r=nical
There's two potential cases handled by this patch:

(1) A scrollbar container followed by another scrollbar container.
    In this case, we need to ensure these are placed into separate
    clusters, even though the cluster flags otherwise match, to
    ensure that slice creation will see the two clusters.

(2) If a fixed position scroll root trails a scrollbar container.
    In this case, ensure that a scrollbar contains marks the
    cluster flags to create a slice straight after the scrollbar,
    to avoid other primitives with the same scroll root sneaking
    into the scrollbar container.

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

--HG--
extra : moz-landing-system : lando
2020-02-04 09:21:16 +00:00
Ting-Yu Lin
22ea8326d7 Bug 1610670 - Add AllPhysicalHalfCorners() to support range-based for loops. r=mats
This patch is generated via:
1. Manually modify gfx/2d/Types.h
2. Run the following script and clang-format.
3. Add brackets for the for loop in nsCSSRendering.cpp.

```

function rename() {
    echo "Renaming $1 to $2"
    rg -l "$1" | xargs sed -i -E -e s/"$1"/"$2"/g
}

rename "NS_FOR_CSS_HALF_CORNERS\(i\)" "for (const auto i : mozilla::AllPhysicalHalfCorners())"
rename "NS_FOR_CSS_HALF_CORNERS\(corner\)" "for (const auto corner : mozilla::AllPhysicalHalfCorners())"
```

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

--HG--
extra : moz-landing-system : lando
2020-02-04 03:28:47 +00:00
Ting-Yu Lin
b19983c13e Bug 1610670 - Add AllPhysicalCorners() to support range-based for loops. r=mats
This patch is generated via:
1. Manually modify gfx/2d/Types.h
2. Run the following script and clang-format.

```

function rename() {
    echo "Renaming $1 to $2"
    rg -l "$1" | xargs sed -i -E -e s/"$1"/"$2"/g
}

rename "NS_FOR_CSS_FULL_CORNERS\(i\)" "for (const auto i : mozilla::AllPhysicalCorners())"
rename "NS_FOR_CSS_FULL_CORNERS\(corner\)" "for (const auto corner : mozilla::AllPhysicalCorners())"
```

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

--HG--
extra : moz-landing-system : lando
2020-02-04 03:28:35 +00:00
Ting-Yu Lin
c81d3e5f5f Bug 1610670 - Add AllPhysicalSides() to support range-based for loops. r=mats
This patch is generated via:
1. Manually modify gfx/2d/Types.h
2. Run the following script and clang-format.

```

function rename() {
    echo "Renaming $1 to $2"
    rg -l "$1" | xargs sed -i -E -e s/"$1"/"$2"/g
}

rename "NS_FOR_CSS_SIDES\(side\)" "for (const auto side : mozilla::AllPhysicalSides())"
rename "NS_FOR_CSS_SIDES\(s\)" "for (const auto s : mozilla::AllPhysicalSides())"
rename "NS_FOR_CSS_SIDES\(i\)" "for (const auto i : mozilla::AllPhysicalSides())"
rename "NS_FOR_CSS_SIDES\(ix\)" "for (const auto ix : mozilla::AllPhysicalSides())"
```

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

--HG--
extra : moz-landing-system : lando
2020-02-04 03:28:27 +00:00
Oana Pop Rus
bc5a36afbd Backed out changeset e9ec1b50f99a (bug 1506376) for devtools multiple failures in browser_animation_keyframes-graph_special-colors.js 2020-02-04 03:43:28 +02:00
Glenn Watson
9b0c2f7a0e Bug 1608280 - Part 1 - Add a valid_rect to picture cache and composite tiles. r=mstange
This patch introduces a per-tile valid rect. In the initial implementation,
this only uses the bounds of the overall picture cache bounding rect. The
next part of this patch will make use of true per-tile valid regions, to
improve performance where there are holes in a single cache slice.

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

--HG--
extra : moz-landing-system : lando
2020-02-03 23:16:54 +00:00
Olli Pettay
3cae7adb8a Bug 1506376, make DidComposite to use mediumhigh priority message r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D61083

--HG--
extra : moz-landing-system : lando
2020-02-03 21:00:01 +00:00
Jim Blandy
2436afd008 Bug 1571974: Simplify orientation handling in line decoration shaders. r=kvark
We want to use the same line decoration (dashed, dotted, wavy) shader code for
both horizontal and vertical lines, so it makes sense for them to use a
coordinate system that has been rotated (transposed, actually) so that .x always
runs parallel to the line being decorated, and .y is always perpendicular.

Before this patch, we passed the orientation enum as a vertex attribute, used a
switch to swap coordinates in the vertex shader, and then swapped them again in
the fragment shader.

This patch trades the orientation for a f32 'axis select' vertex attribute, and
uses `mix` to swap them in the vertex shader. Then no consideration is necessary
in the fragment shader: the vLocalPos varying is already in the appropriate form.

Since get_line_decoration_sizes is already thinking in terms of line-parallel
coordinates, it might seem like a good idea for decoration jobs to simply use
line-parallel coordinates throughout. However, this actually results in more
swapping and opportunities for confusion: much of the CPU work is concerned with
the rectangle the decoration's mask occupies in the texture cache, which is
axis-aligned.

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

--HG--
extra : rebase_source : 8dcd8455c664067dd25f583c944d611a35c25e79
extra : source : dfb21632ea198c1acdc6a34ee08113d516f666d5
2020-01-24 21:46:56 +00:00
Jim Blandy
3e1f7b939b Bug 1571974: Make prim_store::get_line_decoration_sizes return an oriented LayoutSize. r=kvark
Without this change, get_line_decoration_sizes returns an (inline_size,
block_size) pair, where inline_size is parallel to the line being decorated, and
block_size perpendicular. However, these values are generally used as the
dimensions of an axis-aligned bounding box for the line, not as specific
parameters to the rendering process, so it makes sense to arrange them into a
LayoutSize value in this function, since it is already taking the orientation
into account anyway.

The caller, SceneBuilder::add_line, then doesn't need to swap the components,
and the adjustment of the clipping rectangle to avoid partial dots looks a bit
more natural: widths with widths, heights with heights.

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

--HG--
extra : rebase_source : 093d572a7a35bddc6e070fc08d511f7f164a4d89
extra : source : 3549dd471446c291864822736f4587c81741cd56
2020-02-03 09:31:22 +00:00
Oana Pop Rus
96b8905f87 Backed out 2 changesets (bug 1571974) for turning bug 1518179 into perma bc failures. on a CLOSED TREE
Backed out changeset dfb21632ea19 (bug 1571974)
Backed out changeset 3549dd471446 (bug 1571974)
2020-02-03 22:00:29 +02:00
Jonathan Kew
2d4e9aeb66 Bug 1611997 - Invert the sign of the slant angle when mapping between CSS font-style and OpenType 'slnt' axis. r=jwatt
Differential Revision: https://phabricator.services.mozilla.com/D61228

--HG--
extra : moz-landing-system : lando
2020-01-31 15:05:52 +00:00
Jim Blandy
279cadb72a Bug 1571974: Simplify orientation handling in line decoration shaders. r=kvark
We want to use the same line decoration (dashed, dotted, wavy) shader code for
both horizontal and vertical lines, so it makes sense for them to use a
coordinate system that has been rotated (transposed, actually) so that .x always
runs parallel to the line being decorated, and .y is always perpendicular.

Before this patch, we passed the orientation enum as a vertex attribute, used a
switch to swap coordinates in the vertex shader, and then swapped them again in
the fragment shader.

This patch trades the orientation for a f32 'axis select' vertex attribute, and
uses `mix` to swap them in the vertex shader. Then no consideration is necessary
in the fragment shader: the vLocalPos varying is already in the appropriate form.

Since get_line_decoration_sizes is already thinking in terms of line-parallel
coordinates, it might seem like a good idea for decoration jobs to simply use
line-parallel coordinates throughout. However, this actually results in more
swapping and opportunities for confusion: much of the CPU work is concerned with
the rectangle the decoration's mask occupies in the texture cache, which is
axis-aligned.

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

--HG--
extra : moz-landing-system : lando
2020-01-24 21:46:56 +00:00
Jim Blandy
b524ca8410 Bug 1571974: Make prim_store::get_line_decoration_sizes return an oriented LayoutSize. r=kvark
Without this change, get_line_decoration_sizes returns an (inline_size,
block_size) pair, where inline_size is parallel to the line being decorated, and
block_size perpendicular. However, these values are generally used as the
dimensions of an axis-aligned bounding box for the line, not as specific
parameters to the rendering process, so it makes sense to arrange them into a
LayoutSize value in this function, since it is already taking the orientation
into account anyway.

The caller, SceneBuilder::add_line, then doesn't need to swap the components,
and the adjustment of the clipping rectangle to avoid partial dots looks a bit
more natural: widths with widths, heights with heights.

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

--HG--
extra : moz-landing-system : lando
2020-02-03 09:31:22 +00:00
Jonathan Kew
ab65dd885f Bug 1612822 - Refactor text decoration offset/thickness computations. r=emilio
We replace SetWidthIfLength and SetOffsetIfLength with ComputeDecorationLine{Thickness,Offset} functions,
and consolidate more of the computation of the offset within this function to simplify callers.

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

--HG--
extra : moz-landing-system : lando
2020-02-03 14:38:47 +00:00
Robert Mader
829aab8587 Bug 1474281 - Remove unneeded debug print. r=jgilbert
Differential Revision: https://phabricator.services.mozilla.com/D48102

--HG--
extra : moz-landing-system : lando
2020-01-31 17:17:49 +00:00
Andrew Osmond
8370ff7b34 Bug 1611193 - Allow WebRender on late beta/release for recent Windows 10 builds and NVIDIA drivers. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D61373

--HG--
extra : moz-landing-system : lando
2020-01-31 16:18:15 +00:00
sotaro
602ffd4254 Bug 1612256 - Change VRManagerChild::ShutDown() similar to CompositorBridgeChild::ShutDown() r=nical
Differential Revision: https://phabricator.services.mozilla.com/D61263

--HG--
extra : moz-landing-system : lando
2020-01-31 08:20:56 +00:00
Jamie Nicol
e0d0ac8af5 Bug 1610952 - Ensure webrender's async scroll offsets are in correct coordinate space. r=botond
For zoomable APZCs, we were correctly dividing the scroll offset by
the pinch zoom scale. This is effectively equal to multiplying by the
device pixel ratio then dividing by the zoom, converting the offset
from parent layer space to layout device space.

However, for non-zoomable APZCs, we were incorrectly assuming that the
pinch zoom scale equalled 1.0. This was causing us to send incorrectly
scaled async scroll offsets to webrender, resulting in content moving
too slowly or quickly whilst asynchronously panning, then suddenly
jumping as the synchronous scroll offset caught up.

This is fixed by ensuring we always divide the asynchronous scroll
offset by the pinch zoom scale, regardless of whether the APZC is
zoomable or not.

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

--HG--
extra : moz-landing-system : lando
2020-01-31 08:52:11 +00:00
Dorel Luca
983a71b2a4 Backed out changeset 9dc9deb3ba3b (bug 1611660) for Reftest failure in layout/reftests/bugs/605138-1.html == layout/reftests/bugs/605138-1-ref.html 2020-01-31 01:44:08 +02:00
Andrew Osmond
ff69c48b54 Backed out changset b371f612cd60 (Bug 1604535) for performance regressions.
Differential Revision: https://phabricator.services.mozilla.com/D61298

--HG--
extra : moz-landing-system : lando
2020-01-30 13:11:08 +00:00
Kousuke Takaki
04bba6950f Bug 1602088 - Move nsIScrollableFrame::ScrollUnit to namespace scope. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D61140

--HG--
extra : source : 69fded25adc2ac25e302b49c1128f8926e1311a3
2020-01-30 09:13:19 +00:00
Andrew Osmond
de9131c720 Bug 1612207 - SourceSurfaceCapture::IsValid should validate any underlying surfaces. r=jrmuizel
SourceSurfaceCapture can contain an underlying surface instead of a set
of drawing commands. The surface has its own valid state, and must be
checked by the parent in SourceSurfaceCapture::IsValid. If we don't,
then we may end up failing silently while drawing, and images will go
missing. The underlying surface can be invalidated by a device reset if
it is a SourceSurfaceD2D1, as an example.

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

--HG--
extra : moz-landing-system : lando
2020-01-30 12:24:25 +00:00
Cosmin Sabou
5a3d320cd0 Backed out changeset 69fded25adc2 (bug 1602088) for causing several box-shadow reftest failures.
CLOSED TREE
2020-01-30 13:23:10 +02:00
Greg V
2befd54d63 Bug 1484812 - Use SwapBuffersWithDamage on EGL platforms (Wayland/Android) r=jnicol,mstange,jgilbert
EGL_KHR_swap_buffers_with_damage (or EGL_EXT_swap_buffers_with_damage)
is an EGL extension that allows the application to inform the display
server (system compositor) which areas of the window have changed.

This commit implements support for that extension in the layers compositor.
The layers compositor always renders the whole frame, so we're only getting
the benefit of not redrawing unchanged areas *in the system compositor*,
not actually doing partial invalidation/compositing,
but that makes the implementation simpler (no need to track buffer age).

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

--HG--
extra : moz-landing-system : lando
2020-01-30 10:46:54 +00:00
Botond Ballo
f62b4f716b Bug 1611660 - Accept layout viewport updates from the main thread right away. r=tnikkel
Previously, we would wait until the following frame (for uncertain reasons
that date back to B2G), but this meant the layout and visual viewports would
be out of sync for a frame, causing APZ to misbehave.

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

--HG--
extra : moz-landing-system : lando
2020-01-30 10:48:34 +00:00
Glenn Watson
05a7f239ed Bug 1606251 - Fix invalidation for elements with inflation factors. r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D61261

--HG--
extra : moz-landing-system : lando
2020-01-30 09:44:45 +00:00
Kousuke Takaki
9681569b70 Bug 1602088 - Move nsIScrollableFrame::ScrollUnit to namespace scope. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D61140

--HG--
extra : moz-landing-system : lando
2020-01-30 09:13:19 +00:00
Bert Peers
2143f0959d Bug 1605508 - Write new on-boarding document with rendering overview
Some updates and clarifications after Glenn's All Hands 2020 overview
talk.

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

--HG--
extra : moz-landing-system : lando
2020-01-30 08:51:03 +00:00
Nicolas Silva
2a19b8ea5d Bug 1611948 - Rename ClipScrollTree into SpatialTree. r=gw
There is nothing clipping related in there anymore.

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

--HG--
rename : gfx/wr/webrender/src/clip_scroll_tree.rs => gfx/wr/webrender/src/spatial_tree.rs
extra : moz-landing-system : lando
2020-01-29 10:43:20 +00:00
Bert Peers
123e2ce473 Bug 1605283 - Improve support for invalidation debugging and testing r=nataliaCs
Differential Revision: https://phabricator.services.mozilla.com/D61207

--HG--
extra : moz-landing-system : lando
2020-01-29 05:21:52 +00:00
sotaro
45e4405493 Bug 1611743 - Handle IDCompositionSurface::BeginDraw() error r=nical
Differential Revision: https://phabricator.services.mozilla.com/D61101

--HG--
extra : moz-landing-system : lando
2020-01-28 15:22:23 +00:00
Bert Peers
05e00eed63 Bug 1605283 - Improve support for invalidation debugging and testing r=gw a=reland CLOSED TREE
Third iteration:

Fix broken scrolling (and incorrect positioning of quad tree lines) by
serializing the SpaceMapper(-transform) from take_context, and using it
to transform the primitive rects (instead of the previous translation
based on unclipped.origin);
Note: this is done at visualization time and not at export time to
distinguish actually moving elements from merely-scrolling ones.

Serialize the entire UpdateList, so we get the data (Keys) that's being
added; add it to the overview;

Move the static CSS code into tilecache_base.css; add this and the .js
file to the binary, write them as part of output (instead of manual
copy); clean up CSS a bit;

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

--HG--
extra : source : 535ae1d4818a3f0af64d61846035135751352bd1
extra : histedit_source : bf9a8f830ec7db4c2d1fcb6deaaf72949d6b69ed
2020-01-28 20:05:38 +00:00
Csoregi Natalia
25b1fb82cf Backed out changeset 535ae1d4818a (bug 1605283) for cargo related bustage. CLOSED TREE 2020-01-28 22:56:27 +02:00
Bert Peers
cd0e366e52 Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Third iteration:

Fix broken scrolling (and incorrect positioning of quad tree lines) by
serializing the SpaceMapper(-transform) from take_context, and using it
to transform the primitive rects (instead of the previous translation
based on unclipped.origin);
Note: this is done at visualization time and not at export time to
distinguish actually moving elements from merely-scrolling ones.

Serialize the entire UpdateList, so we get the data (Keys) that's being
added; add it to the overview;

Move the static CSS code into tilecache_base.css; add this and the .js
file to the binary, write them as part of output (instead of manual
copy); clean up CSS a bit;

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

--HG--
extra : moz-landing-system : lando
2020-01-28 20:05:38 +00:00
sotaro
9fbc3e628e Bug 1605777 - Clear WrappingTextureSourceYCbCrBasic::mTexture correctly r=nical
Differential Revision: https://phabricator.services.mozilla.com/D60639

--HG--
extra : moz-landing-system : lando
2020-01-23 11:11:46 +00:00
Miko Mynttinen
99dc805fb4 Bug 1558926 - Part 5: Store a reference to cached display item data in DisplayItemRef
Differential Revision: https://phabricator.services.mozilla.com/D60761

--HG--
extra : moz-landing-system : lando
2020-01-27 14:19:50 +00:00
Miko Mynttinen
f2d9974935 Bug 1558926 - Part 4: Avoid display list updates for removed pipelines
Differential Revision: https://phabricator.services.mozilla.com/D60760

--HG--
extra : moz-landing-system : lando
2020-01-27 14:19:17 +00:00
Miko Mynttinen
d889583615 Bug 1558926 - Part 3: Add support for additional WebRender display list data
Differential Revision: https://phabricator.services.mozilla.com/D60759

--HG--
extra : moz-landing-system : lando
2020-01-27 14:18:49 +00:00
Miko Mynttinen
fba2799f7a Bug 1558926 - Part 2: Use DisplayItemCache in WebRenderCommandBuilder
Differential Revision: https://phabricator.services.mozilla.com/D60756

--HG--
extra : moz-landing-system : lando
2020-01-27 14:18:17 +00:00
Miko Mynttinen
5c231763e7 Bug 1558926 - Part 1: Add data structures and pref for display item caching r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D50221

--HG--
extra : moz-landing-system : lando
2020-01-27 14:17:43 +00:00
Jonathan Kew
4a6c3ec3f6 Bug 1611610 - Don't increase glyph advance for synthetic bold if the glyph is zero-width. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D61065

--HG--
extra : moz-landing-system : lando
2020-01-25 15:43:45 +00:00
Jonathan Kew
f360407017 Bug 1611589 - Fix precedence of font-feature-settings vs disabling of ligatures due to letter-spacing. r=lsalzman
Differential Revision: https://phabricator.services.mozilla.com/D61060

--HG--
extra : moz-landing-system : lando
2020-01-25 12:18:00 +00:00
Hiroyuki Ikezoe
677e8ea65a Bug 1594451 - Apply fixed margin offset for position sticky layers/nodes depending on where it's stuck to. r=botond
We currenly only support the dynamic toolbar at bottom, so we apply the
`fixed margin offset` only if the sticky element is stuck at the bottom
of the root scroll container.

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

--HG--
extra : moz-landing-system : lando
2020-01-25 11:00:08 +00:00
Hiroyuki Ikezoe
5d9fe8f9ea Bug 1594451 - Propagate sticky position info to HitTestingNode. r=botond
Differential Revision: https://phabricator.services.mozilla.com/D60065

--HG--
extra : moz-landing-system : lando
2020-01-25 10:25:16 +00:00
Botond Ballo
7ce6d46176 Bug 1611523 - Use the current layers id to simplify IsFixedToRootContent(). r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D61016

--HG--
extra : moz-landing-system : lando
2020-01-25 00:23:44 +00:00
Botond Ballo
a20a5d30fe Bug 1611523 - Track the current layers id during the layer tree traversal in AsyncCompositionManager::ApplyAsyncContentTransformToTree(). r=hiro
Differential Revision: https://phabricator.services.mozilla.com/D61015

--HG--
extra : moz-landing-system : lando
2020-01-25 00:23:34 +00:00
Jim Blandy
c86b4ea822 Bug 1571974: Implement Debug for render_target::LineDecorationJob. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D60924

--HG--
extra : moz-landing-system : lando
2020-01-24 15:42:04 +00:00
David Major
307e4dcb5b Bug 1611476 - Silence a rule-of-three warning in nsRect r=botond
nsRect's special member functions are pretty vanilla aside from the MOZ_COUNT_{C,D}TORs, so the copy assignment doesn't need to do anything unusual, but let's state so explicitly to please the compiler.

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

--HG--
extra : moz-landing-system : lando
2020-01-24 18:58:23 +00:00
Brindusan Cristian
5ca7181fab Backed out 5 changesets (bug 1558926) for WebRender build bustages. CLOSED TREE
Backed out changeset 974bcab6b1bf (bug 1558926)
Backed out changeset 1865e6d29dcf (bug 1558926)
Backed out changeset 92b415dac733 (bug 1558926)
Backed out changeset 30481c41873a (bug 1558926)
Backed out changeset a4d9a1af297a (bug 1558926)
2020-01-24 20:42:16 +02:00
Miko Mynttinen
c210c95ca3 Bug 1558926 - Part 5: Store a reference to cached display item data in DisplayItemRef
Depends on D60760

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

--HG--
extra : moz-landing-system : lando
2020-01-22 22:19:49 +00:00
Miko Mynttinen
64997c1922 Bug 1558926 - Part 4: Avoid display list updates for removed pipelines
Depends on D60759

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

--HG--
extra : moz-landing-system : lando
2020-01-22 22:19:08 +00:00
Miko Mynttinen
b16cae3e0b Bug 1558926 - Part 3: Add support for additional WebRender display list data
Depends on D60756

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

--HG--
extra : moz-landing-system : lando
2020-01-22 22:43:59 +00:00
Miko Mynttinen
7a53d2c64c Bug 1558926 - Part 2: Use DisplayItemCache in WebRenderCommandBuilder
Depends on D50221

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

--HG--
extra : moz-landing-system : lando
2020-01-22 22:41:06 +00:00
Miko Mynttinen
e9f5497f95 Bug 1558926 - Part 1: Add data structures and pref for display item caching r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D50221

--HG--
extra : moz-landing-system : lando
2020-01-22 22:17:18 +00:00
Dzmitry Malyshau
be7fae486d Bug 1609175 - WebGPU bind groups and compute pipelines r=jgilbert,webidl,smaug,bzbarsky
Adds support for bind groups and compute pipelines
The end goal of this PR is to run the compute example.

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

--HG--
extra : moz-landing-system : lando
2020-01-24 16:27:09 +00:00
Noemi Erli
835cec6cf9 Backed out changeset 136b3044f6a6 (bug 1609175) for causing build bustages in WebGPUChild.cpp CLOSED TREE 2020-01-24 17:20:31 +02:00
Dzmitry Malyshau
73eff15f2c Bug 1609175 - WebGPU bind groups and compute pipelines r=jgilbert,webidl,smaug,bzbarsky
Adds support for bind groups and compute pipelines
The end goal of this PR is to run the compute example.

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

--HG--
extra : moz-landing-system : lando
2020-01-24 05:05:34 +00:00
Bert Peers
6ac6d71555 Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Second part: trace the updates that are sent to the DataStore, and save
at least the Insert/Remove and ItemUID as part of the wr-capture.
(We could expand this with more info, eg. the actual Keys, later).

TileView then reads them back and generates a color coded report to
overlay with the page view.  This helps to see the types and amounts of
interned primitives that lead to cache invalidations.

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

--HG--
extra : moz-landing-system : lando
2020-01-24 07:26:32 +00:00
Glenn Watson
a688008906 Bug 1611331 - Tidy up rect field naming in picture cache code. r=Bert
Differential Revision: https://phabricator.services.mozilla.com/D60921

--HG--
extra : moz-landing-system : lando
2020-01-24 03:24:35 +00:00
sotaro
56b30bd8c4 Bug 1602643 - Disable WebRender compositor dinamically for async screenshot r=gw
Differential Revision: https://phabricator.services.mozilla.com/D59658

--HG--
extra : moz-landing-system : lando
2020-01-23 23:52:05 +00:00
Andreea Pavel
f0fa29abdf Backed out changeset 77d7f22c81c4 (bug 1605283) for wrench build bustages on a CLOSED TREE 2020-01-24 01:19:22 +02:00
Nicolas Silva
ea36628e1e Bug 1611176 - Avoid expensive memmoves when adding render tasks. r=gw
On pages with many render tasks (typically a lot of text shadows), we spend a lot of time moving RenderTask which is a fairly large struct into the render graph's buffer. This patch avoids it by using the VecHelper trick of allocaitng space before initializing the value. Some RenderTask::new_* methods which take the render task graph in parameter were modified to add the task and return the task ID to work around borrow-checking restriction.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 19:26:13 +00:00
Bert Peers
2d5981811a Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Second part: trace the updates that are sent to the DataStore, and save
at least the Insert/Remove and ItemUID as part of the wr-capture.
(We could expand this with more info, eg. the actual Keys, later).

TileView then reads them back and generates a color coded report to
overlay with the page view.  This helps to see the types and amounts of
interned primitives that lead to cache invalidations.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 22:20:47 +00:00
Nicolas Silva
cca4fcdf86 Bug 1606771 - Add a reftest. r=kvark
Differential Revision: https://phabricator.services.mozilla.com/D59901

--HG--
extra : moz-landing-system : lando
2020-01-23 14:20:27 +00:00
Nicolas Silva
0f0223fc9b Bug 1606771 - Fix border image repetition computation. r=gw
The computation of the repetition depends on the aspect ratio of the segment's uv rectangle, which was previously represented by the dx/dy variables in the shader. These were mistakenly computing the ratio of the normalized uvs within the primitive's total uv rect, which was incorrect since the normalization introduces a non-uniform scale.
This patch fixes it by taking the uv size in device pixels instead of the the normalized textel rect. dx and dy are also renamed into segment_uv_size which is a more informative name.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 14:24:57 +00:00
Nicolas Silva
512f63684e Bug 1606771 - Fix the middle area of border-image nine-patches. r=gw
Unlike the border areas that only nead their own dimensions, the middle area of a border-image determines its repetition parameter based on the size of the borders. A new flag is provided for the brush_image shader to know whether to use the segment's own rect or look at the borders when computing the pattern's size.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 14:26:32 +00:00
Nicolas Silva
725d18b7cb Bug 1606771 - Implement border-image-repeat: round in WebRender. r=jrmuizel,kvark
border-image-repeat: Round is equivalent to Repeat with the pattern size adjusted to fill the area with a whole number of repetitions. This is done by adjusting the segment's stretch_size in the shader so that it fits a whole number of times in the segment's size.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 14:24:11 +00:00
Nicolas Silva
7c24851526 Bug 1608156 - Fix border-image-repeat: repeat in WebRender. r=gw
Differential Revision: https://phabricator.services.mozilla.com/D59356

--HG--
extra : moz-landing-system : lando
2020-01-23 14:24:11 +00:00
Mihai Alexandru Michis
d8a8849254 Backed out changeset f3b490c076d6 (bug 1602643) for causing bustages regarding CompositorKindChanged
CLOSED TREE
2020-01-23 16:27:33 +02:00
sotaro
7afb826ef9 Bug 1602643 - Disable WebRender compositor dinamically for async screenshot r=gw
Differential Revision: https://phabricator.services.mozilla.com/D59658

--HG--
extra : moz-landing-system : lando
2020-01-23 04:37:28 +00:00
Bob Owen
60b9eebd75 Bug 1604800 Part 2: Remove DataSourceSurfaceRecording from DrawTargetRecording. r=jrmuizel
This is done by using CreateDataSourceSurfaceWithStrideFromData to create a
DataSourceSurface and then OptimizeSourceSurface to record and optimize that.
This means that we now only have SourceSurfaceRecording using SurfaceType
RECORDING. We then rely on this to improve the test in OptimizeSourceSurface to
check that a SourceSurfaceRecording is for its recorder.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 21:23:08 +00:00
Bob Owen
78557e5083 Bug 1604800 Part 1: Add a new WRAP_AND_RECORD SurfaceType for SourceSurfaceWrapAndRecord. r=jrmuizel
This is to avoid type confusion with SourceSurfaceRecording.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 21:21:08 +00:00
Daniel Varga
c9be72d45a Backed out changeset 7ed018d13880 (bug 1605283) for causing build bustage with could not compile webrender error.
CLOSED TREE
2020-01-23 08:46:54 +02:00
Bert Peers
66117dbb5f Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Second part: trace the updates that are sent to the DataStore, and save
at least the Insert/Remove and ItemUID as part of the wr-capture.
(We could expand this with more info, eg. the actual Keys, later).

TileView then reads them back and generates a color coded report to
overlay with the page view.  This helps to see the types and amounts of
interned primitives that lead to cache invalidations.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 06:22:26 +00:00
Jeff Gilbert
7760c4fddf Bug 1608235 - [ANGLE] Validate context before use. r=sotaro
Differential Revision: https://phabricator.services.mozilla.com/D60790

--HG--
extra : moz-landing-system : lando
2020-01-23 02:59:17 +00:00
Ciure Andrei
6ee379ce4c Backed out changeset 2e04c320ad23 (bug 1605283) for causing build bustages CLOSED TREE 2020-01-23 04:28:44 +02:00
Bert Peers
583661abdb Bug 1605283 - Improve support for invalidation debugging and testing r=gw
Second part: trace the updates that are sent to the DataStore, and save
at least the Insert/Remove and ItemUID as part of the wr-capture.
(We could expand this with more info, eg. the actual Keys, later).

TileView then reads them back and generates a color coded report to
overlay with the page view.  This helps to see the types and amounts of
interned primitives that lead to cache invalidations.

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

--HG--
extra : moz-landing-system : lando
2020-01-23 00:12:13 +00:00
Jeff Muizelaar
cce8fe4d25 Bug 1610949 - Only use WS_EX_NOREDIRECTIONBITMAP when using DirectComposition. r=gw
Differential Revision: https://phabricator.services.mozilla.com/D60744

--HG--
extra : moz-landing-system : lando
2020-01-22 21:23:35 +00:00
Boris Chiou
98e40ec294 Bug 1592822 - Replace StyleVecU8 with ipc::ByteBuf. r=emilio
We generate ByteBuf by rust bindgen, so we can drop StyleVecU8.
One potential follow-up is that we can merge this together with WrVecU8.

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

--HG--
rename : ipc/glue/ByteBuf.h => ipc/glue/ByteBufUtils.h
extra : moz-landing-system : lando
2020-01-22 20:18:40 +00:00
Boris Chiou
ffa1ebad7b Bug 1592822 - Use Serde for OffsetRotate and PositionOrAuto. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60088

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:38 +00:00
Boris Chiou
14387265a7 Bug 1592822 - Use Serde for SVGOffsetPath. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60087

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:35 +00:00
Boris Chiou
38cc52c091 Bug 1592822 - Use Serde for Transform. r=emilio
Though this may make us use more space when serializing
StyleTransform, but we don't have to do extra conversion on the compostior
side, and this makes us easier to maintain the Rust type.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 20:20:38 +00:00
Boris Chiou
7b90a66fcb Bug 1592822 - Use Serde for rotate, scale, and translate properties. r=emilio
The only drawback is: we resolve LengthPercentage value before passing
translate property through IPC, so its percentage part is redundant.
However, this makes us easier to maintain the Rust type.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:31 +00:00
Boris Chiou
f3dc7fa3c7 Bug 1592822 - Use macro for the implementation of ParamTraits<> on types which support Serde. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60610

--HG--
extra : moz-landing-system : lando
2020-01-22 20:18:24 +00:00
Glenn Watson
e449f34a4a Bug 1610738 - Add primitive flag to specify a compositor surface is preferred r=sotaro
This allows calling code to specify whether a primitive would prefer
to be promoted to a compositor surface and/or picture cache slice.

This is a performance hint that can be used for large external
primitives, such as videos and canvas elements.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 08:31:19 +00:00
Bogdan Tara
958c34b738 Backed out 6 changesets (bug 1592822) for bustages complaining about layout/painting/nsDisplayList.cpp CLOSED TREE
Backed out changeset 90d0f2ebd310 (bug 1592822)
Backed out changeset 9890bad86a0e (bug 1592822)
Backed out changeset 43870cc90433 (bug 1592822)
Backed out changeset d80e0e3f5b87 (bug 1592822)
Backed out changeset 99be49183325 (bug 1592822)
Backed out changeset 9ce641556acc (bug 1592822)

--HG--
extra : histedit_source : fa4e4b2c899510f1d39ee3baa0374e2ce16d2815
2020-01-22 21:17:39 +02:00
Boris Chiou
4f3076794c Bug 1592822 - Replace StyleVecU8 with ipc::ByteBuf. r=emilio
We generate ByteBuf by rust bindgen, so we can drop StyleVecU8.
One potential follow-up is that we can merge this together with WrVecU8.

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

--HG--
rename : ipc/glue/ByteBuf.h => ipc/glue/ByteBufUtils.h
extra : moz-landing-system : lando
2020-01-22 18:42:54 +00:00
Boris Chiou
e10013895e Bug 1592822 - Use Serde for OffsetRotate and PositionOrAuto. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60088

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:19 +00:00
Boris Chiou
40f3cb3d65 Bug 1592822 - Use Serde for SVGOffsetPath. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60087

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:11 +00:00
Boris Chiou
9735c2e972 Bug 1592822 - Use Serde for Transform. r=emilio
Though this may make us use more space when serializing
StyleTransform, but we don't have to do extra conversion on the compostior
side, and this makes us easier to maintain the Rust type.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:09 +00:00
Boris Chiou
73f0ae66a9 Bug 1592822 - Use Serde for rotate, scale, and translate properties. r=emilio
The only drawback is: we resolve LengthPercentage value before passing
translate property through IPC, so its percentage part is redundant.
However, this makes us easier to maintain the Rust type.

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

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:07 +00:00
Boris Chiou
c3faeb70ea Bug 1592822 - Use macro for the implementation of ParamTraits<> on types which support Serde. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D60610

--HG--
extra : moz-landing-system : lando
2020-01-22 18:40:05 +00:00