mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 15:25:52 +00:00
Bug 1463758: Don't use sequentially consistent atomic operations in RacyFeatures. r=mstange
Relaxed is more than enough for this use. MozReview-Commit-ID: 6BGfEU83s7Y --HG-- extra : rebase_source : ede8f47a5213ae64ed3dbf08a99d2a4a3789c1a2
This commit is contained in:
parent
5ecb7246f5
commit
08d4ae50ba
@ -696,7 +696,7 @@ uint32_t ActivePS::sNextGeneration = 0;
|
||||
// The mutex that guards accesses to CorePS and ActivePS.
|
||||
static PSMutex gPSMutex;
|
||||
|
||||
Atomic<uint32_t> RacyFeatures::sActiveAndFeatures(0);
|
||||
Atomic<uint32_t, MemoryOrdering::Relaxed> RacyFeatures::sActiveAndFeatures(0);
|
||||
|
||||
// Each live thread has a RegisteredThread, and we store a reference to it in TLS.
|
||||
// This class encapsulates that TLS.
|
||||
|
@ -206,7 +206,7 @@ private:
|
||||
|
||||
// We combine the active bit with the feature bits so they can be read or
|
||||
// written in a single atomic operation.
|
||||
static mozilla::Atomic<uint32_t> sActiveAndFeatures;
|
||||
static mozilla::Atomic<uint32_t, mozilla::MemoryOrdering::Relaxed> sActiveAndFeatures;
|
||||
};
|
||||
|
||||
} // namespace detail
|
||||
|
Loading…
Reference in New Issue
Block a user