зеркало из https://github.com/mozilla/gecko-dev.git
Backed out changeset 12a59e5a50bf (bug 1207753) for causing build bustage CLOSED TREE
This commit is contained in:
Родитель
4b033a5256
Коммит
2390d257e6
|
@ -115,7 +115,7 @@ class HandlerProvider final : public IGeckoBackChannel,
|
|||
HRESULT* result);
|
||||
|
||||
Atomic<uint32_t> mRefCnt;
|
||||
Mutex mMutex MOZ_UNANNOTATED; // Protects mSerializer
|
||||
Mutex mMutex; // Protects mSerializer
|
||||
const IID mTargetUnkIid;
|
||||
mscom::InterceptorTargetPtr<IUnknown>
|
||||
mTargetUnk; // Constant, main thread only
|
||||
|
@ -136,7 +136,7 @@ class HandlerProvider final : public IGeckoBackChannel,
|
|||
// Used when the payload is built prior to marshaling the object by a bulk
|
||||
// fetch operation. See prebuildPayload().
|
||||
IA2PayloadPtr mPayload;
|
||||
Mutex mPayloadMutex MOZ_UNANNOTATED; // Protects mPayload
|
||||
Mutex mPayloadMutex; // Protects mPayload
|
||||
};
|
||||
|
||||
} // namespace a11y
|
||||
|
|
|
@ -40,7 +40,7 @@ class MarkersStorage : public LinkedListElement<MarkersStorage> {
|
|||
Mutex& GetLock();
|
||||
|
||||
private:
|
||||
Mutex mLock MOZ_UNANNOTATED;
|
||||
Mutex mLock;
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
@ -123,7 +123,7 @@ class TimelineConsumers : public nsIObserver {
|
|||
LinkedList<MarkersStorage> mMarkersStores;
|
||||
|
||||
// Protects this class's data structures.
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
@ -227,7 +227,7 @@ class BodyStream final : public nsIInputStreamCallback,
|
|||
// We need a mutex because JS engine can release BodyStream on a non-owning
|
||||
// thread. We must be sure that the releasing of resources doesn't trigger
|
||||
// race conditions.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// Protected by mutex.
|
||||
State mState;
|
||||
|
|
|
@ -1101,7 +1101,7 @@ class Manager::CachePutAllAction final : public DBAction {
|
|||
nsTArray<nsID> mDeletedBodyIdList;
|
||||
|
||||
// accessed from any thread while mMutex locked
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
nsTArray<nsCOMPtr<nsISupports>> mCopyContextList;
|
||||
|
||||
Maybe<CacheDirectoryMetadata> mDirectoryMetadata;
|
||||
|
|
|
@ -105,7 +105,7 @@ class ReadStream::Inner final : public ReadStream::Controllable {
|
|||
// to close a stream on our owning thread while an IO thread is simultaneously
|
||||
// reading the same stream. Therefore, protect all access to these stream
|
||||
// objects with a mutex.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
CondVar mCondVar;
|
||||
nsCOMPtr<nsIInputStream> mStream;
|
||||
nsCOMPtr<nsIInputStream> mSnappyStream;
|
||||
|
|
|
@ -32,7 +32,7 @@ namespace mozilla {
|
|||
|
||||
// -
|
||||
|
||||
static StaticMutex sContextSetLock MOZ_UNANNOTATED;
|
||||
static StaticMutex sContextSetLock;
|
||||
|
||||
static std::unordered_set<HostWebGLContext*>& DeferredStaticContextSet() {
|
||||
static std::unordered_set<HostWebGLContext*> sContextSet;
|
||||
|
|
|
@ -1475,7 +1475,7 @@ class CreateImageBitmapFromBlob final : public DiscardableRunnable,
|
|||
// This is called on the main-thread only.
|
||||
nsresult GetMimeTypeAsync();
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// The access to this object is protected by mutex but is always nullified on
|
||||
// the owning thread.
|
||||
|
|
|
@ -62,7 +62,7 @@ class OffscreenCanvasDisplayHelper final {
|
|||
gfx::SurfaceFormat aFormat, const gfx::IntSize& aSize,
|
||||
bool aNeedsPremult, gl::OriginPos aOriginPos) const;
|
||||
|
||||
mutable Mutex mMutex MOZ_UNANNOTATED;
|
||||
mutable Mutex mMutex;
|
||||
HTMLCanvasElement* MOZ_NON_OWNING_REF mCanvasElement;
|
||||
RefPtr<layers::ImageContainer> mImageContainer;
|
||||
RefPtr<gfx::SourceSurface> mFrontBufferSurface;
|
||||
|
|
|
@ -78,7 +78,7 @@ class ConsoleReportCollector final : public nsIConsoleReportCollector {
|
|||
const CopyableTArray<nsString> mStringParams;
|
||||
};
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// protected by mMutex
|
||||
nsTArray<PendingReport> mPendingReports;
|
||||
|
|
|
@ -131,7 +131,7 @@ class FileBlobImpl : public BlobImpl {
|
|||
|
||||
// FileBlobImpl has getter methods with lazy initialization. Because any
|
||||
// BlobImpl must work thread-safe, we use a mutex.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
nsCOMPtr<nsIFile> mFile;
|
||||
|
||||
|
|
|
@ -97,7 +97,7 @@ class MemoryBlobImpl final : public BaseBlobImpl {
|
|||
// sDataOwners and sMemoryReporterRegistered may only be accessed while
|
||||
// holding sDataOwnerMutex! You also must hold the mutex while touching
|
||||
// elements of the linked list that DataOwner inherits from.
|
||||
static mozilla::StaticMutex sDataOwnerMutex MOZ_UNANNOTATED;
|
||||
static mozilla::StaticMutex sDataOwnerMutex;
|
||||
static mozilla::StaticAutoPtr<mozilla::LinkedList<DataOwner> > sDataOwners;
|
||||
static bool sMemoryReporterRegistered;
|
||||
|
||||
|
|
|
@ -92,7 +92,7 @@ class MutableBlobStorage final {
|
|||
[[nodiscard]] nsresult DispatchToIOThread(
|
||||
already_AddRefed<nsIRunnable> aRunnable);
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// All these variables are touched on the main thread only or in the
|
||||
// retargeted thread when used by Append(). They are protected by mMutex.
|
||||
|
|
|
@ -115,7 +115,7 @@ class RemoteLazyInputStream final : public nsIAsyncInputStream,
|
|||
|
||||
// Any member of this class is protected by mutex because touched on
|
||||
// multiple threads.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
@ -78,7 +78,7 @@ class RemoteLazyInputStreamChild final : public PRemoteLazyInputStreamChild {
|
|||
nsTArray<RemoteLazyInputStream*> mStreams;
|
||||
|
||||
// This mutex protects mStreams because that can be touched in any thread.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
const nsID mID;
|
||||
const uint64_t mSize;
|
||||
|
|
|
@ -60,7 +60,7 @@ class BlobURLInputStream final : public nsIAsyncInputStream,
|
|||
|
||||
// Non-recursive mutex introduced in order to guard access to mState, mError
|
||||
// and mAsyncInputStream
|
||||
Mutex mStateMachineMutex MOZ_UNANNOTATED;
|
||||
Mutex mStateMachineMutex;
|
||||
State mState;
|
||||
// Stores the error code if stream is in error state
|
||||
nsresult mError;
|
||||
|
|
|
@ -87,7 +87,7 @@ struct DataInfo {
|
|||
|
||||
// The mutex is locked whenever gDataTable is changed, or if gDataTable
|
||||
// is accessed off-main-thread.
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
|
||||
// All changes to gDataTable must happen on the main thread, while locking
|
||||
// sMutex. Reading from gDataTable on the main thread may happen without
|
||||
|
|
|
@ -118,7 +118,7 @@ class GetFilesHelper : public Runnable, public GetFilesHelperBase {
|
|||
nsTArray<RefPtr<Promise>> mPromises;
|
||||
nsTArray<RefPtr<GetFilesCallback>> mCallbacks;
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// This variable is protected by mutex.
|
||||
bool mCanceled;
|
||||
|
|
|
@ -141,7 +141,7 @@ class GamepadPlatformService final {
|
|||
|
||||
// This mutex protects mChannelParents from race condition
|
||||
// between background and monitor thread
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
std::map<GamepadHandle, GamepadAdded> mGamepadAdded;
|
||||
};
|
||||
|
|
|
@ -1497,7 +1497,7 @@ class ConnectionPool final {
|
|||
};
|
||||
|
||||
// This mutex guards mDatabases, see below.
|
||||
Mutex mDatabasesMutex MOZ_UNANNOTATED;
|
||||
Mutex mDatabasesMutex;
|
||||
|
||||
nsTArray<IdleThreadInfo> mIdleThreads;
|
||||
nsTArray<IdleDatabaseInfo> mIdleDatabases;
|
||||
|
@ -6592,7 +6592,7 @@ nsresult DispatchAndReturnFileReferences(
|
|||
*aMemRefCnt = -1;
|
||||
*aDBRefCnt = -1;
|
||||
|
||||
mozilla::Monitor monitor MOZ_ANNOTATED(__func__);
|
||||
mozilla::Monitor monitor(__func__);
|
||||
bool waiting = true;
|
||||
|
||||
auto lambda = [&] {
|
||||
|
@ -6758,7 +6758,7 @@ class DeserializeIndexValueHelper final : public Runnable {
|
|||
lock.Notify();
|
||||
}
|
||||
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
|
||||
const int64_t mIndexID;
|
||||
const KeyPath& mKeyPath;
|
||||
|
@ -21682,7 +21682,7 @@ class FileHelper::ReadCallback final : public nsIInputStreamCallback {
|
|||
private:
|
||||
~ReadCallback() = default;
|
||||
|
||||
mozilla::Mutex mMutex MOZ_UNANNOTATED;
|
||||
mozilla::Mutex mMutex;
|
||||
mozilla::CondVar mCondVar;
|
||||
bool mInputAvailable;
|
||||
};
|
||||
|
|
|
@ -2842,7 +2842,7 @@ class DeserializeUpgradeValueHelper final : public Runnable {
|
|||
lock.Notify();
|
||||
}
|
||||
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
StructuredCloneReadInfoParent& mCloneReadInfo;
|
||||
nsresult mStatus;
|
||||
};
|
||||
|
|
|
@ -148,7 +148,7 @@ class HangMonitorChild : public PProcessHangMonitorChild,
|
|||
static Atomic<HangMonitorChild*, SequentiallyConsistent> sInstance;
|
||||
|
||||
const RefPtr<ProcessHangMonitor> mHangMonitor;
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
|
||||
// Main thread-only.
|
||||
bool mSentReport;
|
||||
|
@ -282,7 +282,7 @@ class HangMonitorParent : public PProcessHangMonitorParent,
|
|||
// This field is only accessed on the hang thread.
|
||||
bool mIPCOpen;
|
||||
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
|
||||
// Must be accessed with mMonitor held.
|
||||
RefPtr<HangMonitoredProcess> mProcess;
|
||||
|
@ -290,7 +290,7 @@ class HangMonitorParent : public PProcessHangMonitorParent,
|
|||
// Map from plugin ID to crash dump ID. Protected by
|
||||
// mBrowserCrashDumpHashLock.
|
||||
nsTHashMap<nsUint32HashKey, nsString> mBrowserCrashDumpIds;
|
||||
Mutex mBrowserCrashDumpHashLock MOZ_UNANNOTATED;
|
||||
Mutex mBrowserCrashDumpHashLock;
|
||||
mozilla::ipc::TaskFactory<HangMonitorParent> mMainThreadTaskFactory;
|
||||
};
|
||||
|
||||
|
|
|
@ -96,7 +96,7 @@ class RefMessageBody final {
|
|||
// In case the RefMessageBody is shared and refcounted (see mCount/mMaxCount),
|
||||
// we must enforce that the reading does not happen simultaneously on
|
||||
// different threads.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
UniquePtr<ipc::StructuredCloneData> mCloneData;
|
||||
|
||||
|
|
|
@ -1368,7 +1368,7 @@ class Connection final : public CachingDatabaseConnection {
|
|||
* origin, so we need to queue a runnable and wait our turn.)
|
||||
*/
|
||||
class Connection::InitTemporaryOriginHelper final : public Runnable {
|
||||
mozilla::Monitor mMonitor MOZ_UNANNOTATED;
|
||||
mozilla::Monitor mMonitor;
|
||||
const OriginMetadata mOriginMetadata;
|
||||
nsString mOriginDirectoryPath;
|
||||
nsresult mIOThreadResultCode;
|
||||
|
@ -2614,7 +2614,7 @@ class QuotaClient final : public mozilla::dom::quota::Client {
|
|||
|
||||
static QuotaClient* sInstance;
|
||||
|
||||
Mutex mShadowDatabaseMutex MOZ_UNANNOTATED;
|
||||
Mutex mShadowDatabaseMutex;
|
||||
bool mShutdownRequested;
|
||||
|
||||
public:
|
||||
|
|
|
@ -329,7 +329,7 @@ class AudioStream final {
|
|||
soundtouch::SoundTouch* mTimeStretcher;
|
||||
|
||||
// The monitor is held to protect all access to member variables below.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
|
||||
const uint32_t mOutChannels;
|
||||
const AudioConfig::ChannelLayout::ChannelMap mChannelMap;
|
||||
|
|
|
@ -79,7 +79,7 @@ bool VP9Benchmark::IsVP9DecodeFast(bool aDefault) {
|
|||
if (!ShouldRun()) {
|
||||
return false;
|
||||
}
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
uint32_t decodeFps = StaticPrefs::media_benchmark_vp9_fps();
|
||||
uint32_t hadRecentUpdate = StaticPrefs::media_benchmark_vp9_versioncheck();
|
||||
bool needBenchmark;
|
||||
|
|
|
@ -186,7 +186,7 @@ class ChannelMediaResource
|
|||
void Revoke();
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
// mResource should only be modified on the main thread with the lock.
|
||||
// So it can be read without lock on the main thread or on other threads
|
||||
// with the lock.
|
||||
|
|
|
@ -113,7 +113,7 @@ class InputStreamReader final : public nsIInputStreamCallback {
|
|||
|
||||
nsCOMPtr<nsIInputStream> mStream;
|
||||
nsCOMPtr<nsIAsyncInputStream> mAsyncStream;
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
};
|
||||
|
||||
NS_IMPL_ADDREF(InputStreamReader);
|
||||
|
|
|
@ -140,7 +140,7 @@ class FileBlockCache : public MediaBlockCacheBase {
|
|||
// Mutex which controls access to mFD and mFDCurrentPos. Don't hold
|
||||
// mDataMutex while holding mFileMutex! mFileMutex must be owned
|
||||
// while accessing any of the following data fields or methods.
|
||||
Mutex mFileMutex MOZ_UNANNOTATED;
|
||||
Mutex mFileMutex;
|
||||
// Moves a block already committed to file.
|
||||
nsresult MoveBlockInFile(int32_t aSourceBlockIndex, int32_t aDestBlockIndex);
|
||||
// Seeks file pointer.
|
||||
|
@ -159,7 +159,7 @@ class FileBlockCache : public MediaBlockCacheBase {
|
|||
// and mFDCurrentPos. Don't hold mDataMutex while holding mFileMutex!
|
||||
// mDataMutex must be owned while accessing any of the following data
|
||||
// fields or methods.
|
||||
Mutex mDataMutex MOZ_UNANNOTATED;
|
||||
Mutex mDataMutex;
|
||||
// Ensures we either are running the event to preform IO, or an event
|
||||
// has been dispatched to preform the IO.
|
||||
// mDataMutex must be owned while calling this.
|
||||
|
|
|
@ -109,7 +109,7 @@ class FileMediaResource : public BaseMediaResource {
|
|||
// Read or Seek is in progress since it resets various internal
|
||||
// values to null.
|
||||
// This lock protects mSeekable, mInput, mSize, and mSizeInitialized.
|
||||
Mutex mLock MOZ_UNANNOTATED;
|
||||
Mutex mLock;
|
||||
|
||||
// Seekable stream interface to file. This can be used from any
|
||||
// thread.
|
||||
|
|
|
@ -171,7 +171,7 @@ class FrameStatistics {
|
|||
~FrameStatistics() = default;
|
||||
|
||||
// ReentrantMonitor to protect access of playback statistics.
|
||||
mutable ReentrantMonitor mReentrantMonitor MOZ_UNANNOTATED;
|
||||
mutable ReentrantMonitor mReentrantMonitor;
|
||||
|
||||
FrameStatisticsData mFrameStatisticsData;
|
||||
};
|
||||
|
|
|
@ -377,7 +377,7 @@ class MediaTrackGraphInitThreadRunnable;
|
|||
*/
|
||||
class ThreadedDriver : public GraphDriver {
|
||||
class IterationWaitHelper {
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
// The below members are guarded by mMonitor.
|
||||
bool mNeedAnotherIteration = false;
|
||||
TimeStamp mWakeTime;
|
||||
|
|
|
@ -80,7 +80,7 @@ class GraphRunner final : public Runnable {
|
|||
|
||||
// Monitor used for yielding mThread through Wait(), and scheduling mThread
|
||||
// through Signal() from a GraphDriver.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
// The MediaTrackGraph we're running. Weakptr beecause this graph owns us and
|
||||
// guarantees that our lifetime will not go beyond that of itself.
|
||||
MediaTrackGraphImpl* const mGraph;
|
||||
|
|
|
@ -443,7 +443,7 @@ class MediaCache {
|
|||
// The monitor protects all the data members here. Also, off-main-thread
|
||||
// readers that need to block will Wait() on this monitor. When new
|
||||
// data becomes available in the cache, we NotifyAll() on this monitor.
|
||||
mozilla::Monitor mMonitor MOZ_UNANNOTATED;
|
||||
mozilla::Monitor mMonitor;
|
||||
// This must always be accessed when the monitor is held.
|
||||
nsTArray<MediaCacheStream*> mStreams;
|
||||
// The Blocks describing the cache entries.
|
||||
|
|
|
@ -475,7 +475,7 @@ class MediaEventSourceImpl {
|
|||
}
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
nsTArray<RefPtr<Listener>> mListeners;
|
||||
};
|
||||
|
||||
|
|
|
@ -718,7 +718,7 @@ class MediaFormatReader::DemuxerProxy::Wrapper : public MediaTrackDemuxer {
|
|||
void BreakCycles() override {}
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
const RefPtr<TaskQueue> mTaskQueue;
|
||||
const bool mGetSamplesMayBlock;
|
||||
const UniquePtr<TrackInfo> mInfo;
|
||||
|
|
|
@ -392,7 +392,7 @@ class MediaFormatReader final
|
|||
// as those can be read outside the TaskQueue.
|
||||
// They are only written on the TaskQueue however, as such mMutex doesn't
|
||||
// need to be held when those members are read on the TaskQueue.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
// The platform decoder.
|
||||
RefPtr<MediaDataDecoder> mDecoder;
|
||||
nsCString mDescription;
|
||||
|
|
|
@ -391,7 +391,7 @@ class MediaManager final : public nsIMediaManagerService,
|
|||
RefPtr<MediaEngine> mBackend;
|
||||
|
||||
static StaticRefPtr<MediaManager> sSingleton;
|
||||
static StaticMutex sSingletonMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sSingletonMutex;
|
||||
|
||||
// Connect/Disconnect on media thread only
|
||||
MediaEventListener mDeviceListChangeListener;
|
||||
|
|
|
@ -179,7 +179,7 @@ class MediaQueue : private nsRefPtrDeque<T> {
|
|||
}
|
||||
}
|
||||
|
||||
mutable RecursiveMutex mRecursiveMutex MOZ_UNANNOTATED;
|
||||
mutable RecursiveMutex mRecursiveMutex;
|
||||
MediaEventProducer<RefPtr<T>> mPopFrontEvent;
|
||||
MediaEventProducer<RefPtr<T>> mPushEvent;
|
||||
MediaEventProducer<void> mFinishEvent;
|
||||
|
|
|
@ -95,7 +95,7 @@ class MediaTimer {
|
|||
|
||||
nsCOMPtr<nsIEventTarget> mThread;
|
||||
std::priority_queue<Entry> mEntries;
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
nsCOMPtr<nsITimer> mTimer;
|
||||
TimeStamp mCurrentTimerTarget;
|
||||
|
||||
|
|
|
@ -733,7 +733,7 @@ class SourceMediaTrack : public MediaTrack {
|
|||
|
||||
// This must be acquired *before* MediaTrackGraphImpl's lock, if they are
|
||||
// held together.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
// protected by mMutex
|
||||
float mVolume = 1.0;
|
||||
UniquePtr<TrackData> mUpdateTrack;
|
||||
|
|
|
@ -767,7 +767,7 @@ class MediaTrackGraphImpl : public MediaTrackGraph,
|
|||
// not safe to just grab mMonitor from some thread and start monkeying with
|
||||
// the graph. Instead, communicate with the graph thread using provided
|
||||
// mechanisms such as the ControlMessage queue.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
|
||||
// Data guarded by mMonitor (must always be accessed with mMonitor held,
|
||||
// regardless of the value of mLifecycleState).
|
||||
|
|
|
@ -76,7 +76,7 @@ class MemoryBlockCache : public MediaBlockCacheBase {
|
|||
const size_t mMaxBlocks;
|
||||
|
||||
// Mutex which controls access to all members below.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
nsTArray<uint8_t> mBuffer;
|
||||
bool mHasGrown = false;
|
||||
|
|
|
@ -117,7 +117,7 @@ class VideoFrameContainer {
|
|||
} mMainThreadState;
|
||||
|
||||
// mMutex protects all the fields below.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
// The intrinsic size is the ideal size which we should render the
|
||||
// ImageContainer's current Image at.
|
||||
// This can differ from the Image's actual size when the media resource
|
||||
|
|
|
@ -213,7 +213,7 @@ class VideoOutput : public DirectMediaTrackListener {
|
|||
}
|
||||
}
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
TimeStamp mLastFrameTime;
|
||||
// Once the frame is forced to black, we initialize mBlackImage for use in any
|
||||
// following forced-black frames.
|
||||
|
|
|
@ -175,7 +175,7 @@ struct DDMediaLogs {
|
|||
nsTArray<DDObjectLink> mObjectLinks;
|
||||
|
||||
// Protects members below.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// Processing thread.
|
||||
nsCOMPtr<nsIThread> mThread;
|
||||
|
|
|
@ -28,7 +28,7 @@ class MultiWriterQueueReaderLocking_Mutex {
|
|||
void Unlock() { mMutex.Unlock(); };
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
};
|
||||
|
||||
// Reader non-locking strategy, trusting that PopAll will never be called
|
||||
|
|
|
@ -330,7 +330,7 @@ struct DequeWrapperAW : DequeWrapperST {
|
|||
// Multi-thread writes allowed, make sure you don't pop unless writes can't
|
||||
// happen.
|
||||
struct DequeWrapperMW : DequeWrapperST {
|
||||
mozilla::Mutex mMutex MOZ_UNANNOTATED;
|
||||
mozilla::Mutex mMutex;
|
||||
|
||||
DequeWrapperMW() : mMutex("DequeWrapperMW/MT") {}
|
||||
|
||||
|
|
|
@ -131,7 +131,7 @@ class ChromiumCDMProxy : public CDMProxy {
|
|||
|
||||
RefPtr<GMPCrashHelper> mCrashHelper;
|
||||
|
||||
Mutex mCDMMutex MOZ_UNANNOTATED;
|
||||
Mutex mCDMMutex;
|
||||
RefPtr<gmp::ChromiumCDMParent> mCDM;
|
||||
nsCOMPtr<nsISerialEventTarget> mGMPThread;
|
||||
UniquePtr<ChromiumCDMCallbackProxy> mCallback;
|
||||
|
|
|
@ -86,7 +86,7 @@ class GMPSyncRunnable final {
|
|||
bool mDone;
|
||||
GMPTask* mTask;
|
||||
MessageLoop* mMessageLoop;
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
};
|
||||
|
||||
class GMPThreadImpl : public GMPThread {
|
||||
|
@ -99,7 +99,7 @@ class GMPThreadImpl : public GMPThread {
|
|||
void Join() override;
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
base::Thread mThread;
|
||||
};
|
||||
|
||||
|
@ -148,7 +148,7 @@ class GMPMutexImpl : public GMPMutex {
|
|||
void Destroy() override;
|
||||
|
||||
private:
|
||||
ReentrantMonitor mMonitor MOZ_UNANNOTATED;
|
||||
ReentrantMonitor mMonitor;
|
||||
};
|
||||
|
||||
GMPErr CreateMutex(GMPMutex** aMutex) {
|
||||
|
|
|
@ -106,9 +106,8 @@ class GeckoMediaPluginService : public mozIGeckoMediaPluginService,
|
|||
|
||||
static nsCOMPtr<nsIAsyncShutdownClient> GetShutdownBarrier();
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED; // Protects mGMPThread, mPluginCrashHelpers,
|
||||
// mGMPThreadShutdown and some members in
|
||||
// derived classes.
|
||||
Mutex mMutex; // Protects mGMPThread, mPluginCrashHelpers,
|
||||
// mGMPThreadShutdown and some members in derived classes.
|
||||
|
||||
const nsCOMPtr<nsISerialEventTarget> mMainThread;
|
||||
|
||||
|
|
|
@ -211,7 +211,7 @@ class GeckoMediaPluginServiceParent final
|
|||
|
||||
// Synchronization for barrier that ensures we've loaded GMPs from
|
||||
// MOZ_GMP_PATH before allowing GetContentParentFrom() to proceed.
|
||||
Monitor mInitPromiseMonitor MOZ_UNANNOTATED;
|
||||
Monitor mInitPromiseMonitor;
|
||||
MozMonitoredPromiseHolder<GenericPromise> mInitPromise;
|
||||
bool mLoadPluginsFromDiskComplete;
|
||||
|
||||
|
|
|
@ -84,7 +84,7 @@ class GMPStorageChild : public PGMPStorageChild {
|
|||
mozilla::ipc::IPCResult RecvShutdown();
|
||||
|
||||
private:
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
nsRefPtrHashtable<nsCStringHashKey, GMPRecordImpl> mRecords;
|
||||
GMPChild* mPlugin;
|
||||
bool mShutdown;
|
||||
|
|
|
@ -182,7 +182,7 @@ class MockCubebStream {
|
|||
|
||||
private:
|
||||
// Monitor used to block start until mFrozenStart is false.
|
||||
Monitor mFrozenStartMonitor MOZ_UNANNOTATED;
|
||||
Monitor mFrozenStartMonitor;
|
||||
// Whether this stream should wait for an explicit start request before
|
||||
// starting. Protected by FrozenStartMonitor.
|
||||
bool mFrozenStart;
|
||||
|
|
|
@ -1150,7 +1150,7 @@ class CDMStorageTest {
|
|||
nsTArray<ExpectedMessage> mExpected;
|
||||
|
||||
RefPtr<gmp::ChromiumCDMParent> mCDM;
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
Atomic<bool> mFinished;
|
||||
nsCString mNodeId;
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@ static const int64_t gEndOffsets[] = {501, 772, 1244, 1380, 1543, 2015};
|
|||
|
||||
TEST(WebMBuffered, BasicTests)
|
||||
{
|
||||
ReentrantMonitor dummy MOZ_UNANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
WebMBufferedParser parser(0);
|
||||
|
||||
nsTArray<WebMTimeDataOffset> mapping;
|
||||
|
@ -60,7 +60,7 @@ static void ReadFile(const char* aPath, nsTArray<uint8_t>& aBuffer) {
|
|||
|
||||
TEST(WebMBuffered, RealData)
|
||||
{
|
||||
ReentrantMonitor dummy MOZ_UNANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
WebMBufferedParser parser(0);
|
||||
|
||||
nsTArray<uint8_t> webmData;
|
||||
|
@ -82,7 +82,7 @@ TEST(WebMBuffered, RealData)
|
|||
|
||||
TEST(WebMBuffered, RealDataAppend)
|
||||
{
|
||||
ReentrantMonitor dummy MOZ_UNANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
WebMBufferedParser parser(0);
|
||||
nsTArray<WebMTimeDataOffset> mapping;
|
||||
|
||||
|
|
|
@ -44,7 +44,7 @@ class HLSResourceCallbacksSupport
|
|||
|
||||
private:
|
||||
~HLSResourceCallbacksSupport() {}
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
HLSDecoder* mDecoder;
|
||||
};
|
||||
|
||||
|
|
|
@ -119,7 +119,7 @@ class HLSDemuxer::HLSDemuxerCallbacksSupport
|
|||
mDemuxer = nullptr;
|
||||
}
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
private:
|
||||
~HLSDemuxerCallbacksSupport() {}
|
||||
|
|
|
@ -127,7 +127,7 @@ class HLSTrackDemuxer : public MediaTrackDemuxer,
|
|||
RefPtr<MediaRawData> mQueuedSample;
|
||||
|
||||
// Mutex to protect members below across multiple threads.
|
||||
mutable Mutex mMutex MOZ_UNANNOTATED;
|
||||
mutable Mutex mMutex;
|
||||
UniquePtr<TrackInfo> mTrackInfo;
|
||||
};
|
||||
|
||||
|
|
|
@ -116,7 +116,7 @@ class WebMContainerParser
|
|||
|
||||
WebMBufferedParser parser(0);
|
||||
nsTArray<WebMTimeDataOffset> mapping;
|
||||
ReentrantMonitor dummy MOZ_ANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
bool result =
|
||||
parser.Append(aData.Elements(), aData.Length(), mapping, dummy);
|
||||
if (!result) {
|
||||
|
@ -134,7 +134,7 @@ class WebMContainerParser
|
|||
|
||||
WebMBufferedParser parser(0);
|
||||
nsTArray<WebMTimeDataOffset> mapping;
|
||||
ReentrantMonitor dummy MOZ_ANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
parser.AppendMediaSegmentOnly();
|
||||
bool result =
|
||||
parser.Append(aData.Elements(), aData.Length(), mapping, dummy);
|
||||
|
@ -182,7 +182,7 @@ class WebMContainerParser
|
|||
nsTArray<WebMTimeDataOffset> mapping;
|
||||
mapping.AppendElements(mOverlappedMapping);
|
||||
mOverlappedMapping.Clear();
|
||||
ReentrantMonitor dummy MOZ_ANNOTATED("dummy");
|
||||
ReentrantMonitor dummy("dummy");
|
||||
mParser.Append(aData.Elements(), aData.Length(), mapping, dummy);
|
||||
if (mResource) {
|
||||
mResource->AppendData(aData);
|
||||
|
|
|
@ -83,7 +83,7 @@ class MediaSourceDemuxer : public MediaDataDemuxer,
|
|||
MozPromiseHolder<InitPromise> mInitPromise;
|
||||
|
||||
// Monitor to protect members below across multiple threads.
|
||||
mutable Monitor mMonitor MOZ_UNANNOTATED;
|
||||
mutable Monitor mMonitor;
|
||||
RefPtr<TrackBuffersManager> mAudioTrack;
|
||||
RefPtr<TrackBuffersManager> mVideoTrack;
|
||||
MediaInfo mInfo;
|
||||
|
@ -138,7 +138,7 @@ class MediaSourceTrackDemuxer
|
|||
RefPtr<MediaSourceDemuxer> mParent;
|
||||
TrackInfo::TrackType mType;
|
||||
// Monitor protecting members below accessed from multiple threads.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
media::TimeUnit mNextRandomAccessPoint;
|
||||
// Would be accessed in MFR's demuxer proxy task queue and TaskQueue, and
|
||||
// only be set on the TaskQueue. It can be accessed while on TaskQueue without
|
||||
|
|
|
@ -514,7 +514,7 @@ class TrackBuffersManager final
|
|||
Atomic<EvictionState> mEvictionState;
|
||||
|
||||
// Monitor to protect following objects accessed across multiple threads.
|
||||
mutable Mutex mMutex MOZ_UNANNOTATED;
|
||||
mutable Mutex mMutex;
|
||||
// mTaskQueue is only ever written after construction on the task queue.
|
||||
// As such, it can be accessed while on task queue without the need for the
|
||||
// mutex.
|
||||
|
|
|
@ -29,7 +29,7 @@ class OggCodecStore {
|
|||
nsClassHashtable<nsUint32HashKey, OggCodecState> mCodecStates;
|
||||
|
||||
// Protects the |mCodecStates| and the |mKnownStreams| members.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
};
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
@ -57,7 +57,7 @@ class GlobalAllocPolicy {
|
|||
|
||||
private:
|
||||
// Protect access to Instance().
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
};
|
||||
|
||||
/** This the actual base implementation underneath all AllocPolicy objects and
|
||||
|
@ -86,7 +86,7 @@ class AllocPolicyImpl : public AllocPolicy {
|
|||
void ResolvePromise(ReentrantMonitorAutoEnter& aProofOfLock);
|
||||
|
||||
const int mMaxDecoderLimit;
|
||||
ReentrantMonitor mMonitor MOZ_UNANNOTATED;
|
||||
ReentrantMonitor mMonitor;
|
||||
// The number of decoders available for creation.
|
||||
int mDecoderLimit;
|
||||
// Requests to acquire tokens.
|
||||
|
|
|
@ -148,7 +148,7 @@ class PDMInitializer final {
|
|||
}
|
||||
|
||||
static bool sHasInitializedPDMs;
|
||||
static StaticMutex sMonitor MOZ_UNANNOTATED;
|
||||
static StaticMutex sMonitor;
|
||||
};
|
||||
|
||||
bool PDMInitializer::sHasInitializedPDMs = false;
|
||||
|
|
|
@ -46,7 +46,7 @@ class SimpleMap {
|
|||
}
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED; // To protect mMap.
|
||||
Mutex mMutex; // To protect mMap.
|
||||
AutoTArray<Element, 16> mMap;
|
||||
};
|
||||
|
||||
|
|
|
@ -51,7 +51,7 @@ class SamplesWaitingForKey {
|
|||
~SamplesWaitingForKey();
|
||||
|
||||
private:
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
RefPtr<CDMProxy> mProxy;
|
||||
struct SampleEntry {
|
||||
RefPtr<MediaRawData> mSample;
|
||||
|
|
|
@ -112,7 +112,7 @@ class AppleVTDecoder : public MediaDataDecoder,
|
|||
// not required and so input samples on mTaskQueue need not be processed.
|
||||
Atomic<bool> mIsFlushing;
|
||||
// Protects mReorderQueue and mPromise.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
ReorderQueue mReorderQueue;
|
||||
MozMonitoredPromiseHolder<DecodePromise> mPromise;
|
||||
|
||||
|
|
|
@ -65,9 +65,8 @@ class FFmpegDataDecoder<LIBAV_VER>
|
|||
AVCodecID mCodecID; // set in constructor
|
||||
|
||||
protected:
|
||||
static StaticMutex sMutex
|
||||
MOZ_UNANNOTATED; // used to provide critical-section locking
|
||||
// for calls into ffmpeg
|
||||
static StaticMutex sMutex; // used to provide critical-section locking
|
||||
// for calls into ffmpeg
|
||||
const RefPtr<TaskQueue> mTaskQueue; // set in constructor
|
||||
|
||||
private:
|
||||
|
|
|
@ -131,7 +131,7 @@ class VideoFramePool final {
|
|||
|
||||
private:
|
||||
// Protect mDMABufSurfaces pool access
|
||||
Mutex mSurfaceLock MOZ_UNANNOTATED;
|
||||
Mutex mSurfaceLock;
|
||||
nsTArray<RefPtr<VideoFrameSurfaceVAAPI>> mDMABufSurfaces;
|
||||
// We may fail to create texture over DMABuf memory due to driver bugs so
|
||||
// check that before we export first DMABuf video frame.
|
||||
|
|
|
@ -941,7 +941,7 @@ D3D11DXVA2Manager::CopyToImage(IMFSample* aVideoSample,
|
|||
|
||||
if (!mutex && mDevice != DeviceManagerDx::Get()->GetCompositorDevice() &&
|
||||
mSyncObject) {
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
// Ensure that we only ever attempt to synchronise via the sync object
|
||||
// serially as when using the same D3D11 device for multiple video decoders
|
||||
// it can lead to deadlocks.
|
||||
|
|
|
@ -73,7 +73,7 @@ class DXVA2Manager {
|
|||
const nsAString& aDriverVersionString);
|
||||
|
||||
protected:
|
||||
Mutex mLock MOZ_UNANNOTATED;
|
||||
Mutex mLock;
|
||||
DXVA2Manager();
|
||||
|
||||
bool IsUnsupportedResolution(const uint32_t& aWidth, const uint32_t& aHeight,
|
||||
|
|
|
@ -242,7 +242,7 @@ already_AddRefed<MediaDataDecoder> WMFDecoderModule::CreateAudioDecoder(
|
|||
|
||||
template <const GUID& aGuid>
|
||||
static bool CanCreateWMFDecoder() {
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
StaticMutexAutoLock lock(sMutex);
|
||||
static Maybe<bool> result;
|
||||
if (result.isNothing()) {
|
||||
|
|
|
@ -231,7 +231,7 @@ class CamerasChild final : public PCamerasChild {
|
|||
|
||||
nsTArray<CapturerElement> mCallbacks;
|
||||
// Protects the callback arrays
|
||||
Mutex mCallbackMutex MOZ_UNANNOTATED;
|
||||
Mutex mCallbackMutex;
|
||||
|
||||
bool mIPCIsAlive;
|
||||
|
||||
|
@ -243,11 +243,11 @@ class CamerasChild final : public PCamerasChild {
|
|||
// request. The Notify on receiving the response will then unblock
|
||||
// both waiters and one will be guaranteed to get the wrong result.
|
||||
// Take this one before taking mReplyMonitor.
|
||||
Mutex mRequestMutex MOZ_UNANNOTATED;
|
||||
Mutex mRequestMutex;
|
||||
// Hold to wait for an async response to our calls *and* until the
|
||||
// user of LockAndDispatch<> has read the data out. This is done by
|
||||
// keeping the LockAndDispatch object alive.
|
||||
Monitor mReplyMonitor MOZ_UNANNOTATED;
|
||||
Monitor mReplyMonitor;
|
||||
// Async response valid?
|
||||
bool mReceivedReply;
|
||||
// Async responses data contents;
|
||||
|
|
|
@ -59,7 +59,7 @@ void MediaSystemResourceManager::Init() {
|
|||
return;
|
||||
}
|
||||
|
||||
ReentrantMonitor barrier MOZ_UNANNOTATED("MediaSystemResourceManager::Init");
|
||||
ReentrantMonitor barrier("MediaSystemResourceManager::Init");
|
||||
ReentrantMonitorAutoEnter mainThreadAutoMon(barrier);
|
||||
bool done = false;
|
||||
|
||||
|
@ -191,8 +191,7 @@ bool MediaSystemResourceManager::AcquireSyncNoWait(
|
|||
MOZ_ASSERT(aClient);
|
||||
MOZ_ASSERT(!InImageBridgeChildThread());
|
||||
|
||||
ReentrantMonitor barrier MOZ_UNANNOTATED(
|
||||
"MediaSystemResourceManager::AcquireSyncNoWait");
|
||||
ReentrantMonitor barrier("MediaSystemResourceManager::AcquireSyncNoWait");
|
||||
ReentrantMonitorAutoEnter autoMon(barrier);
|
||||
bool done = false;
|
||||
{
|
||||
|
|
|
@ -65,7 +65,7 @@ class MediaSystemResourceManager {
|
|||
|
||||
void HandleAcquireResult(uint32_t aId, bool aSuccess);
|
||||
|
||||
ReentrantMonitor mReentrantMonitor MOZ_UNANNOTATED;
|
||||
ReentrantMonitor mReentrantMonitor;
|
||||
|
||||
bool mShutDown;
|
||||
|
||||
|
|
|
@ -225,7 +225,7 @@ void Await(already_AddRefed<nsIEventTarget> aPool,
|
|||
RejectFunction&& aRejectFunction) {
|
||||
RefPtr<TaskQueue> taskQueue =
|
||||
new TaskQueue(std::move(aPool), "MozPromiseAwait");
|
||||
Monitor mon MOZ_UNANNOTATED(__func__);
|
||||
Monitor mon(__func__);
|
||||
bool done = false;
|
||||
|
||||
aPromise->Then(
|
||||
|
@ -256,7 +256,7 @@ Await(already_AddRefed<nsIEventTarget> aPool,
|
|||
RefPtr<MozPromise<ResolveValueType, RejectValueType, Excl>> aPromise) {
|
||||
RefPtr<TaskQueue> taskQueue =
|
||||
new TaskQueue(std::move(aPool), "MozPromiseAwait");
|
||||
Monitor mon MOZ_UNANNOTATED(__func__);
|
||||
Monitor mon(__func__);
|
||||
bool done = false;
|
||||
|
||||
typename MozPromise<ResolveValueType, RejectValueType,
|
||||
|
@ -400,7 +400,7 @@ class AsyncBlockers {
|
|||
mPromise->Resolve(true, __func__);
|
||||
mResolved = true;
|
||||
}
|
||||
Mutex mLock MOZ_UNANNOTATED; // protects mBlockers and mResolved.
|
||||
Mutex mLock; // protects mBlockers and mResolved.
|
||||
std::map<void*, bool> mBlockers;
|
||||
bool mResolved = false;
|
||||
const RefPtr<GenericPromise::Private> mPromise;
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
#include <CoreFoundation/CoreFoundation.h>
|
||||
|
||||
static bool gRunLoopSet = false;
|
||||
static mozilla::StaticMutex gMutex MOZ_UNANNOTATED;
|
||||
static mozilla::StaticMutex gMutex;
|
||||
|
||||
void mozilla_set_coreaudio_notification_runloop_if_needed() {
|
||||
mozilla::StaticMutexAutoLock lock(gMutex);
|
||||
|
|
|
@ -50,7 +50,7 @@ class OpenSLESProvider {
|
|||
void DestroyEngine(SLObjectItf* aObjectm);
|
||||
|
||||
// Protect all our internal variables
|
||||
mozilla::Mutex mLock MOZ_UNANNOTATED;
|
||||
mozilla::Mutex mLock;
|
||||
SLObjectItf mSLEngine;
|
||||
int mSLEngineUsers;
|
||||
bool mIsRealized;
|
||||
|
|
|
@ -169,7 +169,7 @@ class ShmemPool final {
|
|||
&aRes.mShmem));
|
||||
}
|
||||
const PoolType mPoolType;
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
size_t mPoolFree;
|
||||
bool mErrorLogged;
|
||||
#ifdef DEBUG
|
||||
|
|
|
@ -61,7 +61,7 @@ class TabCapturer {
|
|||
// Used to protect mCallback, since TabCapturer's lifetime might be
|
||||
// longer than mCallback's on stop/shutdown, and we may be waiting on a
|
||||
// tab to finish capturing on MainThread.
|
||||
Monitor mMonitor MOZ_UNANNOTATED;
|
||||
Monitor mMonitor;
|
||||
webrtc::DesktopCapturer::Callback* mCallback = nullptr;
|
||||
|
||||
uint64_t mBrowserId = 0;
|
||||
|
|
|
@ -72,7 +72,7 @@ class AudioBufferMemoryTracker : public nsIMemoryReporter {
|
|||
void Init();
|
||||
|
||||
/* This protects all members of this class. */
|
||||
static StaticMutex sMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sMutex;
|
||||
static StaticRefPtr<AudioBufferMemoryTracker> sSingleton;
|
||||
nsTHashSet<const AudioBuffer*> mBuffers;
|
||||
};
|
||||
|
|
|
@ -80,7 +80,7 @@ class SharedBuffers final {
|
|||
// Synchronizes access to mBufferList. Note that it's the responsibility
|
||||
// of the callers to perform the required locking, and we assert that every
|
||||
// time we access mBufferList.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
// The list representing the queue.
|
||||
BufferList mBufferList;
|
||||
};
|
||||
|
|
|
@ -143,7 +143,7 @@ class HRTFDatabaseLoader {
|
|||
nsAutoRef<HRTFDatabase> m_hrtfDatabase;
|
||||
|
||||
// Holding a m_threadLock is required when accessing m_databaseLoaderThread.
|
||||
mozilla::Mutex m_threadLock MOZ_UNANNOTATED;
|
||||
mozilla::Mutex m_threadLock;
|
||||
PRThread* m_databaseLoaderThread;
|
||||
|
||||
float m_databaseSampleRate;
|
||||
|
|
|
@ -83,7 +83,7 @@ class ReverbConvolver {
|
|||
|
||||
// Background thread and synchronization
|
||||
base::Thread m_backgroundThread;
|
||||
mozilla::Monitor m_backgroundThreadMonitor MOZ_UNANNOTATED;
|
||||
mozilla::Monitor m_backgroundThreadMonitor;
|
||||
bool m_useBackgroundThreads;
|
||||
std::atomic<bool> m_wantsToExit;
|
||||
std::atomic<bool> m_moreInputBuffered;
|
||||
|
|
|
@ -298,7 +298,7 @@ class WebMBufferedState final {
|
|||
MOZ_COUNTED_DTOR(WebMBufferedState)
|
||||
|
||||
// Synchronizes access to the mTimeMapping array and mLastBlockOffset.
|
||||
ReentrantMonitor mReentrantMonitor MOZ_UNANNOTATED;
|
||||
ReentrantMonitor mReentrantMonitor;
|
||||
|
||||
// Sorted (by offset) map of data offsets to timecodes. Populated
|
||||
// on the main thread as data is received and parsed by WebMBufferedParsers.
|
||||
|
|
|
@ -23,7 +23,7 @@ using AudioDeviceSet = CubebDeviceEnumerator::AudioDeviceSet;
|
|||
|
||||
/* static */
|
||||
static StaticRefPtr<CubebDeviceEnumerator> sInstance;
|
||||
static StaticMutex sInstanceMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex sInstanceMutex;
|
||||
|
||||
/* static */
|
||||
CubebDeviceEnumerator* CubebDeviceEnumerator::GetInstance() {
|
||||
|
|
|
@ -69,7 +69,7 @@ class CubebDeviceEnumerator final {
|
|||
void AudioDeviceListChanged(Side aSide);
|
||||
RefPtr<const AudioDeviceSet> EnumerateAudioDevices(Side aSide);
|
||||
// Synchronize access to mInputDevices and mOutputDevices;
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
RefPtr<const AudioDeviceSet> mInputDevices;
|
||||
RefPtr<const AudioDeviceSet> mOutputDevices;
|
||||
// If mManual*Invalidation is true, then it is necessary to query the device
|
||||
|
|
|
@ -152,7 +152,7 @@ class MediaEngineRemoteVideoSource : public MediaEngineSource,
|
|||
|
||||
// mMutex protects certain members on 3 threads:
|
||||
// MediaManager, Cameras IPC and MediaTrackGraph.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// Current state of this source.
|
||||
// Set under mMutex on the owning thread. Accessed under one of the two.
|
||||
|
|
|
@ -246,7 +246,7 @@ class WebrtcAudioConduit : public AudioSessionConduit,
|
|||
// Accessed only on the Call thread.
|
||||
bool mDtmfEnabled;
|
||||
|
||||
mutable RWLock mLock MOZ_UNANNOTATED;
|
||||
mutable RWLock mLock;
|
||||
|
||||
// Call worker thread. All access to mCall->Call() happens here.
|
||||
const RefPtr<AbstractThread> mCallThread;
|
||||
|
|
|
@ -271,7 +271,7 @@ class WebrtcVideoConduit
|
|||
|
||||
bool RequiresNewSendStream(const VideoCodecConfig& newConfig) const;
|
||||
|
||||
mutable mozilla::ReentrantMonitor mRendererMonitor MOZ_UNANNOTATED;
|
||||
mutable mozilla::ReentrantMonitor mRendererMonitor;
|
||||
|
||||
// Accessed on any thread under mRendererMonitor.
|
||||
RefPtr<mozilla::VideoRenderer> mRenderer;
|
||||
|
@ -328,7 +328,7 @@ class WebrtcVideoConduit
|
|||
// that will update the webrtc.org configuration.
|
||||
WatchManager<WebrtcVideoConduit> mWatchManager;
|
||||
|
||||
mutable Mutex mMutex MOZ_UNANNOTATED;
|
||||
mutable Mutex mMutex;
|
||||
|
||||
// Decoder factory used by mRecvStream when it needs new decoders. This is
|
||||
// not shared broader like some state in the WebrtcCallWrapper because it
|
||||
|
|
|
@ -279,7 +279,7 @@ class WebrtcGmpVideoEncoder : public GMPVideoEncoderCallbackProxy,
|
|||
uint32_t mMaxPayloadSize;
|
||||
webrtc::CodecSpecificInfo mCodecSpecificInfo;
|
||||
// Protects mCallback
|
||||
Mutex mCallbackMutex MOZ_UNANNOTATED;
|
||||
Mutex mCallbackMutex;
|
||||
webrtc::EncodedImageCallback* mCallback;
|
||||
Maybe<uint64_t> mCachedPluginId;
|
||||
const std::string mPCHandle;
|
||||
|
@ -430,7 +430,7 @@ class WebrtcGmpVideoDecoder : public GMPVideoDecoderCallbackProxy {
|
|||
nsTArray<UniquePtr<GMPDecodeData>> mQueuedFrames;
|
||||
GMPVideoHost* mHost;
|
||||
// Protects mCallback
|
||||
Mutex mCallbackMutex MOZ_UNANNOTATED;
|
||||
Mutex mCallbackMutex;
|
||||
webrtc::DecodedImageCallback* mCallback;
|
||||
Maybe<uint64_t> mCachedPluginId;
|
||||
Atomic<GMPErr, ReleaseAcquire> mDecoderStatus;
|
||||
|
|
|
@ -57,7 +57,7 @@ class WebrtcMediaDataEncoder : public RefCountedWebrtcVideoEncoder {
|
|||
const RefPtr<PEMFactory> mFactory;
|
||||
RefPtr<MediaDataEncoder> mEncoder;
|
||||
|
||||
Mutex mCallbackMutex MOZ_UNANNOTATED; // Protects mCallback and mError.
|
||||
Mutex mCallbackMutex; // Protects mCallback and mError.
|
||||
webrtc::EncodedImageCallback* mCallback = nullptr;
|
||||
MediaResult mError = NS_OK;
|
||||
|
||||
|
|
|
@ -283,7 +283,7 @@ class NrUdpSocketIpc : public NrSocketIpc {
|
|||
// STS thread executor
|
||||
void recv_callback_s(RefPtr<nr_udp_message> msg);
|
||||
|
||||
ReentrantMonitor monitor_ MOZ_UNANNOTATED; // protects err_and state_
|
||||
ReentrantMonitor monitor_; // protects err_and state_
|
||||
bool err_;
|
||||
NrSocketIpcState state_;
|
||||
|
||||
|
|
|
@ -1546,7 +1546,7 @@ class MediaPipelineReceiveVideo::PipelineListener
|
|||
|
||||
private:
|
||||
RefPtr<layers::ImageContainer> mImageContainer;
|
||||
Mutex mMutex MOZ_UNANNOTATED; // Protects the below members.
|
||||
Mutex mMutex; // Protects the below members.
|
||||
PrincipalHandle mPrincipalHandle;
|
||||
// Set to true on the sts thread if privacy is requested when ALPN was
|
||||
// negotiated. Set to false again when mPrincipalHandle is private.
|
||||
|
|
|
@ -49,7 +49,7 @@ class MIDIMessageQueue {
|
|||
// Array of messages to be sent.
|
||||
nsTArray<MIDIMessage> mMessageQueue;
|
||||
// Mutex for coordinating cross thread array access.
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
};
|
||||
|
||||
} // namespace dom
|
||||
|
|
|
@ -149,7 +149,7 @@ class MIDIPlatformService {
|
|||
nsClassHashtable<nsStringHashKey, MIDIMessageQueue> mMessageQueues;
|
||||
|
||||
// Mutex for managing access to message queue objects.
|
||||
Mutex mMessageQueueMutex MOZ_UNANNOTATED;
|
||||
Mutex mMessageQueueMutex;
|
||||
};
|
||||
|
||||
} // namespace mozilla::dom
|
||||
|
|
|
@ -47,7 +47,7 @@ class midirMIDIPlatformService : public MIDIPlatformService {
|
|||
// midir has its own internal threads and we can't execute jobs directly on
|
||||
// them, instead we forward them to the background thread the service was
|
||||
// created in.
|
||||
static StaticMutex gBackgroundThreadMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex gBackgroundThreadMutex;
|
||||
static nsCOMPtr<nsIThread> gBackgroundThread;
|
||||
};
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
namespace mozilla::dom {
|
||||
|
||||
static StaticRefPtr<PerformanceService> gPerformanceService;
|
||||
static StaticMutex gPerformanceServiceMutex MOZ_UNANNOTATED;
|
||||
static StaticMutex gPerformanceServiceMutex;
|
||||
|
||||
/* static */
|
||||
PerformanceService* PerformanceService::GetOrCreate() {
|
||||
|
|
|
@ -37,7 +37,7 @@ class PerformanceStorageWorker final : public PerformanceStorage {
|
|||
PerformanceStorageWorker();
|
||||
~PerformanceStorageWorker();
|
||||
|
||||
Mutex mMutex MOZ_UNANNOTATED;
|
||||
Mutex mMutex;
|
||||
|
||||
// Protected by mutex.
|
||||
// Created and released on worker-thread. Used also on main-thread.
|
||||
|
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче