| /rocksdb-6.9/utilities/transactions/ |
| D | transaction_db_mutex_impl.cc | 65 mutex_.lock(); in Lock() 82 mutex_.lock(); in TryLockFor() 97 std::unique_lock<std::mutex> lock(mutex_impl->mutex_, std::adopt_lock); in Wait() local 98 cv_.wait(lock); in Wait() 101 lock.release(); in Wait() 111 std::unique_lock<std::mutex> lock(mutex_impl->mutex_, std::adopt_lock); in WaitFor() local 115 cv_.wait(lock); in WaitFor() 118 auto cv_status = cv_.wait_for(lock, duration); in WaitFor() 127 lock.release(); in WaitFor()
|
| D | pessimistic_transaction_db.cc | 548 std::lock_guard<std::mutex> lock(map_mutex_); in InsertExpirableTransaction() local 553 std::lock_guard<std::mutex> lock(map_mutex_); in RemoveExpirableTransaction() local 559 std::lock_guard<std::mutex> lock(map_mutex_); in TryStealingExpiredTransactionLocks() local 580 std::lock_guard<std::mutex> lock(name_map_mutex_); in GetTransactionByName() local 593 std::lock_guard<std::mutex> lock(name_map_mutex_); in GetAllPreparedTransactions() local 619 std::lock_guard<std::mutex> lock(name_map_mutex_); in RegisterTransaction() local 625 std::lock_guard<std::mutex> lock(name_map_mutex_); in UnregisterTransaction() local
|
| D | pessimistic_transaction.h | 74 std::lock_guard<std::mutex> lock(wait_mutex_); in GetWaitingTxns() 84 std::lock_guard<std::mutex> lock(wait_mutex_); in SetWaitingTxn() 91 std::lock_guard<std::mutex> lock(wait_mutex_); in ClearWaitingTxn()
|
| /rocksdb-6.9/env/ |
| D | mock_env.cc | 40 MutexLock lock(&mutex_); in Ref() local 48 MutexLock lock(&mutex_); in Lock() local 59 MutexLock lock(&mutex_); in Unlock() local 82 MutexLock lock(&mutex_); in Truncate() local 97 MutexLock lock(&mutex_); in CorruptBuffer() local 104 MutexLock lock(&mutex_); in Read() local 124 MutexLock lock(&mutex_); in Write() local 136 MutexLock lock(&mutex_); in Append() local 430 MutexLock lock(&mutex_); in NewSequentialFile() local 447 MutexLock lock(&mutex_); in NewRandomAccessFile() local [all …]
|
| D | fs_posix.cc | 98 static int LockOrUnlock(int fd, bool lock) { in LockOrUnlock() argument 102 f.l_type = (lock ? F_WRLCK : F_UNLCK); in LockOrUnlock() 748 FileLock** lock, IODebugContext* /*dbg*/) override { in LockFile() argument 749 *lock = nullptr; in LockFile() 803 *lock = my_lock; in LockFile() 810 IOStatus UnlockFile(FileLock* lock, const IOOptions& /*opts*/, in UnlockFile() argument 812 PosixFileLock* my_lock = reinterpret_cast<PosixFileLock*>(lock); in UnlockFile()
|
| /rocksdb-6.9/test_util/ |
| D | sync_point_impl.cc | 34 std::lock_guard<std::mutex> lock(mutex_); in LoadDependency() local 48 std::lock_guard<std::mutex> lock(mutex_); in LoadDependencyAndMarkers() local 76 std::unique_lock<std::mutex> lock(mutex_); in ClearCallBack() local 78 cv_.wait(lock); in ClearCallBack() 84 std::unique_lock<std::mutex> lock(mutex_); in ClearAllCallBacks() local 86 cv_.wait(lock); in ClearAllCallBacks() 96 std::unique_lock<std::mutex> lock(mutex_); in Process() local 111 cv_.wait(lock); in Process() 122 mutex_.lock(); in Process()
|
| D | sync_point_impl.h | 49 std::lock_guard<std::mutex> lock(mutex_); in SetCallBack() 62 std::lock_guard<std::mutex> lock(mutex_); in ClearTrace()
|
| /rocksdb-6.9/util/ |
| D | threadpool_imp.cc | 152 std::unique_lock<std::mutex> lock(mu_); in JoinThreads() local 161 lock.unlock(); in JoinThreads() 177 std::lock_guard<std::mutex> lock(mu_); in LowerIOPriority() local 183 std::lock_guard<std::mutex> lock(mu_); in LowerCPUPriority() local 193 std::unique_lock<std::mutex> lock(mu_); in BGThread() local 197 bgsignal_.wait(lock); in BGThread() 231 lock.unlock(); in BGThread() 316 std::lock_guard<std::mutex> lock(mu_); in SetBackgroundThreadsInternal() local 329 std::unique_lock<std::mutex> lock(mu_); in GetBackgroundThreads() local 361 std::lock_guard<std::mutex> lock(mu_); in Submit() local [all …]
|
| /rocksdb-6.9/monitoring/ |
| D | statistics.cc | 242 MutexLock lock(&aggregate_lock_); in getTickerCount() local 257 MutexLock lock(&aggregate_lock_); in histogramData() local 273 MutexLock lock(&aggregate_lock_); in getHistogramString() local 279 MutexLock lock(&aggregate_lock_); in setTickerCount() local 301 MutexLock lock(&aggregate_lock_); in getAndResetTickerCount() local 336 MutexLock lock(&aggregate_lock_); in Reset() local 356 MutexLock lock(&aggregate_lock_); in ToString() local 394 MutexLock lock(&aggregate_lock_); in getTickerMap() local
|
| /rocksdb-6.9/memory/ |
| D | concurrent_arena.h | 67 std::unique_lock<SpinMutex> lock(arena_mutex_, std::defer_lock); in ApproximateMemoryUsage() 68 lock.lock(); in ApproximateMemoryUsage() 143 arena_lock.lock(); in AllocateImpl() 154 s->mutex.lock(); in AllocateImpl() 156 std::unique_lock<SpinMutex> lock(s->mutex, std::adopt_lock); in AllocateImpl()
|
| /rocksdb-6.9/docs/_posts/ |
| D | 2014-05-14-lock.markdown | 7 - /blog/521/lock/ 10 … introduce the recent improvements we did to RocksDB to improve the issue of lock contention costs. 12 …en and mem tables are lock-free data structures supporting single writer and multiple readers. The… 27 … but if you are building a high throughput server with lots of reads, the lock contention will bec… 29 …n lists live mem tables and SST tables so a reader only needs acquire the lock in order to find th… 33 …lock-free in read queries. After consolidating reference counting to one single super version and … 41 …volves malloc (in our case). Malloc sometimes is slow because it needs to lock some shared data st… 48 …lock, I was lying. In RocksDB, all LRU caches had exclusive mutexes within to protect writes to th… 53 …lock contention is not a bottleneck anymore, which is shown in our [memory-only benchmark](https:/…
|
| D | 2014-06-27-avoid-expensive-locks-in-get.markdown | 10 As promised in the previous [blog post](blog/2014/05/14/lock.html)! 24 The lock is necessary because pointer super_version_ may be updated, the corresponding SuperVersion… 32 …tected, mutex must be acquired to update the reference. The cost of mutex lock is amortized among … 64 …it each thread’s local storage and free its resources without incurring a lock. We designed a lock…
|
| /rocksdb-6.9/db_stress_tool/ |
| D | no_batched_ops_stress.cc | 306 std::unique_ptr<MutexLock>& lock) override { in TestPut() argument 313 lock.reset(); in TestPut() 316 lock.reset( in TestPut() 384 std::unique_ptr<MutexLock>& lock) override { in TestDelete() argument 395 lock.reset(); in TestDelete() 398 lock.reset( in TestDelete() 460 std::unique_ptr<MutexLock>& lock) override { in TestDeleteRange() argument 472 lock.reset(); in TestDeleteRange() 478 range_locks.emplace_back(std::move(lock)); in TestDeleteRange() 524 std::unique_ptr<MutexLock>& lock) override { in TestIngestExternalFile() argument [all …]
|
| D | db_stress_test_base.h | 90 std::unique_ptr<MutexLock>& lock) = 0; 95 std::unique_ptr<MutexLock>& lock) = 0; 100 std::unique_ptr<MutexLock>& lock) = 0; 105 std::unique_ptr<MutexLock>& lock) = 0;
|
| /rocksdb-6.9/db/ |
| D | logs_with_prep_tracker.cc | 13 std::lock_guard<std::mutex> lock(prepared_section_completed_mutex_); in MarkLogAsHavingPrepSectionFlushed() local 24 std::lock_guard<std::mutex> lock(logs_with_prep_mutex_); in MarkLogAsContainingPrepSection() local 44 std::lock_guard<std::mutex> lock(logs_with_prep_mutex_); in FindMinLogContainingOutstandingPrep() local
|
| D | flush_scheduler.cc | 17 std::lock_guard<std::mutex> lock(checking_mutex_); in ScheduleWork() local 50 std::lock_guard<std::mutex> lock(checking_mutex_); in TakeNextColumnFamily() local 70 std::lock_guard<std::mutex> lock(checking_mutex_); in Empty() local
|
| D | trim_history_scheduler.cc | 15 std::lock_guard<std::mutex> lock(checking_mutex_); in ScheduleWork() local 22 std::lock_guard<std::mutex> lock(checking_mutex_); in TakeNextColumnFamily() local
|
| /rocksdb-6.9/utilities/persistent_cache/ |
| D | hash_table_evictable.h | 46 port::RWMutex& lock = GetMutex(h); in Insert() local 48 WriteLock _(&lock); in Insert() 66 port::RWMutex& lock = GetMutex(h); in Find() local 68 ReadLock _(&lock); in Find()
|
| D | hash_table.h | 119 port::RWMutex& lock = locks_[lock_idx]; in Find() local 120 lock.ReadLock(); in Find() 124 *ret_lock = &lock; in Find() 128 lock.ReadUnlock(); in Find()
|
| /rocksdb-6.9/utilities/ |
| D | env_timed.cc | 120 Status LockFile(const std::string& fname, FileLock** lock) override { in LockFile() argument 122 return EnvWrapper::LockFile(fname, lock); in LockFile() 125 Status UnlockFile(FileLock* lock) override { in UnlockFile() argument 127 return EnvWrapper::UnlockFile(lock); in UnlockFile()
|
| D | env_librados.cc | 332 std::lock_guard<std::mutex> lock(_mutex); in Append() local 366 std::lock_guard<std::mutex> lock(_mutex); in Truncate() local 409 std::lock_guard<std::mutex> lock(_mutex); in Flush() local 431 std::lock_guard<std::mutex> lock(_mutex); in Sync() local 466 std::lock_guard<std::mutex> lock(_mutex); in GetFileSize() local 1420 FileLock** lock) in LockFile() argument 1444 *lock = new LibradosFileLock(_GetIoctx(fpath), fpath); in LockFile() 1458 Status EnvLibrados::UnlockFile(FileLock* lock) in UnlockFile() argument 1460 LOG_DEBUG("[IO]%p\n", lock); in UnlockFile() 1461 if (nullptr != lock) { in UnlockFile() [all …]
|
| /rocksdb-6.9/port/win/ |
| D | env_win.cc | 848 FileLock** lock) { in LockFile() argument 849 assert(lock != nullptr); in LockFile() 851 *lock = NULL; in LockFile() 874 *lock = new WinFileLock(hFile); in LockFile() 880 Status WinEnvIO::UnlockFile(FileLock* lock) { in UnlockFile() argument 883 assert(lock != nullptr); in UnlockFile() 885 delete lock; in UnlockFile() 1419 FileLock** lock) { in LockFile() argument 1420 return winenv_io_.LockFile(lockFname, lock); in LockFile() 1423 Status WinEnv::UnlockFile(FileLock* lock) { in UnlockFile() argument [all …]
|
| D | env_win.h | 149 virtual Status LockFile(const std::string& lockFname, FileLock** lock); 151 virtual Status UnlockFile(FileLock* lock); 281 Status LockFile(const std::string& lockFname, FileLock** lock) override; 283 Status UnlockFile(FileLock* lock) override;
|
| /rocksdb-6.9/third-party/folly/folly/synchronization/detail/ |
| D | ProxyLockable-inl.h | 56 proxy_.emplace(mtx.lock()); in ProxyLockableUniqueLock() 114 void ProxyLockableUniqueLock<Mutex>::lock() { in lock() function 118 proxy_.emplace(mutex_->lock()); in lock()
|
| D | ProxyLockable.h | 36 _t<std::decay<decltype(std::declval<mutex_type>().lock())>>; 91 void lock();
|