MCPcopy Create free account
hub / github.com/catboost/catboost / AcquireWrite

Method AcquireWrite

util/system/rwlock.cpp:86–96  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84}
85
86void TRWMutex::TImpl::AcquireWrite() noexcept {
87 with_lock (Lock_) {
88 while (State_ != 0) {
89 ++BlockedWriters_;
90 WriteCond_.Wait(Lock_);
91 --BlockedWriters_;
92 }
93
94 State_ = -1;
95 }
96}
97
98bool TRWMutex::TImpl::TryAcquireWrite() noexcept {
99 with_lock (Lock_) {

Callers 2

AcquireMethod · 0.80
RunReadersWritersMethod · 0.80

Calls 1

LastSystemErrorTextFunction · 0.70

Tested by

no test coverage detected