Small stuff
This commit is contained in:
@@ -7,7 +7,7 @@ pub fn main() {
|
||||
|
||||
let (tx, rx) = mpsc::channel();
|
||||
|
||||
let max_threads = 128;
|
||||
let max_threads = 32;
|
||||
let mut handles = vec![];
|
||||
|
||||
for chunk in (0..500).collect::<Vec<_>>().chunks(max_threads) {
|
||||
@@ -46,4 +46,5 @@ pub fn main() {
|
||||
for (items, bench) in results {
|
||||
println!("Results for {items} items:\n{bench}");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -33,12 +33,11 @@ impl<T: Engine> Engine<BenchmarkResult> for Benchmark<T> {
|
||||
|
||||
let start = Instant::now();
|
||||
|
||||
for _ in 0..100 {
|
||||
for _ in 0..40 {
|
||||
let start = Instant::now();
|
||||
self.render(&cx);
|
||||
let end = Instant::now();
|
||||
times.push(end.duration_since(start).as_micros());
|
||||
self.0.render_delay();
|
||||
}
|
||||
|
||||
let end = Instant::now();
|
||||
|
||||
Reference in New Issue
Block a user