Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(101)

Issue 2229553004: cc: Implement UnionTraits for DrawQuads (Closed)

Created:
4 years, 4 months ago by Fady Samuel
Modified:
4 years, 4 months ago
Reviewers:
danakj, Tom Sepez, yzshen1
CC:
chromium-reviews, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, cc-bugs_chromium.org, ben+mojo_chromium.org, darin (slow to review)
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

cc: Implement UnionTraits for DrawQuads Previously DrawQuad inheritance was modeled in mojom as a composition of optional fields. This resulted in a lot of validation overhead. With the newly introduced UnionTraits, we can check the tag indicating the type to serialize and deserialize once, and only validate that type. This results in a significant performance win for CompositorFrame serialization. In many cases, serialization is 20-40% faster than ParamTraits, and deserialization is 5-10% faster. This CL also removes PICTURE_CONTENT and INVALID material types from the mojom as we cannot serialize those types of materials. BUG=624459 CQ_INCLUDE_TRYBOTS=master.tryserver.blink:linux_precise_blink_rel Committed: https://crrev.com/0abffe077031a99cf914b683b327312828764e75 Cr-Commit-Position: refs/heads/master@{#411169}

Patch Set 1 #

Patch Set 2 : Fixed comment #

Total comments: 2

Patch Set 3 : Cleanup according to Yuzhu's suggestion #

Total comments: 4

Patch Set 4 : More cleanup: Got rid of material and collapsed a method call #

Total comments: 7

Patch Set 5 : Addressed alphabetization #

Unified diffs Side-by-side diffs Delta from patch set Stats (+125 lines, -283 lines) Patch
M cc/ipc/quads.mojom View 1 2 3 4 4 chunks +16 lines, -28 lines 0 comments Download
M cc/ipc/quads_struct_traits.h View 1 2 10 chunks +90 lines, -128 lines 0 comments Download
M cc/ipc/quads_struct_traits.cc View 1 2 3 3 chunks +15 lines, -126 lines 0 comments Download
M cc/ipc/render_pass_struct_traits.cc View 1 2 1 chunk +4 lines, -1 line 0 comments Download

Messages

Total messages: 32 (14 generated)
Fady Samuel
How do feel about this Yuzhu? I'm considering moving methods out to the cc file ...
4 years, 4 months ago (2016-08-09 17:31:29 UTC) #6
yzshen1
https://codereview.chromium.org/2229553004/diff/20001/cc/ipc/quads.mojom File cc/ipc/quads.mojom (right): https://codereview.chromium.org/2229553004/diff/20001/cc/ipc/quads.mojom#newcode123 cc/ipc/quads.mojom:123: Material material; Could we remove this enum entirely?
4 years, 4 months ago (2016-08-09 17:42:04 UTC) #9
Fady Samuel
PTAL Yuzhu! I've also removed the Null methods since they are no longer used. https://codereview.chromium.org/2229553004/diff/20001/cc/ipc/quads.mojom ...
4 years, 4 months ago (2016-08-09 18:23:09 UTC) #10
yzshen1
LGTM with two nits Thanks! https://codereview.chromium.org/2229553004/diff/40001/cc/ipc/quads.mojom File cc/ipc/quads.mojom (right): https://codereview.chromium.org/2229553004/diff/40001/cc/ipc/quads.mojom#newcode100 cc/ipc/quads.mojom:100: enum Material { Could ...
4 years, 4 months ago (2016-08-09 18:29:54 UTC) #11
Fady Samuel
Done, Yuzhu, could you please run this locally? I want to confirm someone other than ...
4 years, 4 months ago (2016-08-09 18:42:50 UTC) #12
Fady Samuel
+danakj@ for cc :-) +tsepez@ for
4 years, 4 months ago (2016-08-09 18:53:35 UTC) #14
Fady Samuel
On 2016/08/09 18:53:35, Fady Samuel wrote: > +danakj@ for cc :-) > +tsepez@ for +tsepez@ ...
4 years, 4 months ago (2016-08-09 18:53:51 UTC) #15
Tom Sepez
traits lgtm.
4 years, 4 months ago (2016-08-09 19:00:00 UTC) #16
danakj
LG but can we use SetAll? https://codereview.chromium.org/2229553004/diff/60001/cc/ipc/quads.mojom File cc/ipc/quads.mojom (right): https://codereview.chromium.org/2229553004/diff/60001/cc/ipc/quads.mojom#newcode107 cc/ipc/quads.mojom:107: StreamVideoQuadState stream_video_quad_state; nit: ...
4 years, 4 months ago (2016-08-09 21:37:23 UTC) #17
Fady Samuel
PTAL Dana, Yuzhu. Dana, Yuzhu, the DataView API is set up such that I cannot ...
4 years, 4 months ago (2016-08-10 13:29:03 UTC) #18
yzshen1
https://codereview.chromium.org/2229553004/diff/60001/cc/ipc/quads_struct_traits.cc File cc/ipc/quads_struct_traits.cc (right): https://codereview.chromium.org/2229553004/diff/60001/cc/ipc/quads_struct_traits.cc#newcode57 cc/ipc/quads_struct_traits.cc:57: quad->color = data.color(); On 2016/08/10 13:29:03, Fady Samuel wrote: ...
4 years, 4 months ago (2016-08-10 15:53:07 UTC) #19
danakj
On Wed, Aug 10, 2016 at 6:29 AM, <fsamuel@chromium.org> wrote: > PTAL Dana, Yuzhu. > ...
4 years, 4 months ago (2016-08-10 16:54:43 UTC) #20
danakj
offline summary: param traits are also not using SetAll, what *is* using SetAll is tests, ...
4 years, 4 months ago (2016-08-10 18:25:15 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2229553004/80001
4 years, 4 months ago (2016-08-10 18:26:53 UTC) #24
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_ng/builds/275302)
4 years, 4 months ago (2016-08-10 20:01:00 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2229553004/80001
4 years, 4 months ago (2016-08-10 20:03:12 UTC) #28
commit-bot: I haz the power
Committed patchset #5 (id:80001)
4 years, 4 months ago (2016-08-10 22:44:03 UTC) #30
commit-bot: I haz the power
4 years, 4 months ago (2016-08-10 22:45:57 UTC) #32
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/0abffe077031a99cf914b683b327312828764e75
Cr-Commit-Position: refs/heads/master@{#411169}

Powered by Google App Engine
This is Rietveld 408576698