[heap] Make GCTracer::ResetForTesting thread safe.
Bug: Change-Id: I49a259b8911969aace193cc3d0b18e4b8bcac7b8 Reviewed-on: https://chromium-review.googlesource.com/818344 Reviewed-by: Michael Lippautz <mlippautz@chromium.org> Commit-Queue: Ulan Degenbaev <ulan@chromium.org> Cr-Commit-Position: refs/heads/master@{#49988}
This commit is contained in:
parent
a837ef8a9a
commit
95ca3e8bf7
@ -172,6 +172,7 @@ void GCTracer::ResetForTesting() {
|
||||
recorded_context_disposal_times_.Reset();
|
||||
recorded_survival_ratios_.Reset();
|
||||
start_counter_ = 0;
|
||||
base::LockGuard<base::Mutex> guard(&background_counter_mutex_);
|
||||
for (int i = 0; i < BackgroundScope::NUMBER_OF_SCOPES; i++) {
|
||||
background_counter_[i].total_duration_ms = 0;
|
||||
background_counter_[i].runtime_call_counter.Reset();
|
||||
|
Loading…
Reference in New Issue
Block a user