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

Unified Diff: base/debug/trace_event_synthetic_delay.cc

Issue 392933002: Fix data race with synthetic delay initialization (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Just the fix. Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/debug/trace_event_synthetic_delay.cc
diff --git a/base/debug/trace_event_synthetic_delay.cc b/base/debug/trace_event_synthetic_delay.cc
index ab1880941ba459be2a2c3be26750365cbba9148c..868a77737645d4693bd8313db3972ba45091bc55 100644
--- a/base/debug/trace_event_synthetic_delay.cc
+++ b/base/debug/trace_event_synthetic_delay.cc
@@ -220,11 +220,11 @@ base::debug::TraceEventSyntheticDelay* GetOrCreateDelay(
base::subtle::AtomicWord* impl_ptr) {
base::debug::TraceEventSyntheticDelay* delay_impl =
reinterpret_cast<base::debug::TraceEventSyntheticDelay*>(
- base::subtle::NoBarrier_Load(impl_ptr));
+ base::subtle::Acquire_Load(impl_ptr));
if (!delay_impl) {
delay_impl = base::debug::TraceEventSyntheticDelayRegistry::GetInstance()
->GetOrCreateDelay(name);
- base::subtle::NoBarrier_Store(
+ base::subtle::Release_Store(
impl_ptr, reinterpret_cast<base::subtle::AtomicWord>(delay_impl));
}
return delay_impl;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698