pub enum RudaCountSelection {
Exact(RudaCount),
Approx(RudaCount, u32),
}Expand description
Defines how to select ruda count based on the number of rudas required.
Variants§
Exact(RudaCount)
If the number of rudas is the same as required.
Approx(RudaCount, u32)
If the number of rudas isn’t the same as required.
This can happen based on the hardware limit, requiring the kernel to perform OOB checks.
Implementations§
Source§impl RudaCountSelection
impl RudaCountSelection
Sourcepub fn new<R>(client: &ComputeClient<R>, num_rudas: u32) -> RudaCountSelectionwhere
R: Runtime,
pub fn new<R>(client: &ComputeClient<R>, num_rudas: u32) -> RudaCountSelectionwhere
R: Runtime,
Creates a RudaCount while respecting the hardware limits.
Sourcepub fn ruda_count(self) -> RudaCount
pub fn ruda_count(self) -> RudaCount
Converts into RudaCount.
Trait Implementations§
Source§impl From<RudaCountSelection> for RudaCount
impl From<RudaCountSelection> for RudaCount
Source§fn from(value: RudaCountSelection) -> RudaCount
fn from(value: RudaCountSelection) -> RudaCount
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for RudaCountSelection
impl !UnwindSafe for RudaCountSelection
impl Freeze for RudaCountSelection
impl Send for RudaCountSelection
impl Sync for RudaCountSelection
impl Unpin for RudaCountSelection
impl UnsafeUnpin for RudaCountSelection
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