Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
marc2332 committed Sep 25, 2023
1 parent e1997ec commit 8f9edbe
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions crates/torin/benches/bench.rs
Original file line number Diff line number Diff line change
Expand Up @@ -429,15 +429,16 @@ fn criterion_benchmark(c: &mut Criterion) {
),
);

const LEVELS: usize = 20;
const LEVELS: usize = 14;
const WIDE: usize = 2;

fn build_branch(mocked_dom: &mut TestingDOM, root: usize, level: usize) -> Vec<usize> {
if level == LEVELS {
return vec![];
}

let nodes = (0..=((level + 1) * 3))
.map(|i| i + ((level + 1) * 1000))
let nodes = (0..=WIDE)
.map(|i| i + ((level + 1) * 100) + (root * 10))
.into_iter()
.collect::<Vec<usize>>();
for id in nodes.iter() {
Expand Down Expand Up @@ -477,7 +478,7 @@ fn criterion_benchmark(c: &mut Criterion) {
DirectionMode::Vertical,
),
);
layout.invalidate(8013);
layout.invalidate(7008);
layout.find_best_root(&mut mocked_dom);
layout.measure(
0,
Expand Down

0 comments on commit 8f9edbe

Please sign in to comment.