Граф коммитов

152 Коммитов

Автор SHA1 Сообщение Дата
Andrew Osmond 35eed7acf6 Bug 1711948 - Add surfaces from image containers to the memory report. r=tnikkel
An image container can keep a surface alive longer than it can remain in
the cache, if it is indeed kept in the cache. We should cross reference
our memory report generated from the SurfaceCache against any surfaces
stored in our ImageContainer objects to ensure they are all reported.

This is of particular importance for blob recordings which are not put
into SurfaceCache. While the recordings themselves have their own memory
reporting inside of WebRender, it would be good to know what recordings
we are keeping alive from the content side to help break it down.

Differential Revision: https://phabricator.services.mozilla.com/D115517
2021-05-20 12:31:27 +00:00
Andrew Osmond f262b1efaa Bug 1699224 - Part 1. Ensure we map/unmap surfaces used by DrawTargetSkia. r=jrmuizel
Since we want to be able to unmap shared surfaces which are not in use,
we need to be able to map the data in as required. Blob images can
access shared surfaces via recordings which are used by DrawTargetSkia.
This patch makes it call Map/Unmap for data surfaces that require a data
pointer in Skia.

Differential Revision: https://phabricator.services.mozilla.com/D109437
2021-03-29 22:43:26 +00:00
Bob Owen e35330bd95 Bug 1641256: Don't deactivate remote canvas due to read error when the writer has already failed. r=jrmuizel
This also removes the gfxDevCrashes when an invalid enum is read, because we
suspect these are mainly due to the writer shutting down mid event.
We could only crash when the writer hasn't failed, but because these reads are
in templated code it would mean updating the different event streams with a new
function. If we are still getting high numbers in the deactivation telemetry we
will need to do this to try and track down the problem.

Differential Revision: https://phabricator.services.mozilla.com/D82493
2020-07-07 19:30:14 +00:00
Andrew Osmond 91b071ed14 Bug 1618345 - Enforce proper color management by splitting gfx::Color into sRGBColor and DeviceColor types. r=jrmuizel
gfx::Color is currently misused in many places. The DrawTargets expect
the color space to be in device space, e.g. what we are actually going
to draw using. Everything sitting above generally deals with sRGB, as
specified in CSS. Sometimes we missed the conversion from sRGB to device
space when issuing draw calls, and similarly sometimes we converted the
color to device space twice.

This patch splits the type in two. sRGBColor and DeviceColor now
represent sRGB and device color spaces respectively. DrawTarget only
accepts DeviceColor, and one can get a DeviceColor from an sRGBColor via
the ToDeviceColor helper API. The reftests now pass with color
management enabled for everything (e.g. CSS) instead of just tagged
raster images.

There will be a follow up patch to enable color management everywhere by
default on all supported platforms.

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

--HG--
extra : moz-landing-system : lando
2020-03-09 14:16:17 +00:00
Simon Giesecke dce1e48caf Bug 1613985 - Use default for equivalent-to-default constructors/destructors in gfx. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D65288

--HG--
extra : moz-landing-system : lando
2020-03-04 15:39:20 +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
Andrew Osmond 73ee861def Bug 1604535 - Avoid copying image surfaces when used with OMTP. r=tnikkel
When one uses SourceSurfaceRawData to wrap a data pointer, it will
perform a copy of said data if GuaranteePersistence is called. This is
done for DrawTargetCapture, which is used with OMTP. Prior to this
patch, image surfaces would be wrapped by a SourceSurfaceRawData when
using the basic compositor on any non-Linux platform (since Linux does
not support volatile memory). This means every time imgFrame::Draw is
called with OMTP, a copy of the image will be made. Images don't need
this property since the data is already going to persist, so this patch
adds a new class SourceSurfaceMappedData, which takes a ScopedMap
keeping the underlying surface open and readable.

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

--HG--
extra : moz-landing-system : lando
2019-12-25 21:27:46 +00:00
Bob Owen 2b04f744b3 Bug 1570358: Check validity of enums before playing back Moz2D RecordedEvents. r=jrmuizel
Differential Revision: https://phabricator.services.mozilla.com/D40419

--HG--
extra : moz-landing-system : lando
2019-08-05 13:08:30 +00:00
Nicholas Nethercote 18fae65f38 Bug 1563139 - Remove StaticPrefs.h. r=glandium
This requires replacing inclusions of it with inclusions of more specific prefs
files.

The exception is that StaticPrefsAll.h, which is equivalent to StaticPrefs.h,
and is used in `Codegen.py` because doing something smarter is tricky and
suitable for a follow-up. As a result, any change to StaticPrefList.yaml will
still trigger recompilation of all the generated DOM bindings files, but that's
still a big improvement over trigger recompilation of every file that uses
static prefs.

Most of the changes in this commit are very boring. The only changes that are
not boring are modules/libpref/*, Codegen.py, and ServoBindings.toml.

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

--HG--
extra : moz-landing-system : lando
2019-07-26 01:10:23 +00:00
Nicholas Nethercote e54f4ead1e Bug 1560820 - Remove `sGfxLogLevel`. r=nical
`sGfxLogLevel` is a global variable whose value mirrors the value of the
"gfx.logging.level" pref in the prefs table, and is kept up to date by a
prefs callback.

But "gfx.logging.level" is a static pref that already has a mirror variable,
accessible via `StaticPrefs::gfx_logging_level()`.

So we can use the latter and remove the former, and this patch does that. The
patch also removes a sentence in a comment that refers to special treatment of
LOG_DEBUG and LOG_DEBUG_PRLOG, because that sentence appears to be referring to
something (another comment?) that is no longer present.

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

--HG--
extra : moz-landing-system : lando
2019-07-24 00:05:23 +00:00
Bob Owen 9b1c422ff4 Bug 1464032 Part 10: Add a CanvasTranslator and canvas recorded events. r=jrmuizel
These are extensions to the Moz2D RecordedEvents to record and play back canvas
texture related functions in the GPU process.
The CanvasTranslator handles the playback of these and the Moz2D ones.
2018-12-02 14:17:12 +00:00
Jean-Yves Avenard 9ac65feb3d Bug 1550422 - P17. Convert gfxPrefs::GfxLoggingLevel to StaticPrefs. r=jrmuizel
Fly-by fix, we make LoggingPrefs::sGfxLogLevel as it is written on the main thread but read on different threads.

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

--HG--
extra : moz-landing-system : lando
2019-05-26 14:30:29 +00:00
Gurzau Raul 967bc2a754 Backed out 31 changesets (bug 1552643, bug 1550422) for xpcshell crash on a CLOSED TREE.
Backed out changeset e30c1aa75529 (bug 1552643)
Backed out changeset caadcd7e02d3 (bug 1552643)
Backed out changeset aa7086ab09be (bug 1552643)
Backed out changeset 0b4029671710 (bug 1550422)
Backed out changeset a16295296035 (bug 1550422)
Backed out changeset 3b70307c0db5 (bug 1550422)
Backed out changeset 69df7818d4a3 (bug 1550422)
Backed out changeset d98dfc565927 (bug 1550422)
Backed out changeset 6f0997976944 (bug 1550422)
Backed out changeset 0edd264464c2 (bug 1550422)
Backed out changeset 9ea6da7a74ec (bug 1550422)
Backed out changeset f855f9309c8b (bug 1550422)
Backed out changeset 1033546224a7 (bug 1550422)
Backed out changeset ade7384c6186 (bug 1550422)
Backed out changeset 75b04de7e99c (bug 1550422)
Backed out changeset 91c3acdb2454 (bug 1550422)
Backed out changeset 77d2f80257d1 (bug 1550422)
Backed out changeset e0cd10d35327 (bug 1550422)
Backed out changeset 097091082423 (bug 1550422)
Backed out changeset 2f328853c1ab (bug 1550422)
Backed out changeset f92f2cc29cb1 (bug 1550422)
Backed out changeset 6dc82f88333d (bug 1550422)
Backed out changeset c20f66494d69 (bug 1550422)
Backed out changeset 2ba22cddeb6f (bug 1550422)
Backed out changeset 3aa72f89e295 (bug 1550422)
Backed out changeset ab4c4e806977 (bug 1550422)
Backed out changeset 72e5de040dda (bug 1550422)
Backed out changeset 7d3c2d486706 (bug 1550422)
Backed out changeset 132e0b8d8468 (bug 1550422)
Backed out changeset 54c85ac75dd0 (bug 1550422)
Backed out changeset d7ba4a18dd54 (bug 1550422)
2019-05-25 09:07:49 +03:00
Jean-Yves Avenard 14806f7e2e Bug 1550422 - P17. Convert gfxPrefs::GfxLoggingLevel to StaticPrefs. r=jrmuizel
Fly-by fix, we make LoggingPrefs::sGfxLogLevel as it is written on the main thread but read on different threads.

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

--HG--
extra : moz-landing-system : lando
2019-05-24 11:33:24 +00:00
Gurzau Raul 74c555539e Backed out 28 changesets (bug 1550422) for marionette AssertionError and failing browser_policy_hardware_acceleration.js on a CLOSED TREE.
Backed out changeset 5dd10a365ba9 (bug 1550422)
Backed out changeset 529f5be01ab9 (bug 1550422)
Backed out changeset b6861d3badf8 (bug 1550422)
Backed out changeset 059cff1a3dde (bug 1550422)
Backed out changeset 6ada1116b241 (bug 1550422)
Backed out changeset ca67e8e45262 (bug 1550422)
Backed out changeset a1961a51ae44 (bug 1550422)
Backed out changeset 1c90b9cb3ad4 (bug 1550422)
Backed out changeset 285fa46e4f26 (bug 1550422)
Backed out changeset e2938a444234 (bug 1550422)
Backed out changeset 7a930fc51125 (bug 1550422)
Backed out changeset 898ed02804fe (bug 1550422)
Backed out changeset e1b7abc99ae9 (bug 1550422)
Backed out changeset f781d415cef6 (bug 1550422)
Backed out changeset 2fef10a7cce5 (bug 1550422)
Backed out changeset ea64b4d8d4ff (bug 1550422)
Backed out changeset 86a8ba1b755c (bug 1550422)
Backed out changeset 9c0c9e80f309 (bug 1550422)
Backed out changeset 10c153ddbaea (bug 1550422)
Backed out changeset 60fe635ec2c9 (bug 1550422)
Backed out changeset a38796266b28 (bug 1550422)
Backed out changeset 2db647dcdf1c (bug 1550422)
Backed out changeset 952ddac02972 (bug 1550422)
Backed out changeset ba46b53643ec (bug 1550422)
Backed out changeset ca47ef6c59f7 (bug 1550422)
Backed out changeset f45f471a1a40 (bug 1550422)
Backed out changeset 371b4da5b771 (bug 1550422)
Backed out changeset 02fc78890032 (bug 1550422)
2019-05-23 05:59:44 +03:00
Jean-Yves Avenard 3992dfb602 Bug 1550422 - P17. Convert gfxPrefs::GfxLoggingLevel to StaticPrefs. r=jrmuizel
Fly-by fix, we make LoggingPrefs::sGfxLogLevel as it is written on the main thread but read on different threads.

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

--HG--
extra : moz-landing-system : lando
2019-05-22 12:44:52 +00:00
Jean-Yves Avenard 11ac9e9cf8 Bug 1540581 - P6. Tidy some C++ declarations in gfx/. r=gerald,jrmuizel
* Remove redundant virtual keywords
* Mark all destructors of inheriting classes as virtual for clarity
* Mark all classes without virtual destructor as final (exposed errors)
* Make destructor virtual where it needed to be (some were missing)
* Replace empty ({}) code declaration in header with = default
* Remove virtual unused methods

I probably missed some, it quickly became a rabbit hole.

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

--HG--
extra : moz-landing-system : lando
2019-04-11 12:36:51 +00:00
Jeff Gilbert 758e836333 No bug - clang-format -p gfx 2019-03-29 23:41:48 -07:00
Kartikaya Gupta 6743c7ace2 Bug 1536128 - Make apz.printtree work on non-debug builds. r=botond
This eliminates the need to additionally modify gfx.logging.level on
non-debug builds to make apz.printtree output show up.

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

--HG--
extra : moz-landing-system : lando
2019-03-18 18:42:04 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Lee Salzman 4d142c7a81 Bug 1455848 - fix logging of wchar strings on MinGW builds. r=me 2018-12-11 17:16:21 -05:00
Lee Salzman f7066e0fb7 Bug 1455848 - validate access to DWrite font files in WR and output helpful log messages on failure. r=jrmuizel 2018-12-11 15:58:02 -05:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
Ehsan Akhgari 2febd96e7e Bug 1508472 - Part 2: Second batch of comment fix-ups in preparation for the tree reformat r=sylvestre
This is a best effort attempt at ensuring that the adverse impact of
reformatting the entire tree over the comments would be minimal.  I've used a
combination of strategies including disabling of formatting, some manual
formatting and some changes to formatting to work around some clang-format
limitations.

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

--HG--
extra : moz-landing-system : lando
2018-11-28 00:54:56 +00:00
Cosmin Sabou 0afa5aa670 Backed out 2 changesets (bug 1508472) for causing build bustages on JobScheduler_posix.cpp. CLOSED TREE
Backed out changeset af951294cf96 (bug 1508472)
Backed out changeset 2320933cb7bc (bug 1508472)
2018-11-28 00:08:11 +02:00
Ehsan Akhgari 7c937c2747 Bug 1508472 - Part 2: Second batch of comment fix-ups in preparation for the tree reformat r=sylvestre
This is a best effort attempt at ensuring that the adverse impact of
reformatting the entire tree over the comments would be minimal.  I've used a
combination of strategies including disabling of formatting, some manual
formatting and some changes to formatting to work around some clang-format
limitations.

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

--HG--
extra : moz-landing-system : lando
2018-11-27 21:36:18 +00:00
Andreea Pavel 945463d394 Backed out changeset 11d6688b953f (bug 1508472) for build bustages on a CLOSED TREE 2018-11-27 18:28:30 +02:00
Ehsan Akhgari d0a3a76106 Bug 1508472 - Part 2: Second batch of comment fix-ups in preparation for the tree reformat r=sylvestre
This is a best effort attempt at ensuring that the adverse impact of
reformatting the entire tree over the comments would be minimal.  I've used a
combination of strategies including disabling of formatting, some manual
formatting and some changes to formatting to work around some clang-format
limitations.

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

--HG--
extra : moz-landing-system : lando
2018-11-27 15:18:32 +00:00
Lee Salzman de75729420 Bug 1480615 - reuse scaled fonts across blob image recordings. r=jrmuizel 2018-09-05 21:55:53 -04:00
Sebastian Hengst 0819f35e51 Backed out 4 changesets (bug 525063) on request from Andi. a=backout
Backed out changeset 516c4fb1e4b8 (bug 525063)
Backed out changeset 6ff8aaef2866 (bug 525063)
Backed out changeset bf13e4103150 (bug 525063)
Backed out changeset d7d2f08e051c (bug 525063)
2018-04-13 16:01:28 +03:00
Tristan Bourvon a3a77c0312 Bug 525063 - Initialize uninitialized class attributes in m-c. r=ehsan 2018-04-10 21:11:02 +02:00
Ryan Hunt 4a4b48772d Add basic DrawTargetCapture logging ability (bug 1435938, r=bas)
MozReview-Commit-ID: LhbC4mWub6k

--HG--
extra : histedit_source : 3dd4ae3ce007aa326c1d47f018770df1e9b982e1%2C4cf1db87b1cd9e879a90351f086711d24216d7b5
2018-02-05 22:00:45 -06:00
Daniel Holbert 126bd9e1a4 Bug 1412427 part 8: (automated patch) Switch a bunch of C++ files in gfx to use our standard mode lines. r=jrmuizel
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py

For every file that is modified in this patch, the changes are as follows:
 (1) The patch changes the file to use the exact C++ mode lines from the
     Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

 (2) The patch deletes any blank lines between the mode line & the MPL
     boilerplate comment.

 (3) If the file previously had the mode lines and MPL boilerplate in a
     single contiguous C++ comment, then the patch splits them into
     separate C++ comments, to match the boilerplate in the coding style.

MozReview-Commit-ID: 77D61xpSmIl

--HG--
extra : rebase_source : c6162fa3cf539a07177a19838324bf368faa162b
2017-10-27 16:10:06 -07:00
David Anderson 783e6ecfd6 Add diagnostics for the crash in bug 1387467. r=milan 2017-08-05 01:32:25 -07:00
Sebastian Hengst f257cde65c Backed out changeset c044d8842861 (bug 1387467) for build bustage at FrameBuilder.cpp:154 (no member GetName). r=backout on a CLOSED TREE 2017-08-05 11:54:09 +02:00
David Anderson 20c4bd2549 Add diagnostics for the crash in bug 1387467. r=milan 2017-08-05 01:32:25 -07:00
Botond Ballo 9e5ace4056 Bug 1369929 - Do not increase the indent twice in the TreeAutoIndent copy constructor. r=kats
MozReview-Commit-ID: BVudzxWZnQS

--HG--
extra : rebase_source : ff590dc7e5aa31f6d93baf91f8e8df2f27c95628
2017-06-05 12:42:28 -04:00
Lee Salzman 28471864af Bug 1355931 - move font serialization from ScaledFont to UnscaledFont. r=jrmuizel
MozReview-Commit-ID: 3d1XMoe2BKj
2017-04-14 14:11:00 -04:00
Eric Rahm 89708e6a2a Bug 1353143 - Part 5: Replace direct usage of PR_LogPrint. r=froydnj
This replaces the usage of |PR_LogPrint| with either |printf_stderr| or
|MOZ_LOG| where appropriate. |printf_stderr| is used where a logger is not
actually available or if log levels are not being used as expected.
2017-04-04 14:36:21 -07:00
Andrew Osmond 48eeda9e2c Bug 1331938 - Part 2. Add SourceSurfaceSharedData, a shared data backed DataSourceSurface. r=nical 2017-01-18 10:12:32 -05:00
Bob Owen ca714c62ab Bug 1321522: Add null check and logging on fontResource in RecordedScaledFontCreation::PlayEvent. r=milan
MozReview-Commit-ID: 3nM28xgGLPO
2016-12-15 10:55:10 +00:00
Milan Sreckovic 7bf73e0916 Bug 1313884: Part 2. Additional nullptr test and nightly/aurora crash if bad things happen. r=gw280 2016-11-15 12:56:16 -05:00
Phil Ringnalda be66b650bb Backed out changeset bb4879b87c17 (bug 1313884) because bad things happen @mozilla::dom::CanvasRenderingContext2D::DrawImage all the time
CLOSED TREE
2016-11-10 23:28:02 -08:00
Milan Sreckovic 09875b84c7 Bug 1313884 - Part 2: Additional nullptr test and nightly/aurora crash if bad things happen. r=gw280
--HG--
extra : rebase_source : 14ff98dde9eeccb1bbdeb0ccb9b6dcba75d5ebf2
2016-11-10 10:26:00 -05:00
Matt Woodrow 4d0b10822d Bug 1308363 - Remove GONK specific code from gfx/. r=jrmuizel,sotaro 2016-10-27 13:17:10 +13:00
Kevin Wern 16d7a2302e Bug 1227233: Increase scope of TreeTraversal.h to by-value traversal r=botond
MozReview-Commit-ID: LOw1k792T10

--HG--
extra : rebase_source : a81ac06686bc21ed69693a3a80551e0648a8299a
2016-09-22 12:31:26 -04:00
David Anderson 3cab7db05c Use gfxCriticalError in CompositorBridgeChild::ProcessingError. (bug 1302413, r=milan) 2016-09-15 23:55:24 -07:00
Kartikaya Gupta d83081b2a6 Bug 1301461 - Minor fix for gtest output prettiness. r=milan
MozReview-Commit-ID: BWs9AKDc5sE

--HG--
extra : rebase_source : 4313318b2934bb329fa24df50fb0b91c4de5dd0d
2016-09-08 13:41:43 -04:00
Nicolas Silva 39f5573d6f Bug 1291190 - Don't crash when push/pop clips are not balanced correctly. r=Bas 2016-08-24 11:06:45 +02:00
Milan Sreckovic 7b6a6a19d3 Bug 635464: Diagnostic crash in nightly and aurora, to see if we are asking basic content client for alpha. r=bas
MozReview-Commit-ID: 2DBdJZs0hlh

--HG--
extra : rebase_source : dabafda100d50b8308e4dc008254a7a4c6d80549
2016-07-20 10:26:02 -04:00