#[repr(C)]pub struct LaunchableMutPtr<T>(_);
Expand description
A pointer to mutable memory that can be dereferenced on the GPU.
LaunchableMutPtr
is intended to be passed as an argument to a CUDA kernel
function. For example, it can be passed to RUSTACuda’s launch!()
macro.
LaunchableMutPtr
must not be dereferenced on the CPU, as it may point to
device memory.
LaunchableMutPtr
is guaranteed to have an equivalent internal
representation to a raw pointer. Thus, it can be safely reinterpreted or
transmuted to *mut T
.
Implementations
sourceimpl<T: DeviceCopy> LaunchableMutPtr<T>
impl<T: DeviceCopy> LaunchableMutPtr<T>
sourcepub fn as_void(&self) -> LaunchableMutPtr<c_void>
pub fn as_void(&self) -> LaunchableMutPtr<c_void>
Cast internal pointer to void pointer.
sourcepub unsafe fn offset(self, count: isize) -> LaunchableMutPtr<T>
pub unsafe fn offset(self, count: isize) -> LaunchableMutPtr<T>
Calculates the offset from a pointer
Trait Implementations
sourceimpl<T> Clone for LaunchableMutPtr<T>
impl<T> Clone for LaunchableMutPtr<T>
Implement Clone trait to support cloning std::ffi::c_void
pointers.
c_void
doesn’t implement Clone, thus can’t be derived automatically.
sourceimpl<T: Debug> Debug for LaunchableMutPtr<T>
impl<T: Debug> Debug for LaunchableMutPtr<T>
sourceimpl<T> From<DevicePointer<T>> for LaunchableMutPtr<T>
impl<T> From<DevicePointer<T>> for LaunchableMutPtr<T>
sourceimpl<T: DeviceCopy> From<UnifiedPointer<T>> for LaunchableMutPtr<T>
impl<T: DeviceCopy> From<UnifiedPointer<T>> for LaunchableMutPtr<T>
sourceimpl<T: Hash> Hash for LaunchableMutPtr<T>
impl<T: Hash> Hash for LaunchableMutPtr<T>
sourceimpl<T: PartialEq> PartialEq<LaunchableMutPtr<T>> for LaunchableMutPtr<T>
impl<T: PartialEq> PartialEq<LaunchableMutPtr<T>> for LaunchableMutPtr<T>
sourcefn eq(&self, other: &LaunchableMutPtr<T>) -> bool
fn eq(&self, other: &LaunchableMutPtr<T>) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &LaunchableMutPtr<T>) -> bool
fn ne(&self, other: &LaunchableMutPtr<T>) -> bool
This method tests for !=
.
impl<T: Copy> Copy for LaunchableMutPtr<T>
impl<T: DeviceCopy> DeviceCopy for LaunchableMutPtr<T>
impl<T: Eq> Eq for LaunchableMutPtr<T>
impl<T> StructuralEq for LaunchableMutPtr<T>
impl<T> StructuralPartialEq for LaunchableMutPtr<T>
Auto Trait Implementations
impl<T> RefUnwindSafe for LaunchableMutPtr<T> where
T: RefUnwindSafe,
impl<T> !Send for LaunchableMutPtr<T>
impl<T> !Sync for LaunchableMutPtr<T>
impl<T> Unpin for LaunchableMutPtr<T>
impl<T> UnwindSafe for LaunchableMutPtr<T> where
T: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more