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

30 Коммитов

Автор SHA1 Сообщение Дата
Ryan Hunt 084c9b6f4c Allocate TextureReadLock at TextureClient creation and drop file handles immediately after. (bug 1416726, r=aosmond)
This changes the lifecycle and API for TextureReadLock to fix file descriptor exhaustion
crashes. These changes are partially superficial and mostly align the API of TextureReadLocks
with their actual usage.

The changes are:

1. Create the TextureReadLock in the TextureClient constructor so it's available before IPC creation
    a. This is superficial as EnableReadLock was always called before IPC creation
2. Send the ReadLockDescriptor in the PTextureConstructor message and close the file handle
3. Receive the ReadLockDescriptor in TextureHost and close the file handle
4. Send a boolean flag in layer transactions if the texture is read locked instead of a descriptor
5. Use a boolean flag in TextureHost to determine if the ReadLock must be unlocked instead of a nullptr

I believe that we can remove the InitReadLocks code from LayerTransaction as that was added to
prevent file descriptor limits in IPDL messages and is no longer needed with this change. But
that is a non-essential change and this patch is already big enough.

MozReview-Commit-ID: DzHujrOQejH

--HG--
extra : rebase_source : 3bdd7c9bc8edfdc386faad8a9e59ad7dc18ed91d
2018-03-12 08:10:13 -05:00
peter chang f0d71f5a55 Bug 1418791 - Explicit free the resource of PersistentBufferProviderBasic, r=sotaro
MozReview-Commit-ID: JJXYkF5PR5K

--HG--
extra : rebase_source : 86217890ee8a6e5d26b1b26cc063d42c6793c903
2017-11-23 16:31:55 +08:00
sotaro 222b1d574f Bug 1411472 - Add support of PersistentBufferProviderShared r=nical 2017-11-16 14:47:26 +09: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
Nicolas Silva 36605f9e7b Bug 1300121 - Make PersistentBufferProviderShared::BorrowDrawTarget more robust agaist bad edge cases and if all fails, fallback to the basic provider. r=Bas 2016-10-11 13:23:11 +02:00
Andi-Bogdan Postelnicu f93ddb39f5 Bug 1317637 - Converts for(...; ...; ...) loops to use the new range-based loops in C++11 in gfx/. r=jrmuizel
MozReview-Commit-ID: Dd6426wCbMg

--HG--
extra : rebase_source : 9e849faba30642b273bc5a0e0a74355ba160173e
2016-11-15 10:55:49 +02:00
Sylvestre Ledru d6ef1e706d Bug 1317430 - Avoid a unnecessary copy by passing a const & in gfx/ r=nical
MozReview-Commit-ID: 4AHG1queVe6

--HG--
extra : rebase_source : cd678e951710321c798b5ca617f39b18f82bea77
2016-11-14 23:16:18 +01:00
Matt Woodrow a0aad01631 Bug 1305897 - Move ActiveResourceTracker onto ShadowLayerForwarder, since it's not used anywhere else. r=nical 2016-10-03 21:20:13 +13:00
Matt Woodrow 55f506db9f Bug 1281456 - Decouple TextureForwarder and CompositableForwarder. r=gw280 2016-09-27 16:22:20 +13:00
Sebastian Hengst 548f7778a1 Backed out changeset e0d755ab4cbd (bug 1302380) for timeouts reftest with e10s invariable-declaration-XX.html on Linux 32 bit. r=backout 2016-09-16 18:55:44 +02:00
Nicolas Silva f4d4ceeeed Bug 1302380 - Report canvas memory usage through the buffer provider. r=gw280 2016-09-16 10:13:19 +02:00
Nicolas Silva 569564c271 Bug 1291163 - Make sure TextureHosts are read-unlock'ed if Compositor::EndFrame is not called. r=sotaro 2016-08-09 18:19:01 +02:00
Nicolas Silva 36eabd3917 Bug 1291296 - Make it possible to change a PersistentBufferProvider's Forwarder without crashing. r=ethlin 2016-08-09 14:42:15 +02:00
Nicolas Silva a4ee782267 Bug 1289380 - Simplify PersistentBufferProviderShared. r=edwin 2016-07-27 16:50:20 +02:00
Nicolas Silva 144561ee0b Bug 1284721 - Flush CanvasRenderingContext2D's DrawTarget when returning it to the BufferProvider. r=lsalzman 2016-07-11 17:44:27 +02:00
Wes Kocher 743746da45 Backed out changeset b966ababca8d (bug 1284721) for bustage CLOSED TREE
***
Backed out 3 changesets (bug 1284721, bug 1285207) for bustage CLOSED TREE

Backed out changeset 75f6c7e15d76 (bug 1284721)
Backed out changeset b7f2d54f3904 (bug 1285207)
Backed out changeset fceb3f145f91 (bug 1284721)

--HG--
extra : amend_source : b849891c44fd8704c0f601cf58ebeac13c88e2e6
extra : histedit_source : 54c8ef4b974c761a774260ec11e28d29013e0378%2C4d2cb79fbedcdabb4ea4fc52dcd26618bef2225e
2016-07-08 12:17:06 -07:00
Nicolas Silva 5a6fb6e9ec Bug 1284721 - Partially backout some changes that got incidentally folded into the wrong patch. r=me 2016-07-08 19:35:36 +02:00
Nicolas Silva b51ed22a3f Bug 1284721 - Flush CanvasRenderingContext2D's DrawTarget before handing it off to the BufferProvider. r=lsalzman 2016-07-08 19:26:48 +02:00
Nicolas Silva 6837c5c2f2 Bug 1167235 - Part 4 - Forward the shutdown notification to CanvasRenderingContext2D. r=Bas 2016-07-01 10:58:18 +02:00
Nicolas Silva d7bdab458f Bug 1167235 - Part 3 - Use TextureReadLock to optimize canvas copy-on-writes. r=Bas 2016-07-01 10:58:16 +02:00
Nicolas Silva 55982c743c Bug 1167235 - Part 1 - Render canvas2D into TextureClient directly. r=Bas 2016-07-01 10:58:06 +02:00
Sebastian Hengst 51e7f34222 Backed out changeset 14dfa550c783 (bug 1167235) 2016-06-28 20:28:23 +02:00
Sebastian Hengst 3dfd5773f2 Backed out changeset 6ee8762044bd (bug 1167235) 2016-06-28 20:28:23 +02:00
Sebastian Hengst 7f0473d085 Backed out changeset f534fcb785c9 (bug 1167235) 2016-06-28 20:28:22 +02:00
Nicolas Silva f8343772b9 Bug 1167235 - Part 4 - Forward the shutdown notification to CanvasRenderingContext2D. r=Bas 2016-06-28 14:07:00 +02:00
Nicolas Silva 607b38fffa Bug 1167235 - Part 3 - Use TextureReadLock to optimize canvas copy-on-writes. r=Bas 2016-06-28 14:06:57 +02:00
Nicolas Silva 9367516d33 Bug 1167235 - Part 1 - Render canvas2D into TextureClient directly. r=Bas 2016-06-28 14:06:51 +02:00
Vincent Liu 62a02d2e47 Bug 1198574 - Remove unnecessary argument for PersistentBufferProvider. r=bas 2015-08-26 18:58:18 +08:00
Birunthan Mohanathas a8939590de Bug 1182996 - Fix and add missing namespace comments. rs=ehsan
The bulk of this commit was generated by running:

  run-clang-tidy.py \
    -checks='-*,llvm-namespace-comment' \
    -header-filter=^/.../mozilla-central/.* \
    -fix
2015-07-13 08:25:42 -07:00
Bas Schouten 03d7b7630c Bug 1167235 - Part 1: Add code exposing a PersistentBufferProvider. r=nical 2015-06-19 01:07:21 +02:00