pub struct LoadTable { /* private fields */ }Expand description
The load table containing entries for all actors.
This lives in mapped memory so both host and GPU can access it.
Implementations§
Source§impl LoadTable
impl LoadTable
Sourcepub fn get_mut(&mut self, actor_id: u32) -> Option<&mut LoadEntry>
pub fn get_mut(&mut self, actor_id: u32) -> Option<&mut LoadEntry>
Get a mutable reference to an entry.
Sourcepub fn most_loaded(&self) -> Option<(u32, &LoadEntry)>
pub fn most_loaded(&self) -> Option<(u32, &LoadEntry)>
Find the most loaded actor (best target for work stealing FROM).
Sourcepub fn least_loaded(&self) -> Option<(u32, &LoadEntry)>
pub fn least_loaded(&self) -> Option<(u32, &LoadEntry)>
Find the least loaded actor (best target for work sharing TO).
Sourcepub fn imbalance_ratio(&self) -> f64
pub fn imbalance_ratio(&self) -> f64
Compute load imbalance ratio (max_depth / min_depth). Returns 1.0 for perfectly balanced, higher = more imbalanced.
Sourcepub fn compute_steal_plan(&self, config: &SchedulerConfig) -> Vec<StealOp>
pub fn compute_steal_plan(&self, config: &SchedulerConfig) -> Vec<StealOp>
Compute a work stealing plan: which actors should steal from which.
Returns a list of (thief_id, victim_id, count) tuples.
For RoundRobin and Priority strategies, this returns an empty plan
since those use a central work queue rather than peer-to-peer stealing.
Auto Trait Implementations§
impl Freeze for LoadTable
impl RefUnwindSafe for LoadTable
impl Send for LoadTable
impl Sync for LoadTable
impl Unpin for LoadTable
impl UnsafeUnpin for LoadTable
impl UnwindSafe for LoadTable
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
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<F, W, T, D> Deserialize<With<T, W>, D> for F
impl<F, W, T, D> Deserialize<With<T, W>, D> for F
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> LayoutRaw for T
impl<T> LayoutRaw for T
Source§fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>
Gets the layout of the type.