See: https://docs.google.com/document/d/15sPmv541FCSHdcZt_DvQS6hJYP7SzmVaQkM4k4SZr7M/edit This will allow us to serialize images and webfonts for oop raster.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/42a9c3857924702424c195cf80a5e22f707d2c57 commit 42a9c3857924702424c195cf80a5e22f707d2c57 Author: Eric Karl <ericrk@chromium.org> Date: Tue Oct 31 23:48:19 2017 Refactor discardable manager for transfer cache In preperation for adding the OOP Transfer Cache, I'm splitting ClientDiscardableManager into two classes: - ClientDiscardableManager - manages DiscardableHandles only - ClientDiscardableTextureManager - manages GL textures and uses a ClientDiscardableManager. This will allow the ClientTransferCache to also use a ClientDiscardableManager to manage its own DiscardableHandles. Eventually I plan to merge the transfer cache and discardable texture systems, but while the TransferCache and OOP raster is in flux, I'd like to keep them seperate. Bug: 777622 Cq-Include-Trybots: master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: Iebfbdc31d9676d98abf7f422204d65c503df2d33 Reviewed-on: https://chromium-review.googlesource.com/745539 Commit-Queue: Eric Karl <ericrk@chromium.org> Reviewed-by: Antoine Labour <piman@chromium.org> Cr-Commit-Position: refs/heads/master@{#513008} [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/BUILD.gn [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/client_discardable_manager.cc [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/client_discardable_manager.h [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/client_discardable_manager_unittest.cc [add] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/client_discardable_texture_manager.cc [add] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/client_discardable_texture_manager.h [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/gles2_implementation.cc [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/gles2_implementation_unittest.cc [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/client/share_group.h [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/common/discardable_handle.cc [modify] https://crrev.com/42a9c3857924702424c195cf80a5e22f707d2c57/gpu/command_buffer/common/discardable_handle.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5 commit 7f52f5fed4832f5dd2c5ead454d850cc1b821cc5 Author: Eric Karl <ericrk@chromium.org> Date: Wed Nov 01 20:25:50 2017 Add DeseriaizeOptions to PaintOpBuffer With the addition of the TransferCache, we need a way to pass support objects in to the Deserialize function. This adds an empty DeserializeOptions struct to Deserialize. The transfer cache will be added to this struct in a future CL. Bug: 777622 Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: Ibf75721d0dd45987335204c9a0a4d91713f2ae99 Reviewed-on: https://chromium-review.googlesource.com/749442 Reviewed-by: Antoine Labour <piman@chromium.org> Reviewed-by: enne <enne@chromium.org> Reviewed-by: Khushal <khushalsagar@chromium.org> Commit-Queue: Eric Karl <ericrk@chromium.org> Cr-Commit-Position: refs/heads/master@{#513245} [modify] https://crrev.com/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5/cc/paint/paint_op_buffer.cc [modify] https://crrev.com/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5/cc/paint/paint_op_buffer.h [modify] https://crrev.com/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5/cc/paint/paint_op_buffer_fuzzer.cc [modify] https://crrev.com/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5/cc/paint/paint_op_buffer_unittest.cc [modify] https://crrev.com/7f52f5fed4832f5dd2c5ead454d850cc1b821cc5/gpu/command_buffer/service/gles2_cmd_decoder.cc
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/16711ec5150adad5d3ec4a8e9494098c8e859a72 commit 16711ec5150adad5d3ec4a8e9494098c8e859a72 Author: Eric Karl <ericrk@chromium.org> Date: Sat Nov 18 00:58:11 2017 Transfer Cache Implementation This change adds the OOP Raster transfer cache. Subsequent changes will hook these objects up to the OOP Raster serialize/deserialize mechanisms. The transfer cache includes four main classes/interfaces: --ClientTransferCacheEntry-- Represents an object that can be added to the transfer cache. Includes methods for serializing the object for transport to the GPU process. --ClientTransferCache-- Provides methods for inserting, locking, unlocking, and deleting ClientTransferCacheEntry objects. Handles sending these objects to the ServiceTransferCache. --ServiceTransferCacheEntry-- Represents an object that can be stored in the GPU process' ServiceTransferCache. Includes methods for deserializing the serialized data produced by the ClientTransferCacheEntry. --ServiceTransferCache-- Includes methods for receiving new objects from the ClientTransferCache, looking up existing objects, and enforcing memory limits. This system is built around the existing DiscardableHandle system used in GPU discardable textures. Bug: 777622 Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: I5bf2ed467147d6dbcd5690a3997280806c4d7763 Reviewed-on: https://chromium-review.googlesource.com/747273 Commit-Queue: Eric Karl <ericrk@chromium.org> Reviewed-by: Antoine Labour <piman@chromium.org> Reviewed-by: enne <enne@chromium.org> Cr-Commit-Position: refs/heads/master@{#517646} [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/BUILD.gn [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/DEPS [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/BUILD.gn [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/raw_memory_transfer_cache_entry.cc [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/raw_memory_transfer_cache_entry.h [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/transfer_cache_entry.cc [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/transfer_cache_entry.h [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/cc/paint/transfer_cache_unittest.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/BUILD.gn [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/GLES2/gl2chromium_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/build_gles2_cmd_buffer.py [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/BUILD.gn [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/client_transfer_cache.cc [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/client_transfer_cache.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_c_lib_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_cmd_helper_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_implementation.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_implementation_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_implementation_impl_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_interface.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_interface_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_interface_stub_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_trace_implementation_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/cmd_buffer_functions.txt [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/BUILD.gn [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/discardable_handle.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/discardable_handle.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/gles2_cmd_format_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/gles2_cmd_ids_autogen.h [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/common/transfer_cache_entry_id.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/BUILD.gn [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/context_group.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/context_group.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototypes.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doers.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_handlers.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_handlers_autogen.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/gles2_cmd_decoder_unittest_4_autogen.h [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/service_transfer_cache.cc [add] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/command_buffer/service/service_transfer_cache.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/ipc/gl_in_process_context.cc [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/ipc/gl_in_process_context.h [modify] https://crrev.com/16711ec5150adad5d3ec4a8e9494098c8e859a72/gpu/ipc/in_process_command_buffer.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4eb20dc93c611b6966e21642c0f8b5958c4f7184 commit 4eb20dc93c611b6966e21642c0f8b5958c4f7184 Author: Eric Karl <ericrk@chromium.org> Date: Fri Dec 08 22:04:46 2017 Make transfer cache command buffer commands INTERNAL Currrently, TransferCache uses a set of glTransferCache* commands which are designed to be called *only* by the transfer cache itself. This is a bit error prone, as they are externally exposed, so I've made these commands INTERNAL and re-worked the transfer cache so it can only be directly accessed from the GLES2Implementation. For components (image decode cache) who need to access the transfer cache externally, functions have been added to ContextSupport. These functions also make it clearer which functions are externally thread safe. Bug: 777622 Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: I5a847743304126835ea04e030ada6b499ad4023c Reviewed-on: https://chromium-review.googlesource.com/812508 Commit-Queue: Eric Karl <ericrk@chromium.org> Reviewed-by: Antoine Labour <piman@chromium.org> Cr-Commit-Position: refs/heads/master@{#522896} [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/cc/paint/transfer_cache_unittest.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/cc/test/test_context_support.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/cc/test/test_context_support.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/GLES2/gl2chromium_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/build_gles2_cmd_buffer.py [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/BUILD.gn [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/client_transfer_cache.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/client_transfer_cache.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/context_support.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_c_lib_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_cmd_helper_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_implementation.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_implementation.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_implementation_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_implementation_impl_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_interface_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_interface_stub_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_interface_stub_impl_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_trace_implementation_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/gles2_trace_implementation_impl_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/client/share_group.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/cmd_buffer_functions.txt [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/common/gles2_cmd_format_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/common/gles2_cmd_format_test_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/common/gles2_cmd_ids_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_autogen.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doer_prototypes.h [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_doers.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_handlers.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_passthrough_handlers_autogen.cc [modify] https://crrev.com/4eb20dc93c611b6966e21642c0f8b5958c4f7184/gpu/command_buffer/service/gles2_cmd_decoder_unittest_4_autogen.h
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/8ac366fa089e0959da91e9c774fe34b5610885d9 commit 8ac366fa089e0959da91e9c774fe34b5610885d9 Author: Eric Karl <ericrk@chromium.org> Date: Sat Dec 09 02:34:18 2017 Add TransferCacheDeserializeHelper and cleanup. This is in preperation for font/image usage of the transfer cache. Allows access to the transfer cache through cc/paint deserialize functions. Bug: 777622 Cq-Include-Trybots: master.tryserver.blink:linux_trusty_blink_rel;master.tryserver.chromium.android:android_optional_gpu_tests_rel;master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Change-Id: Ifd0d9e4b19e91d9979decc751f3be90f38516321 Reviewed-on: https://chromium-review.googlesource.com/811989 Commit-Queue: Eric Karl <ericrk@chromium.org> Reviewed-by: Antoine Labour <piman@chromium.org> Reviewed-by: vmpstr <vmpstr@chromium.org> Cr-Commit-Position: refs/heads/master@{#522966} [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/image_transfer_cache_entry.cc [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/image_transfer_cache_entry.h [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/paint_op_buffer.h [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/raw_memory_transfer_cache_entry.cc [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/raw_memory_transfer_cache_entry.h [add] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/transfer_cache_deserialize_helper.h [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/cc/paint/transfer_cache_entry.h [modify] https://crrev.com/8ac366fa089e0959da91e9c774fe34b5610885d9/gpu/command_buffer/service/gles2_cmd_decoder.cc
This is in a good state now, remaining work is feature dependent and tracked by blocked bugs.
Comment 1 by enne@chromium.org
, Oct 23 2017