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

Issue 2016213002: Introduce base classes for blame contexts (Closed)

Created:
4 years, 7 months ago by Xiaocheng
Modified:
4 years, 6 months ago
Reviewers:
benjhayden, Sami
CC:
catapult-reviews_chromium.org, tracing-review_chromium.org
Base URL:
https://github.com/catapult-project/catapult.git@master
Target Ref:
refs/heads/master
Project:
catapult
Visibility:
Public.

Description

Introduce base classes for blame contexts This patch introduces the following class hierarchy as the trace view side correspondence of subclasses of Chrome's BlameContext: (from tr.model.ObjectSnapshot/Instance) - BlameContextSnapshot/Instance - FrameTreeNodeSnapshot/Instance - RenderFrameSnapshot/Instance - TopLevelSnapshot/Instance This patch is also a preparation for Frame Data Side Panel: https://codereview.chromium.org/1996303002 BUG=chromium:546021 TEST=tracing.extras.chrome.blame_context.blame_context_test tracing.extras.chrome.blame_context.frame_blame_context_test Committed: https://chromium.googlesource.com/external/github.com/catapult-project/catapult/+/71d985b3c851904130cba48b3a38304a10ad77d3

Patch Set 1 #

Patch Set 2 : Add blame_context_test.html #

Patch Set 3 : Add frame_blame_context_test.html; And some other revision #

Total comments: 23

Patch Set 4 : Remove |attributedEvents|; Switch to tr.c.TestUtils #

Total comments: 3

Patch Set 5 : Remove FrameBlameContextBase; Switch back to manual model setup in test; Some other revisions #

Total comments: 21

Patch Set 6 : Add TestUtils.newSnapshot and use TestUtils.newModel; Return undefined explicitly #

Patch Set 7 : Rename crossProcessCounterpart; Remove isTracedByRenderer; Remove empty overridings #

Patch Set 8 : Remove isTracedByRenderer from blame_context_test.html #

Unified diffs Side-by-side diffs Delta from patch set Stats (+316 lines, -159 lines) Patch
M tracing/trace_viewer.gypi View 1 2 3 4 2 chunks +4 lines, -2 lines 0 comments Download
M tracing/tracing/core/test_utils.html View 1 2 3 4 5 2 chunks +12 lines, -0 lines 0 comments Download
A tracing/tracing/extras/chrome/blame_context/blame_context.html View 1 2 3 4 5 6 1 chunk +74 lines, -0 lines 0 comments Download
A tracing/tracing/extras/chrome/blame_context/blame_context_test.html View 1 2 3 4 5 6 7 1 chunk +64 lines, -0 lines 0 comments Download
A tracing/tracing/extras/chrome/blame_context/frame_blame_context_test.html View 1 2 3 4 5 6 1 chunk +44 lines, -0 lines 0 comments Download
A + tracing/tracing/extras/chrome/blame_context/frame_tree_node.html View 1 2 3 4 5 6 2 chunks +24 lines, -13 lines 0 comments Download
A + tracing/tracing/extras/chrome/blame_context/render_frame.html View 1 2 3 4 5 6 1 chunk +31 lines, -18 lines 0 comments Download
A tracing/tracing/extras/chrome/blame_context/top_level.html View 1 2 3 4 5 6 1 chunk +59 lines, -0 lines 0 comments Download
D tracing/tracing/extras/chrome/frame_tree_node.html View 1 chunk +0 lines, -58 lines 0 comments Download
D tracing/tracing/extras/chrome/render_frame.html View 1 chunk +0 lines, -66 lines 0 comments Download
M tracing/tracing/extras/chrome_config.html View 1 2 3 4 1 chunk +4 lines, -2 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 33 (12 generated)
Xiaocheng
PTAL.
4 years, 7 months ago (2016-05-27 07:28:06 UTC) #3
Sami
Ben, does this look like a good data structure to work with? I think the ...
4 years, 6 months ago (2016-05-27 14:03:10 UTC) #6
Xiaocheng
Thanks for the review. PTAL at patch 4. I have moved the logic about |attributedEvents| ...
4 years, 6 months ago (2016-05-30 07:55:55 UTC) #7
Sami
Thanks, removing the up-front processing cost seems fine for now. https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html#newcode25 ...
4 years, 6 months ago (2016-05-31 16:59:37 UTC) #8
benjhayden
I think that these classes would be clearer without FrameBlameContextBase. More inline. https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html ...
4 years, 6 months ago (2016-05-31 17:37:12 UTC) #9
Sami
https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html#newcode36 tracing/tracing/extras/chrome/blame_context/blame_context.html:36: this.attributedEvents = new tr.model.EventSet(); On 2016/05/31 17:37:12, benjhayden_chromium wrote: ...
4 years, 6 months ago (2016-05-31 18:15:10 UTC) #10
benjhayden
https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/frame_tree_node.html File tracing/tracing/extras/chrome/blame_context/frame_tree_node.html (right): https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/frame_tree_node.html#newcode31 tracing/tracing/extras/chrome/blame_context/frame_tree_node.html:31: return this.args.RenderFrame; On 2016/05/31 at 18:15:10, Sami wrote: > ...
4 years, 6 months ago (2016-05-31 19:49:59 UTC) #11
Xiaocheng
https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): https://codereview.chromium.org/2016213002/diff/40001/tracing/tracing/extras/chrome/blame_context/blame_context.html#newcode25 tracing/tracing/extras/chrome/blame_context/blame_context.html:25: * directly. Subclasses of base::trace_event::BlameContext should define their On ...
4 years, 6 months ago (2016-06-01 01:22:12 UTC) #12
Xiaocheng
PTAL at Patch 5. The argument FrameTreeNode.args.RenderFrame has been renamed to FrameTreeNode.args.renderFrame. The Chrome side ...
4 years, 6 months ago (2016-06-01 05:43:45 UTC) #13
Sami
lgtm with one question/suggestion. Please let Ben have a look too. https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/frame_tree_node.html File tracing/tracing/extras/chrome/blame_context/frame_tree_node.html (right): ...
4 years, 6 months ago (2016-06-01 16:02:11 UTC) #15
benjhayden
https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/frame_tree_node.html File tracing/tracing/extras/chrome/blame_context/frame_tree_node.html (right): https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/frame_tree_node.html#newcode29 tracing/tracing/extras/chrome/blame_context/frame_tree_node.html:29: get crossProcessCounterpart() { On 2016/06/01 at 16:02:11, Sami wrote: ...
4 years, 6 months ago (2016-06-01 20:23:22 UTC) #16
benjhayden
This is looking almost done! Exciting! Just a few more questions. https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): ...
4 years, 6 months ago (2016-06-01 20:48:24 UTC) #17
Xiaocheng
PTAL at Patch 6, which: - Adds TestUtils.newSnapshot as a wrapper of ObjectCollection.addSnapshot - Uses ...
4 years, 6 months ago (2016-06-02 06:54:55 UTC) #18
benjhayden
https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/blame_context.html#newcode40 tracing/tracing/extras/chrome/blame_context/blame_context.html:40: preInitialize: function() { On 2016/06/02 at 06:54:55, Xiaocheng wrote: ...
4 years, 6 months ago (2016-06-02 20:07:01 UTC) #19
Xiaocheng
Revised accordingly in Patch 7. PTAL. https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/blame_context.html File tracing/tracing/extras/chrome/blame_context/blame_context.html (right): https://codereview.chromium.org/2016213002/diff/80001/tracing/tracing/extras/chrome/blame_context/blame_context.html#newcode40 tracing/tracing/extras/chrome/blame_context/blame_context.html:40: preInitialize: function() { ...
4 years, 6 months ago (2016-06-03 05:38:38 UTC) #20
Xiaocheng
Sorry, PTAL at patch 8 instead.
4 years, 6 months ago (2016-06-03 05:48:39 UTC) #21
benjhayden
lgtm Thanks!
4 years, 6 months ago (2016-06-03 16:38:35 UTC) #23
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2016213002/140001
4 years, 6 months ago (2016-06-03 20:26:38 UTC) #26
commit-bot: I haz the power
Try jobs failed on following builders: Catapult Presubmit on master.tryserver.client.catapult (JOB_FAILED, https://build.chromium.org/p/tryserver.client.catapult/builders/Catapult%20Presubmit/builds/2874)
4 years, 6 months ago (2016-06-03 20:45:09 UTC) #28
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/2016213002/140001
4 years, 6 months ago (2016-06-03 20:57:17 UTC) #31
commit-bot: I haz the power
4 years, 6 months ago (2016-06-03 20:58:37 UTC) #33
Message was sent while issue was closed.
Committed patchset #8 (id:140001) as
https://chromium.googlesource.com/external/github.com/catapult-project/catapu...

Powered by Google App Engine
This is Rietveld 408576698