pub enum SyncMode {
PreCpuToDevice,
PostCpuToDevice,
PreDeviceToCpu,
PostDeviceToCpu,
FullCoherence,
}
Expand description
Mode of syncing to apply when calling sync()
. These sync calls are unnecessary by default, and
should only be used with utmost care.
Variants§
PreCpuToDevice
Ensures coherence for the host to write to the device, ensuring that the memory is coherent from the perspective of the CPU before the host writes.
PostCpuToDevice
Ensures coherence for the host to write to the device, ensuring that the memory is coherent after the write.
PreDeviceToCpu
Ensures coherence for the device to write to the host, ensuring that the memory is coherent before the device performs an operation.
PostDeviceToCpu
Ensures coherence for the device to write to the host, ensuring that the memory is coherent after the device performs an operation.
FullCoherence
Ensures that memory is fully coherent.
Trait Implementations§
source§impl Ord for SyncMode
impl Ord for SyncMode
source§impl PartialOrd for SyncMode
impl PartialOrd for SyncMode
impl Copy for SyncMode
impl Eq for SyncMode
impl StructuralPartialEq for SyncMode
Auto Trait Implementations§
impl DeviceSync for SyncMode
impl Freeze for SyncMode
impl ObjSafe for SyncMode
impl RefUnwindSafe for SyncMode
impl Send for SyncMode
impl Sync for SyncMode
impl Unpin for SyncMode
impl UnwindSafe for SyncMode
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.