/external/rust/crates/parking_lot/src/ |
D | rwlock.rs | 89 pub type RwLock<T> = lock_api::RwLock<RawRwLock, T>; typedef 94 pub const fn const_rwlock<T>(val: T) -> RwLock<T> { in const_rwlock() 95 RwLock::const_new(<RawRwLock as lock_api::RawRwLock>::INIT, val) in const_rwlock() 130 use crate::{RwLock, RwLockUpgradableReadGuard, RwLockWriteGuard}; 146 let l = RwLock::new(()); in smoke() 160 let r = Arc::new(RwLock::new(())); in frob() 184 let arc = Arc::new(RwLock::new(1)); in test_rw_arc_no_poison_wr() 197 let arc = Arc::new(RwLock::new(1)); in test_rw_arc_no_poison_ww() 210 let arc = Arc::new(RwLock::new(1)); in test_rw_arc_no_poison_rr() 223 let arc = Arc::new(RwLock::new(1)); in test_rw_arc_no_poison_rw() [all …]
|
D | deadlock.rs | 43 use crate::{Mutex, ReentrantMutex, RwLock}; 172 let m1: Arc<RwLock<()>> = Default::default(); in test_rwlock_deadlock() 173 let m2: Arc<RwLock<()>> = Default::default(); in test_rwlock_deadlock() 174 let m3: Arc<RwLock<()>> = Default::default(); in test_rwlock_deadlock() 218 let m1: Arc<RwLock<()>> = Default::default(); in test_rwlock_deadlock_reentrant()
|
/external/rust/crates/tokio/tests/ |
D | sync_rwlock.rs | 10 use tokio::sync::{Barrier, RwLock}; 16 let rwlock = RwLock::new(42); in into_inner() 23 let rwlock = RwLock::new(100); in read_shared() 34 let rwlock = RwLock::new(100); in write_shared_pending() 45 let rwlock = RwLock::new(100); in read_exclusive_pending() 57 let rwlock = RwLock::with_max_readers(100, 1024); in exhaust_reading() 78 let rwlock = RwLock::new(100); in write_exclusive_pending() 89 let rwlock = RwLock::new(100); in write_shared_drop() 104 let rwlock = RwLock::new(100); in write_read_shared_pending() 122 let rwlock = RwLock::new(100); in write_read_shared_drop_pending() [all …]
|
/external/rust/crates/spin/src/ |
D | rw_lock.rs | 64 pub struct RwLock<T: ?Sized> { struct 78 inner: &'a RwLock<T>, argument 86 inner: &'a RwLock<T>, 99 inner: &'a RwLock<T>, 104 unsafe impl<T: ?Sized + Send> Send for RwLock<T> {} implementation 105 unsafe impl<T: ?Sized + Send + Sync> Sync for RwLock<T> {} implementation 107 impl<T> RwLock<T> { impl 124 pub const fn new(user_data: T) -> RwLock<T> { in new() 125 RwLock { in new() 136 let RwLock { data, .. } = self; in into_inner() localVariable [all …]
|
D | lib.rs | 74 pub use rw_lock::{RwLock, RwLockReadGuard, RwLockWriteGuard, RwLockUpgradableGuard}; 86 pub type RwLock<T> = lock_api::RwLock<crate::RwLock<()>, T>; typedef 89 pub type RwLockReadGuard<'a, T> = lock_api::RwLockReadGuard<'a, crate::RwLock<()>, T>; 92 pub type RwLockWriteGuard<'a, T> = lock_api::RwLockWriteGuard<'a, crate::RwLock<()>, T>; 96 lock_api::RwLockUpgradableReadGuard<'a, crate::RwLock<()>, T>;
|
/external/rust/crates/tokio/src/sync/ |
D | rwlock.rs | 88 pub struct RwLock<T: ?Sized> { struct 108 check_send::<RwLock<u32>>(); in bounds() argument 109 check_sync::<RwLock<u32>>(); in bounds() 110 check_unpin::<RwLock<u32>>(); in bounds() 136 let rwlock = Arc::new(RwLock::new(0)); in bounds() 146 unsafe impl<T> Send for RwLock<T> where T: ?Sized + Send {} implementation 147 unsafe impl<T> Sync for RwLock<T> where T: ?Sized + Send + Sync {} implementation 190 impl<T: ?Sized> RwLock<T> { impl 200 pub fn new(value: T) -> RwLock<T> in new() 204 RwLock { in new() [all …]
|
D | watch.rs | 60 use crate::loom::sync::{Arc, RwLock, RwLockReadGuard}; 101 value: RwLock<T>, 186 value: RwLock::new(init), in channel()
|
/external/rust/crates/tokio/src/loom/std/ |
D | parking_lot.rs | 17 pub(crate) struct RwLock<T>(parking_lot::RwLock<T>); struct 55 impl<T> RwLock<T> { implementation 56 pub(crate) fn new(t: T) -> RwLock<T> { in new() 57 RwLock(parking_lot::RwLock::new(t)) in new()
|
D | mod.rs | 59 Condvar, Mutex, MutexGuard, RwLock, RwLockReadGuard, WaitTimeoutResult, 64 pub(crate) use std::sync::{Condvar, MutexGuard, RwLock, RwLockReadGuard, WaitTimeoutResult};
|
/external/rust/crates/parking_lot/tests/ |
D | issue_203.rs | 1 use parking_lot::RwLock; 4 struct Bar(RwLock<()>); 13 static B: Bar = Bar(RwLock::new(())); 21 let a = RwLock::new(()); in main()
|
/external/rust/crates/lock_api/src/ |
D | rwlock.rs | 311 pub struct RwLock<R, T: ?Sized> { struct 318 impl<R, T> Serialize for RwLock<R, T> argument 332 impl<'de, R, T> Deserialize<'de> for RwLock<R, T> implementation 341 Deserialize::deserialize(deserializer).map(RwLock::new) in deserialize() 345 unsafe impl<R: RawRwLock + Send, T: ?Sized + Send> Send for RwLock<R, T> {} implementation 346 unsafe impl<R: RawRwLock + Sync, T: ?Sized + Send + Sync> Sync for RwLock<R, T> {} implementation 348 impl<R: RawRwLock, T> RwLock<R, T> { impl 352 pub const fn new(val: T) -> RwLock<R, T> { in new() 353 RwLock { in new() 362 pub fn new(val: T) -> RwLock<R, T> { in new() [all …]
|
/external/rust/crates/parking_lot/ |
D | README.md | 13 This library provides implementations of `Mutex`, `RwLock`, `Condvar` and 21 contended from multiple threads. The numbers for `RwLock` vary depending on 23 the standard library `RwLock`, and even up to 50x faster in some cases. 31 and `RwLock` only require 1 word of storage space. On the other hand the 49 6. `Condvar`, `RwLock` and `Once` work on Windows XP, unlike the standard 51 7. `RwLock` takes advantage of hardware lock elision on processors that 53 8. `RwLock` uses a task-fair locking policy, which avoids reader and writer 60 11. `RwLock` supports atomically downgrading a write lock into a read lock. 61 12. `Mutex` and `RwLock` allow raw unlocking without a RAII guard object. 62 13. `Mutex<()>` and `RwLock<()>` allow raw locking without a RAII guard [all …]
|
D | CHANGELOG.md | 4 - Fix incorrect memory ordering in `RwLock`. (#260) 31 - Add methods to construct `Mutex`, `RwLock`, etc in a `const` context. (#217) 94 - Fixed potential deadlock when upgrading a RwLock. 120 This release moves most of the code for type-safe `Mutex` and `RwLock` types 122 `no_std` and provides `Mutex` and `RwLock` type-safe wrapper types from a raw
|
/external/rust/crates/spin/ |
D | CHANGELOG.md | 30 - `RwLock`, `Mutex` and `Once` now implement `From<T>` 51 - `RwLock::reader_count` and `RwLock::writer_count`
|
/external/rust/crates/nix/test/ |
D | test.rs | 43 use std::sync::{Mutex, RwLock, RwLockWriteGuard}; 61 pub static ref CWD_LOCK: RwLock<()> = RwLock::new(());
|
/external/rust/crates/tokio/src/sync/tests/ |
D | loom_rwlock.rs | 12 let rwlock = Arc::new(RwLock::<u32>::new(0)); in concurrent_write() 43 let rwlock = Arc::new(RwLock::<u32>::new(0)); in concurrent_read_write() 88 let lock = Arc::new(RwLock::new(1)); in downgrade()
|
/external/rust/cxx/gen/build/src/ |
D | cfg.rs | 276 use std::sync::{PoisonError, RwLock}; 303 static ref CURRENT: RwLock<CurrentCfg> = RwLock::new(CurrentCfg::default());
|
/external/rust/crates/tokio/src/sync/rwlock/ |
D | owned_read_guard.rs | 1 use crate::sync::rwlock::RwLock; 19 pub(super) lock: ManuallyDrop<Arc<RwLock<T>>>,
|
D | owned_write_guard_mapped.rs | 1 use crate::sync::rwlock::RwLock; 20 pub(super) lock: ManuallyDrop<Arc<RwLock<T>>>,
|
D | owned_write_guard.rs | 3 use crate::sync::rwlock::RwLock; 21 pub(super) lock: ManuallyDrop<Arc<RwLock<T>>>,
|
/external/rust/crates/plotters/src/style/font/ |
D | ttf.rs | 5 use std::sync::{Arc, RwLock}; 41 static ref CACHE: RwLock<HashMap<String, FontResult<Font<'static>>>> = 42 RwLock::new(HashMap::new());
|
/external/rust/crates/spin/examples/ |
D | debug.rs | 11 let rwlock = spin::RwLock::new(42); in main()
|
/external/rust/crates/android_logger/src/ |
D | lib.rs | 75 use std::sync::RwLock; 108 config: RwLock<Config>, 115 config: RwLock::new(config), in new() 131 config: RwLock::new(Config::default()), in default()
|
/external/rust/crates/lock_api/ |
D | METADATA | 2 description: "Wrappers to create fully-featured Mutex and RwLock types. Compatible with no_std."
|
/external/rust/crates/rayon/ |
D | FAQ.md | 67 - `RefCell` -- replacement: `RwLock`, or perhaps `Mutex` 120 A similar problem can arise when converting `RefCell` to `RwLock`, but 137 this to parallel code with an `RwLock`, we do not: this is because 186 `RwLock`: the length would be out of sync and our indexing would fail 191 than downstream. Similarly, if we move to an `RwLock`, we'll find that 201 `AtomicUsize`, `RwLock`, `Mutex`, et al. in parallel code), then this
|