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

Issue 2881563002: memory-infra: Fix deadlock in MemoryDumpManager (Closed)

Created:
3 years, 7 months ago by hjd
Modified:
3 years, 7 months ago
CC:
chromium-reviews, tracing+reviews_chromium.org, wfh+watch_chromium.org, danakj+watch_chromium.org, vmpstr+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

memory-infra: Fix deadlock in MemoryDumpManager When we destroy a memory dump manager (MDM is a singleton so this only happens in tests) we attempt to stop the thread under the lock. This can lead to a deadlock if there are outstanding tasks which also try to take the lock. Instead we should get a pointer to the thread under the lock, stop the thread, then finally reset the pointer which is what this CL does. BUG=721072 Review-Url: https://codereview.chromium.org/2881563002 Cr-Commit-Position: refs/heads/master@{#470989} Committed: https://chromium.googlesource.com/chromium/src/+/f1610b19b843e8cdc00a215074f9c9e04de9dd17

Patch Set 1 #

Total comments: 2

Patch Set 2 : remove brackets #

Unified diffs Side-by-side diffs Delta from patch set Stats (+11 lines, -4 lines) Patch
M base/trace_event/memory_dump_manager.cc View 1 1 chunk +11 lines, -4 lines 0 comments Download

Messages

Total messages: 16 (9 generated)
hjd
ptal, thanks! :)
3 years, 7 months ago (2017-05-11 13:49:24 UTC) #3
Primiano Tucci (use gerrit)
LGTM with 1 comment https://codereview.chromium.org/2881563002/diff/1/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2881563002/diff/1/base/trace_event/memory_dump_manager.cc#newcode186 base/trace_event/memory_dump_manager.cc:186: { no need for these ...
3 years, 7 months ago (2017-05-11 13:53:27 UTC) #5
hjd
https://codereview.chromium.org/2881563002/diff/1/base/trace_event/memory_dump_manager.cc File base/trace_event/memory_dump_manager.cc (right): https://codereview.chromium.org/2881563002/diff/1/base/trace_event/memory_dump_manager.cc#newcode186 base/trace_event/memory_dump_manager.cc:186: { On 2017/05/11 13:53:27, Primiano Tucci wrote: > no ...
3 years, 7 months ago (2017-05-11 14:18:41 UTC) #6
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/2881563002/20001
3 years, 7 months ago (2017-05-11 15:16:31 UTC) #9
commit-bot: I haz the power
Try jobs failed on following builders: android_n5x_swarming_rel on master.tryserver.chromium.android (JOB_FAILED, https://build.chromium.org/p/tryserver.chromium.android/builders/android_n5x_swarming_rel/builds/175998)
3 years, 7 months ago (2017-05-11 16:27:47 UTC) #11
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/2881563002/20001
3 years, 7 months ago (2017-05-11 16:34:02 UTC) #13
commit-bot: I haz the power
3 years, 7 months ago (2017-05-11 17:16:34 UTC) #16
Message was sent while issue was closed.
Committed patchset #2 (id:20001) as
https://chromium.googlesource.com/chromium/src/+/f1610b19b843e8cdc00a215074f9...

Powered by Google App Engine
This is Rietveld 408576698