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

Issue 2535213002: [WIP] Add SharedMemoryTracker to dump base::SharedMemory usage

Created:
4 years ago by hajimehoshi
Modified:
3 years, 6 months ago
CC:
chromium-reviews, jam, darin-cc_chromium.org, gavinp+memory_chromium.org, piman+watch_chromium.org, vmpstr+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[WIP] Add SharedMemoryTracker to dump base::SharedMemory usage This CL adds SharedMemoryTracker to dump base::SharedMemory usage. Remaining tasks: * Confirm there is no regression in terms of performance * Add tests BUG=604726 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

Patch Set 1 #

Patch Set 2 : Remove unneeded calls #

Total comments: 1

Patch Set 3 : Implement for other platforms #

Patch Set 4 : Bug fix: Windows #

Patch Set 5 : Bug fix: compile errors #

Patch Set 6 : impl #

Patch Set 7 : s/SharedMemoryDumpProvider/SharedMemoryTracker/g #

Patch Set 8 : Fix compile errors #

Patch Set 9 : Review #

Patch Set 10 : Bug fix #

Patch Set 11 : Implement buckets #

Total comments: 11

Patch Set 12 : Address on primiano's review #

Total comments: 4

Patch Set 13 : (rebase) #

Patch Set 14 : (rebase) #

Patch Set 15 : (rebase:wip) #

Patch Set 16 : (wip) #

Total comments: 1

Patch Set 17 : (wip) #

Patch Set 18 : Add ownership edges #

Patch Set 19 : Remove unneeded dump #

Patch Set 20 : (wip: changed this for POSIX only fix) #

Patch Set 21 : Bug fix: dump creation on single process mode #

Patch Set 22 : (rebase) #

Patch Set 23 : Bug fix: shared_bitmap might be null #

Patch Set 24 : (rebase) #

Patch Set 25 : (rebase: WIP) #

Patch Set 26 : (wip) #

Patch Set 27 : (wip: Add SharedMemory::set_importance) #

Patch Set 28 : (wip) #

Patch Set 29 : (wip) #

Patch Set 30 : (rebase) #

Patch Set 31 : rebase and reduce TODOs #

Patch Set 32 : Move GetGUIDForTracing to handlers #

Patch Set 33 : (rebase) #

Patch Set 34 : impl #

Patch Set 35 : (rebase) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+324 lines, -227 lines) Patch
M base/BUILD.gn View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 2 chunks +2 lines, -7 lines 0 comments Download
M base/memory/discardable_shared_memory.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 1 chunk +2 lines, -0 lines 0 comments Download
M base/memory/shared_memory.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 3 chunks +4 lines, -15 lines 0 comments Download
M base/memory/shared_memory_handle.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 2 chunks +5 lines, -0 lines 0 comments Download
M base/memory/shared_memory_handle.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 1 chunk +12 lines, -0 lines 0 comments Download
M base/memory/shared_memory_mac.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 3 chunks +3 lines, -1 line 0 comments Download
M base/memory/shared_memory_nacl.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 1 chunk +1 line, -0 lines 0 comments Download
M base/memory/shared_memory_posix.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 1 chunk +0 lines, -19 lines 0 comments Download
M base/memory/shared_memory_tracker.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 3 chunks +12 lines, -11 lines 0 comments Download
M base/memory/shared_memory_tracker.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 2 chunks +26 lines, -36 lines 0 comments Download
M cc/raster/staging_buffer_pool.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 3 chunks +20 lines, -13 lines 0 comments Download
M cc/resources/resource_provider.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 3 chunks +48 lines, -26 lines 0 comments Download
M cc/resources/shared_bitmap.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 2 chunks +8 lines, -0 lines 0 comments Download
M cc/resources/shared_bitmap.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 1 chunk +4 lines, -0 lines 0 comments Download
M components/discardable_memory/common/discardable_shared_memory_heap.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 2 chunks +3 lines, -27 lines 0 comments Download
M components/discardable_memory/service/discardable_shared_memory_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 1 chunk +4 lines, -0 lines 0 comments Download
M components/viz/display_compositor/host_shared_bitmap_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 3 chunks +15 lines, -5 lines 0 comments Download
M content/browser/gpu/browser_gpu_memory_buffer_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 2 chunks +6 lines, -5 lines 0 comments Download
M gpu/command_buffer/client/cmd_buffer_helper.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 3 chunks +14 lines, -8 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 3 chunks +15 lines, -9 lines 0 comments Download
M gpu/command_buffer/client/gles2_implementation_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 2 chunks +5 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/mapped_memory.h View 1 2 3 4 5 6 7 8 9 10 11 12 1 chunk +2 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/mapped_memory.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 3 chunks +14 lines, -8 lines 0 comments Download
M gpu/command_buffer/client/transfer_buffer.h View 1 2 3 4 5 2 chunks +3 lines, -0 lines 0 comments Download
M gpu/command_buffer/client/transfer_buffer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 1 chunk +8 lines, -0 lines 0 comments Download
M gpu/command_buffer/common/buffer.h View 1 2 3 4 5 2 chunks +2 lines, -3 lines 0 comments Download
M gpu/command_buffer/common/buffer.cc View 1 2 3 4 5 2 chunks +4 lines, -4 lines 0 comments Download
M gpu/command_buffer/service/buffer_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 2 chunks +14 lines, -4 lines 0 comments Download
M gpu/command_buffer/service/transfer_buffer_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 5 chunks +9 lines, -8 lines 0 comments Download
M gpu/ipc/client/gpu_memory_buffer_impl_shared_memory.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 1 chunk +1 line, -0 lines 0 comments Download
M gpu/ipc/client/gpu_memory_buffer_impl_shared_memory.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 4 chunks +13 lines, -7 lines 0 comments Download
M gpu/ipc/service/gpu_command_buffer_stub.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 2 chunks +4 lines, -1 line 0 comments Download
M media/video/gpu_memory_buffer_video_frame_pool.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 3 chunks +15 lines, -6 lines 0 comments Download
M services/ui/public/cpp/bitmap/child_shared_bitmap_manager.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 2 chunks +6 lines, -0 lines 0 comments Download
M ui/gfx/gpu_memory_buffer.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 1 chunk +2 lines, -0 lines 0 comments Download
M ui/gfx/gpu_memory_buffer.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 1 chunk +4 lines, -0 lines 0 comments Download
M ui/gl/gl_image_shared_memory.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 2 chunks +14 lines, -4 lines 0 comments Download

Messages

Total messages: 188 (160 generated)
hajimehoshi
4 years ago (2016-11-29 11:56:15 UTC) #5
haraken
How did you measure the performance impact of this CL? reveman@: Would you take a ...
4 years ago (2016-11-30 04:39:27 UTC) #11
hajimehoshi
On 2016/11/30 04:39:27, haraken wrote: > How did you measure the performance impact of this ...
4 years ago (2016-11-30 07:15:04 UTC) #14
reveman
On 2016/11/30 at 04:39:27, haraken wrote: > How did you measure the performance impact of ...
4 years ago (2016-11-30 20:39:55 UTC) #20
hajimehoshi
On 2016/11/30 07:15:04, hajimehoshi wrote: > On 2016/11/30 04:39:27, haraken wrote: > > How did ...
4 years ago (2016-12-01 06:19:30 UTC) #21
Primiano Tucci (use gerrit)
Left some comments on crbug.com/604726 TL;DR 1) I think you want to count only anonymous ...
4 years ago (2016-12-02 10:56:20 UTC) #26
hajimehoshi
primiano@: This is not finished yet (I need to implement GetIDFromSharedMemoryHandle on other platforms than ...
3 years, 12 months ago (2016-12-20 09:37:51 UTC) #31
hajimehoshi
ping
3 years, 12 months ago (2016-12-21 12:15:54 UTC) #32
Primiano Tucci (use gerrit)
On 2016/12/21 12:15:54, hajimehoshi wrote: > ping Do you have a trace to see how ...
3 years, 12 months ago (2016-12-21 13:32:37 UTC) #33
Primiano Tucci (use gerrit)
Had a first high-level pass, here's some initial comments. I think overall is shooting in ...
3 years, 12 months ago (2016-12-21 15:06:41 UTC) #34
hajimehoshi
On 2016/12/21 13:32:37, Primiano Tucci (back but slow) wrote: > On 2016/12/21 12:15:54, hajimehoshi wrote: ...
3 years, 11 months ago (2017-01-10 11:34:55 UTC) #39
hajimehoshi
I'm now fixing the CL as you suggested to improve performance. Thank you! On 2016/12/21 ...
3 years, 11 months ago (2017-01-12 05:20:09 UTC) #54
hajimehoshi
Thank you for reviewing! > 1) I think SharedMemoryDumpProvider is both a bit of a ...
3 years, 11 months ago (2017-01-12 08:31:44 UTC) #57
hajimehoshi
> I've not measured the performance but I’ll try. Which metrics or telemetry tests > ...
3 years, 11 months ago (2017-01-19 11:12:05 UTC) #88
Primiano Tucci (use gerrit)
Ops sorry lost track of this On 2017/01/19 11:12:05, hajimehoshi ooo til Jan 9 wrote: ...
3 years, 11 months ago (2017-01-19 12:47:04 UTC) #89
hajimehoshi
On 2017/01/19 12:47:04, Primiano Tucci wrote: > Ops sorry lost track of this > > ...
3 years, 11 months ago (2017-01-20 07:44:06 UTC) #90
hajimehoshi
On 2017/01/20 07:44:06, hajimehoshi ooo til Jan 9 wrote: > On 2017/01/19 12:47:04, Primiano Tucci ...
3 years, 11 months ago (2017-01-20 09:23:39 UTC) #91
Primiano Tucci (use gerrit)
Thanks your reply makes sense. Also thanks for all the hard work doing all the ...
3 years, 11 months ago (2017-01-20 16:34:52 UTC) #93
hajimehoshi
On 2017/01/20 16:34:52, Primiano Tucci wrote: > Thanks your reply makes sense. Also thanks for ...
3 years, 11 months ago (2017-01-23 11:58:38 UTC) #94
hajimehoshi
https://codereview.chromium.org/2535213002/diff/310001/base/memory/shared_memory_handle.h File base/memory/shared_memory_handle.h (right): https://codereview.chromium.org/2535213002/diff/310001/base/memory/shared_memory_handle.h#newcode207 base/memory/shared_memory_handle.h:207: bool GetIDFromSharedMemoryHandle(const SharedMemoryHandle& handle, On 2017/01/20 16:34:52, Primiano Tucci ...
3 years, 11 months ago (2017-01-23 11:59:09 UTC) #95
Primiano Tucci (use gerrit)
SG. I think makes sense to start splitting this CL to make reviewable from the ...
3 years, 11 months ago (2017-01-24 01:26:41 UTC) #100
ssid
Primiano, please double check if I am making sense here. I think we need a ...
3 years, 11 months ago (2017-01-24 04:39:50 UTC) #101
hajimehoshi
On 2017/01/24 04:39:50, ssid wrote: > Primiano, please double check if I am making sense ...
3 years, 10 months ago (2017-01-24 10:49:14 UTC) #102
ssid
Had a discussion with primiano@ about this issue. I was wrong about 2 dumps owning ...
3 years, 10 months ago (2017-01-24 23:36:37 UTC) #103
hajimehoshi
As https://codereview.chromium.org/2654073002/ has been landed, I fixed this CL to add ownerships correctly. The current ...
3 years, 8 months ago (2017-03-27 10:05:01 UTC) #116
hajimehoshi
ping
3 years, 8 months ago (2017-03-29 11:50:35 UTC) #117
Primiano Tucci (use gerrit)
On 2017/03/29 11:50:35, hajimehoshi wrote: > ping Is this cl to review? The title says ...
3 years, 8 months ago (2017-03-29 23:59:19 UTC) #118
hajimehoshi
3 years, 8 months ago (2017-03-30 05:02:54 UTC) #119
On 2017/03/29 23:59:19, Primiano Tucci wrote:
> On 2017/03/29 11:50:35, hajimehoshi wrote:
> > ping
> 
> Is this cl to review? The title says wip and some pieces seem to have landed
> separately?

I reflected ssid@'s comment and I wanted to check if the general direction is
OK, there are still some works to do yet though.

As you said, same things are in the other small CL
(https://codereview.chromium.org/2775423003/), so let's continue there. Thanks.

Powered by Google App Engine
This is Rietveld 408576698