Home
last modified time | relevance | path

Searched refs:UnsafeCell (Results 1 – 25 of 84) sorted by relevance

1234

/external/rust/crates/tokio/src/loom/std/
Dunsafe_cell.rs2 pub(crate) struct UnsafeCell<T>(std::cell::UnsafeCell<T>); struct
4 impl<T> UnsafeCell<T> { implementation
5 pub(crate) const fn new(data: T) -> UnsafeCell<T> { in new()
6 UnsafeCell(std::cell::UnsafeCell::new(data)) in new()
Datomic_u32.rs1 use std::cell::UnsafeCell;
7 inner: UnsafeCell<std::sync::atomic::AtomicU32>,
15 let inner = UnsafeCell::new(std::sync::atomic::AtomicU32::new(val)); in new()
Datomic_u8.rs1 use std::cell::UnsafeCell;
7 inner: UnsafeCell<std::sync::atomic::AtomicU8>,
15 let inner = UnsafeCell::new(std::sync::atomic::AtomicU8::new(val)); in new()
Datomic_u16.rs1 use std::cell::UnsafeCell;
7 inner: UnsafeCell<std::sync::atomic::AtomicU16>,
15 let inner = UnsafeCell::new(std::sync::atomic::AtomicU16::new(val)); in new()
Datomic_usize.rs1 use std::cell::UnsafeCell;
7 inner: UnsafeCell<std::sync::atomic::AtomicUsize>,
15 let inner = UnsafeCell::new(std::sync::atomic::AtomicUsize::new(val)); in new()
/external/rust/crates/tokio/src/runtime/task/
Dcore.rs12 use crate::loom::cell::UnsafeCell;
40 scheduler: UnsafeCell<Option<S>>,
44 stage: UnsafeCell<Stage<T>>,
64 pub(crate) owned: UnsafeCell<linked_list::Pointers<Header>>,
67 pub(crate) queue_next: UnsafeCell<Option<NonNull<Header>>>,
70 pub(super) stack_next: UnsafeCell<Option<NonNull<Header>>>,
82 pub(super) waker: UnsafeCell<Option<Waker>>,
99 owned: UnsafeCell::new(linked_list::Pointers::new()), in new()
100 queue_next: UnsafeCell::new(None), in new()
101 stack_next: UnsafeCell::new(None), in new()
[all …]
/external/rust/crates/crossbeam-epoch/src/
Dlib.rs77 pub(crate) use loom::cell::UnsafeCell;
115 pub(crate) struct UnsafeCell<T>(::core::cell::UnsafeCell<T>); struct
122 impl<T> UnsafeCell<T> { implementation
124 pub(crate) fn new(data: T) -> UnsafeCell<T> { in new()
125 UnsafeCell(::core::cell::UnsafeCell::new(data)) in new()
/external/rust/crates/rayon-core/src/
Djob.rs5 use std::cell::UnsafeCell;
74 func: UnsafeCell<Option<F>>,
75 result: UnsafeCell<JobResult<R>>,
87 func: UnsafeCell::new(Some(func)), in new()
88 result: UnsafeCell::new(JobResult::None), in new()
138 job: UnsafeCell<Option<BODY>>,
147 job: UnsafeCell::new(Some(func)), in new()
/external/rust/crates/futures-util/src/stream/futures_unordered/
Dtask.rs1 use core::cell::UnsafeCell;
12 pub(super) future: UnsafeCell<Option<Fut>>,
19 pub(super) prev_all: UnsafeCell<*const Task<Fut>>,
24 pub(super) len_all: UnsafeCell<usize>,
Dmod.rs11 use core::cell::UnsafeCell;
122 future: UnsafeCell::new(None), in new()
124 prev_all: UnsafeCell::new(ptr::null()), in new()
125 len_all: UnsafeCell::new(0), in new()
134 tail: UnsafeCell::new(stub_ptr), in new()
168 future: UnsafeCell::new(Some(future)), in push()
170 prev_all: UnsafeCell::new(ptr::null_mut()), in push()
171 len_all: UnsafeCell::new(0), in push()
/external/rust/crates/tokio/src/sync/mpsc/
Dblock.rs1 use crate::loom::cell::UnsafeCell;
27 observed_tail_position: UnsafeCell<usize>,
40 struct Values<T>([UnsafeCell<MaybeUninit<T>>; BLOCK_CAP]);
86 observed_tail_position: UnsafeCell::new(0), in new()
370 let p = vals.as_mut_ptr() as *mut UnsafeCell<MaybeUninit<T>>; in uninitialized()
373 .write(UnsafeCell::new(MaybeUninit::uninit())); in uninitialized()
382 type Output = UnsafeCell<MaybeUninit<T>>;
/external/rust/crates/rand/src/rngs/
Dthread.rs11 use core::cell::UnsafeCell;
63 rng: Rc<UnsafeCell<ReseedingRng<Core, OsRng>>>,
69 static THREAD_RNG_KEY: Rc<UnsafeCell<ReseedingRng<Core, OsRng>>> = {
75 Rc::new(UnsafeCell::new(rng))
/external/rust/crates/mio/src/sys/windows/
Doverlapped.rs3 use std::cell::UnsafeCell;
12 inner: UnsafeCell<miow::Overlapped>,
20 inner: UnsafeCell::new(miow::Overlapped::zero()), in new()
/external/rust/crates/futures-channel/src/
Dlock.rs7 use core::cell::UnsafeCell;
19 data: UnsafeCell<T>,
42 data: UnsafeCell::new(t), in new()
/external/rust/crates/tokio/src/util/
Dtry_lock.rs3 use std::cell::UnsafeCell;
10 data: UnsafeCell<T>,
27 data: UnsafeCell::new($data),
/external/rust/crates/futures-executor/src/
Dunpark_mutex.rs1 use std::cell::UnsafeCell;
15 inner: UnsafeCell<Option<D>>,
49 inner: UnsafeCell::new(None), in new()
/external/rust/crates/protobuf/src/
Dlazy_v2.rs4 use std::cell::UnsafeCell;
10 ptr: UnsafeCell<*const T>,
19 ptr: UnsafeCell::new(0 as *const T),
/external/rust/crates/futures-core/src/task/__internal/
Datomic_waker.rs1 use core::cell::UnsafeCell;
91 waker: UnsafeCell<Option<Waker>>,
207 waker: UnsafeCell::new(None), in new()
/external/crosvm/cros_async/src/sync/
Dwaiter.rs5 use std::cell::UnsafeCell;
23 prev: UnsafeCell<Option<NonNull<AtomicLink>>>,
24 next: UnsafeCell<Option<NonNull<AtomicLink>>>,
32 prev: UnsafeCell::new(None), in new()
33 next: UnsafeCell::new(None), in new()
/external/rust/crates/parking_lot_core/src/thread_parker/
Dunix.rs11 cell::{Cell, UnsafeCell},
30 mutex: UnsafeCell<libc::pthread_mutex_t>,
31 condvar: UnsafeCell<libc::pthread_cond_t>,
44 mutex: UnsafeCell::new(libc::PTHREAD_MUTEX_INITIALIZER), in new()
45 condvar: UnsafeCell::new(libc::PTHREAD_COND_INITIALIZER), in new()
/external/rust/crates/tokio/src/sync/
Donce_cell.rs2 use crate::loom::cell::UnsafeCell;
37 value: UnsafeCell<MaybeUninit<T>>,
85 value: UnsafeCell::new(MaybeUninit::uninit()), in new()
100 value: UnsafeCell::new(MaybeUninit::new(v)), in new_with()
114 value: UnsafeCell::new(MaybeUninit::uninit()), in const_new()
/external/rust/crates/futures-channel/src/mpsc/
Dqueue.rs47 use std::cell::UnsafeCell;
76 tail: UnsafeCell<*mut Node<T>>,
98 tail: UnsafeCell::new(stub), in new()
/external/rust/crates/crossbeam-channel/src/
Dutils.rs3 use std::cell::{Cell, UnsafeCell};
67 value: UnsafeCell<T>,
75 value: UnsafeCell::new(value), in new()
/external/rust/crates/once_cell/src/
Dimp_pl.rs2 cell::UnsafeCell,
15 value: UnsafeCell<Option<T>>,
34 value: UnsafeCell::new(None), in new()
/external/rust/crates/tokio/src/sync/task/
Datomic_waker.rs3 use crate::loom::cell::UnsafeCell;
27 waker: UnsafeCell<Option<Waker>>,
140 waker: UnsafeCell::new(None), in new()

1234