euv_performance/suite/
struct.rs1use super::*;
2
3#[derive(Clone, Debug, Deserialize, Getter, New, PartialEq, Serialize)]
5pub struct BenchMetric {
6 pub(crate) name: String,
8 #[get(type(copy))]
10 pub(crate) iterations: usize,
11 #[get(type(copy))]
13 pub(crate) total_micros: u64,
14 #[get(type(copy))]
16 pub(crate) ns_per_op: f64,
17 #[get(type(copy))]
19 pub(crate) ops_per_sec: f64,
20 pub(crate) detail: String,
22 #[get(type(copy))]
24 #[new(skip)]
25 #[serde(default)]
26 pub(crate) alloc_count: u64,
27 #[get(type(copy))]
29 #[new(skip)]
30 #[serde(default)]
31 pub(crate) bytes_allocated: u64,
32 #[get(type(copy))]
34 #[new(skip)]
35 #[serde(default)]
36 pub(crate) allocs_per_op: f64,
37 #[get(type(copy))]
39 #[new(skip)]
40 #[serde(default)]
41 pub(crate) bytes_per_op: f64,
42}
43
44#[derive(Clone, Debug, Deserialize, Getter, New, PartialEq, Serialize)]
46pub struct BenchReport {
47 pub(crate) metrics: Vec<BenchMetric>,
49}
50
51#[derive(Clone, Copy, Debug)]
53pub(crate) struct BenchCase {
54 pub(crate) name: &'static str,
56 pub(crate) runner: fn() -> BenchMetric,
58}