pub struct GpuResource {
pub ptr: hipDeviceptr_t,
pub binding: hipDeviceptr_t,
pub size: u64,
}Expand description
A GPU memory resource allocated for HIP using GpuStorage.
Fields§
§ptr: hipDeviceptr_tThe GPU memory pointer.
binding: hipDeviceptr_tThe HIP binding pointer.
size: u64The size of the resource.
Implementations§
Source§impl GpuResource
impl GpuResource
Sourcepub fn new(ptr: hipDeviceptr_t, binding: hipDeviceptr_t, size: u64) -> Self
pub fn new(ptr: hipDeviceptr_t, binding: hipDeviceptr_t, size: u64) -> Self
Constructs a new GpuResource.
Trait Implementations§
Source§impl Debug for GpuResource
impl Debug for GpuResource
impl Send for GpuResource
Auto Trait Implementations§
impl Freeze for GpuResource
impl RefUnwindSafe for GpuResource
impl !Sync for GpuResource
impl Unpin for GpuResource
impl UnwindSafe for GpuResource
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more