diff options
author | 2009-03-05 14:34:35 -0800 | |
---|---|---|
committer | 2009-03-05 14:34:35 -0800 | |
commit | 4df2423a947bcd3f024cc3d3a1a315a8dc428598 (patch) | |
tree | e7dac2c5a367b169e7f05a36058cf470e93f003b /include/utils/threads.h | |
parent | c474dec3ffa1c0fe37edb3e701684188f7e8e7bc (diff) |
auto import from //depot/cupcake/@136594
Diffstat (limited to 'include/utils/threads.h')
-rw-r--r-- | include/utils/threads.h | 35 |
1 files changed, 0 insertions, 35 deletions
diff --git a/include/utils/threads.h b/include/utils/threads.h index 7dca810043e9..8d8d46a054d8 100644 --- a/include/utils/threads.h +++ b/include/utils/threads.h @@ -249,41 +249,6 @@ private: /* - * Read/write lock. The resource can have multiple readers or one writer, - * but can't be read and written at the same time. - * - * The same thread should not call a lock function while it already has - * a lock. (Should be okay for multiple readers.) - */ -class ReadWriteLock { -public: - ReadWriteLock() - : mNumReaders(0), mNumWriters(0) - {} - ~ReadWriteLock() {} - - void lockForRead(); - bool tryLockForRead(); - void unlockForRead(); - - void lockForWrite(); - bool tryLockForWrite(); - void unlockForWrite(); - -private: - int mNumReaders; - int mNumWriters; - - Mutex mLock; - Condition mReadWaiter; - Condition mWriteWaiter; -#if defined(PRINT_RENDER_TIMES) - DurationTimer mDebugTimer; -#endif -}; - - -/* * This is our spiffy thread object! */ |