use super::*;
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct ShardEvidence {
pub(super) field: WorkloadField,
pub(super) global: usize,
pub(super) per_rank: [usize; 2],
}
impl ShardEvidence {
#[must_use]
pub const fn field(self) -> WorkloadField {
self.field
}
#[must_use]
pub const fn global(self) -> usize {
self.global
}
#[must_use]
pub const fn per_rank(self) -> [usize; 2] {
self.per_rank
}
}
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub enum PlanningCollectiveKind {
AllReduce,
AllGather,
ReduceScatter,
SendRecv,
}
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct CommunicationEvidence {
pub(super) kind: PlanningCollectiveKind,
pub(super) launches: usize,
pub(super) bytes: usize,
}
impl CommunicationEvidence {
#[must_use]
pub const fn kind(self) -> PlanningCollectiveKind {
self.kind
}
#[must_use]
pub const fn launches(self) -> usize {
self.launches
}
#[must_use]
pub const fn bytes(self) -> usize {
self.bytes
}
}