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

Issue 2852803002: Remove base::SharedMemory::ShareToProcess. (Closed)

Created:
3 years, 7 months ago by erikchen
Modified:
3 years, 7 months ago
Reviewers:
Nico, brettw
CC:
chromium-reviews, mlamouri+watch-content_chromium.org, extensions-reviews_chromium.org, creis+watch_chromium.org, vmpstr+watch_chromium.org, posciak+watch_chromium.org, nasko+codewatch_chromium.org, jam, gavinp+memory_chromium.org, piman+watch_chromium.org, feature-media-reviews_chromium.org, darin-cc_chromium.org, asvitkine+watch_chromium.org, mac-reviews_chromium.org, chromium-apps-reviews_chromium.org, danakj+watch_chromium.org, xjz+watch_chromium.org, miu+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Remove base::SharedMemory::ShareToProcess. This CL is a refactor and has no intended behavior change. The method was initially introduced to assist in IPC, before Chrome's IPC subsystem was capable of transporting handles across processes. Now that the IPC subsystem does have the capability, the functionality is no longer needed in base::SharedMemory. BUG=716206 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 TBR=brettw@chromium.org Review-Url: https://codereview.chromium.org/2852803002 Cr-Commit-Position: refs/heads/master@{#468888} Committed: https://chromium.googlesource.com/chromium/src/+/37e7d8301a078bd1b6b3ef7cffdb6c6ac3277edd

Patch Set 1 #

Patch Set 2 : compile error. #

Patch Set 3 : Rebase. #

Patch Set 4 : Compile errors. #

Patch Set 5 : Compile error. #

Patch Set 6 : Rebase. #

Total comments: 9

Patch Set 7 : Comments from thakis & rebas. #

Patch Set 8 : Compile error. #

Patch Set 9 : Rebase. #

Total comments: 18

Patch Set 10 : Comments from thakis. #

Patch Set 11 : compile error. #

Patch Set 12 : Compile error. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+116 lines, -219 lines) Patch
M base/memory/discardable_shared_memory.h View 1 chunk +0 lines, -10 lines 0 comments Download
M base/memory/discardable_shared_memory_unittest.cc View 7 chunks +14 lines, -28 lines 0 comments Download
M base/memory/shared_memory.h View 1 2 3 4 5 6 2 chunks +0 lines, -18 lines 0 comments Download
M base/memory/shared_memory_handle.h View 1 2 3 4 5 6 1 chunk +3 lines, -1 line 0 comments Download
M base/memory/shared_memory_mac.cc View 1 2 3 4 5 1 chunk +0 lines, -12 lines 0 comments Download
M base/memory/shared_memory_mac_unittest.cc View 1 2 3 3 chunks +5 lines, -6 lines 0 comments Download
M base/memory/shared_memory_nacl.cc View 1 chunk +0 lines, -6 lines 0 comments Download
M base/memory/shared_memory_posix.cc View 1 chunk +0 lines, -6 lines 0 comments Download
M base/memory/shared_memory_unittest.cc View 1 2 3 2 chunks +4 lines, -4 lines 0 comments Download
M base/memory/shared_memory_win.cc View 1 2 1 chunk +0 lines, -20 lines 0 comments Download
M base/metrics/persistent_memory_allocator_unittest.cc View 1 chunk +4 lines, -4 lines 0 comments Download
M chrome/renderer/pepper/pepper_shared_memory_message_filter.cc View 1 2 3 4 5 6 7 8 9 1 chunk +3 lines, -2 lines 0 comments Download
M components/display_compositor/host_shared_bitmap_manager_unittest.cc View 3 chunks +3 lines, -6 lines 0 comments Download
M components/nacl/browser/nacl_process_host.cc View 2 chunks +7 lines, -7 lines 0 comments Download
M content/browser/android/synchronous_compositor_host.cc View 1 2 3 4 1 chunk +2 lines, -5 lines 0 comments Download
M content/browser/browser_child_process_host_impl.cc View 1 chunk +2 lines, -3 lines 0 comments Download
M content/browser/renderer_host/media/audio_input_renderer_host.cc View 1 chunk +3 lines, -3 lines 0 comments Download
M content/browser/renderer_host/media/audio_renderer_host.cc View 1 chunk +3 lines, -2 lines 0 comments Download
M content/browser/renderer_host/pepper/pepper_gamepad_host.h View 1 2 3 4 5 6 7 1 chunk +0 lines, -2 lines 0 comments Download
M content/browser/renderer_host/pepper/pepper_gamepad_host.cc View 1 2 3 4 5 6 7 3 chunks +1 line, -4 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 1 chunk +2 lines, -2 lines 0 comments Download
M content/child/resource_dispatcher_unittest.cc View 1 chunk +3 lines, -3 lines 0 comments Download
M content/common/sandbox_mac_fontloading_unittest.mm View 1 chunk +3 lines, -3 lines 0 comments Download
M content/renderer/media/audio_message_filter_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +6 lines, -0 lines 0 comments Download
M content/renderer/media/speech_recognition_audio_sink_unittest.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M content/renderer/pepper/pepper_platform_audio_output.cc View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -2 lines 0 comments Download
M content/renderer/pepper/pepper_platform_audio_output_dev.cc View 1 2 3 4 5 6 7 8 9 1 chunk +1 line, -2 lines 0 comments Download
M device/gamepad/gamepad_provider.h View 1 2 3 4 5 6 1 chunk +2 lines, -4 lines 0 comments Download
M device/gamepad/gamepad_provider.cc View 1 2 3 4 5 6 1 chunk +2 lines, -6 lines 0 comments Download
M device/gamepad/gamepad_provider_unittest.cc View 1 2 3 4 5 6 4 chunks +4 lines, -8 lines 0 comments Download
M device/gamepad/gamepad_service.h View 1 2 3 4 5 6 1 chunk +2 lines, -4 lines 0 comments Download
M device/gamepad/gamepad_service.cc View 1 2 3 4 5 6 1 chunk +2 lines, -3 lines 0 comments Download
M extensions/browser/user_script_loader.cc View 1 chunk +4 lines, -3 lines 0 comments Download
M gpu/ipc/service/gpu_channel_test_common.cc View 1 chunk +1 line, -3 lines 0 comments Download
M media/audio/audio_input_device_unittest.cc View 1 2 3 4 5 6 7 8 9 2 chunks +4 lines, -3 lines 0 comments Download
M media/audio/audio_output_device_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +5 lines, -3 lines 0 comments Download
M media/gpu/video_decode_accelerator_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +5 lines, -4 lines 0 comments Download
M media/gpu/video_encode_accelerator_unittest.cc View 1 2 3 4 5 6 7 8 9 2 chunks +6 lines, -4 lines 0 comments Download
M ppapi/proxy/video_decoder_resource_unittest.cc View 1 2 3 4 5 6 7 8 9 1 chunk +2 lines, -4 lines 0 comments Download
M ppapi/proxy/video_encoder_resource_unittest.cc View 2 chunks +5 lines, -7 lines 0 comments Download

Depends on Patchset:

Dependent Patchsets:

Messages

Total messages: 64 (45 generated)
erikchen
thakis: Please review.
3 years, 7 months ago (2017-04-28 22:08:11 UTC) #6
Nico
I got confused in file 2 :-( https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc File base/memory/discardable_shared_memory_unittest.cc (right): https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc#newcode47 base/memory/discardable_shared_memory_unittest.cc:47: SharedMemoryHandle shared_handle ...
3 years, 7 months ago (2017-05-02 16:02:14 UTC) #25
Nico
I another thing to be confused about, but it's kind of the same thing as ...
3 years, 7 months ago (2017-05-02 16:06:12 UTC) #26
erikchen
thakis: PTAL https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc File base/memory/discardable_shared_memory_unittest.cc (right): https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc#newcode47 base/memory/discardable_shared_memory_unittest.cc:47: SharedMemoryHandle shared_handle = memory1.handle().Duplicate(); On 2017/05/02 16:02:14, ...
3 years, 7 months ago (2017-05-02 19:00:52 UTC) #29
Nico
https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc File base/memory/discardable_shared_memory_unittest.cc (right): https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc#newcode47 base/memory/discardable_shared_memory_unittest.cc:47: SharedMemoryHandle shared_handle = memory1.handle().Duplicate(); On 2017/05/02 19:00:51, erikchen wrote: ...
3 years, 7 months ago (2017-05-02 19:36:25 UTC) #32
erikchen
https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc File base/memory/discardable_shared_memory_unittest.cc (right): https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc#newcode47 base/memory/discardable_shared_memory_unittest.cc:47: SharedMemoryHandle shared_handle = memory1.handle().Duplicate(); On 2017/05/02 19:36:25, Nico wrote: ...
3 years, 7 months ago (2017-05-02 19:44:04 UTC) #33
Nico
Thanks, looking through the CL now. https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc File base/memory/discardable_shared_memory_unittest.cc (right): https://codereview.chromium.org/2852803002/diff/100001/base/memory/discardable_shared_memory_unittest.cc#newcode47 base/memory/discardable_shared_memory_unittest.cc:47: SharedMemoryHandle shared_handle = ...
3 years, 7 months ago (2017-05-02 19:54:17 UTC) #34
erikchen
> Ah, thanks for explaining. I feel there probably should be a at least a ...
3 years, 7 months ago (2017-05-02 19:56:38 UTC) #37
Nico
Thanks again for explaining, this now made much more sense. I tried to check if ...
3 years, 7 months ago (2017-05-02 20:08:01 UTC) #38
erikchen
On 2017/05/02 20:08:01, Nico wrote: > Thanks again for explaining, this now made much more ...
3 years, 7 months ago (2017-05-02 21:31:52 UTC) #43
erikchen
https://codereview.chromium.org/2852803002/diff/160001/chrome/renderer/pepper/pepper_shared_memory_message_filter.cc File chrome/renderer/pepper/pepper_shared_memory_message_filter.cc (right): https://codereview.chromium.org/2852803002/diff/160001/chrome/renderer/pepper/pepper_shared_memory_message_filter.cc#newcode56 chrome/renderer/pepper/pepper_shared_memory_message_filter.cc:56: ->TrackSharedMemoryHandle(instance, host_shm_handle, size); On 2017/05/02 20:08:00, Nico wrote: > ...
3 years, 7 months ago (2017-05-02 21:33:11 UTC) #44
erikchen
thakis: PTAL I'm pretty sure there are several leaks of SharedMemoryHandle. I don't think there's ...
3 years, 7 months ago (2017-05-02 21:34:18 UTC) #45
Nico
Lgtm
3 years, 7 months ago (2017-05-02 21:45:38 UTC) #46
erikchen
TBRing brettw for a top-level stamp.
3 years, 7 months ago (2017-05-03 01:19:32 UTC) #51
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/2852803002/200001
3 years, 7 months ago (2017-05-03 01:20:25 UTC) #54
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_tsan_rel_ng on master.tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_tsan_rel_ng/builds/65729)
3 years, 7 months ago (2017-05-03 01:43:18 UTC) #56
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/2852803002/220001
3 years, 7 months ago (2017-05-03 02:08:24 UTC) #59
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/2852803002/220001
3 years, 7 months ago (2017-05-03 02:08:43 UTC) #61
commit-bot: I haz the power
3 years, 7 months ago (2017-05-03 04:06:35 UTC) #64
Message was sent while issue was closed.
Committed patchset #12 (id:220001) as
https://chromium.googlesource.com/chromium/src/+/37e7d8301a078bd1b6b3ef7cffdb...

Powered by Google App Engine
This is Rietveld 408576698