pub struct HardwareProfile {
pub peak_gflops: f64,
pub memory_bandwidth_gbs: f64,
pub name: String,
}Expand description
Hardware profile for roofline analysis.
Fields§
§peak_gflops: f64Peak throughput in GFLOPS.
memory_bandwidth_gbs: f64Memory bandwidth in GB/s.
name: StringHuman-readable profile name.
Implementations§
Source§impl HardwareProfile
impl HardwareProfile
Sourcepub fn ridge_point(&self) -> f64
pub fn ridge_point(&self) -> f64
Ridge point: arithmetic intensity where compute and memory are balanced.
Sourcepub fn predict_latency_secs(&self, cost: &OpCost) -> f64
pub fn predict_latency_secs(&self, cost: &OpCost) -> f64
Predict execution latency in seconds using the roofline model.
latency = max(flops / peak_flops_per_sec, bytes / bandwidth_per_sec)
Sourcepub fn bottleneck(&self, cost: &OpCost) -> Bottleneck
pub fn bottleneck(&self, cost: &OpCost) -> Bottleneck
Determine the bottleneck for a given operation cost.
Trait Implementations§
Source§impl Clone for HardwareProfile
impl Clone for HardwareProfile
Source§fn clone(&self) -> HardwareProfile
fn clone(&self) -> HardwareProfile
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for HardwareProfile
impl RefUnwindSafe for HardwareProfile
impl Send for HardwareProfile
impl Sync for HardwareProfile
impl Unpin for HardwareProfile
impl UnsafeUnpin for HardwareProfile
impl UnwindSafe for HardwareProfile
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