Skip to content

Commit

Permalink
Format.
Browse files Browse the repository at this point in the history
  • Loading branch information
Narsil committed Jul 26, 2023
1 parent 76ea6bd commit b11ea6f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
15 changes: 11 additions & 4 deletions gemm-common/src/gemm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -354,10 +354,17 @@ pub unsafe fn gemm_basic_generic<
max_threads
};
let total_work = m * n_chunk * k_chunk;
let n_threads = if total_work > threading_threshold{
std::cmp::max(1, std::cmp::min(max_threads, (total_work - threading_threshold + 1) / threading_threshold))
}else{1}
;
let n_threads = if total_work > threading_threshold {
std::cmp::max(
1,
std::cmp::min(
max_threads,
(total_work - threading_threshold + 1) / threading_threshold,
),
)
} else {
1
};
n_threads
}
};
Expand Down
2 changes: 0 additions & 2 deletions gemm/benches/bench.rs
Original file line number Diff line number Diff line change
Expand Up @@ -357,9 +357,7 @@ pub fn criterion_benchmark_parallelism(c: &mut Criterion) {
}
}
}

}

}

criterion_group!(
Expand Down

0 comments on commit b11ea6f

Please sign in to comment.