Multithreaded benchmark

This commit is contained in:
2026-01-30 17:35:58 +01:00
parent c9a7e3c835
commit 340b8c6f4d
2 changed files with 52 additions and 9 deletions
+14
View File
@@ -87,3 +87,17 @@ impl<T: Engine> Engine<BenchmarkResult> for Benchmark<T> {
self.0.executor()
}
}
impl std::fmt::Display for BenchmarkResult {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
write!(
f,
"- Average: {} ns\n\
- Min: {} ns\n\
- Max: {} ns\n\
- Total Render: {} ns\n\
- Total: {} ns",
self.average, self.min, self.max, self.total_render, self.total
)
}
}