Skip to content

Commit

Permalink
[CPU] Use parallel_nt_static for MLAS threading (openvinotoolkit#19297)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangYiIntel authored Aug 22, 2023
1 parent 7df8d1c commit 7e72456
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugins/intel_cpu/src/mlas/thread_pool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ size_t OVMlasThreadPool::DegreeOfParallelism() {
}

void OVMlasThreadPool::TrySimpleParallelFor(const std::ptrdiff_t total, const std::function<void(std::ptrdiff_t)>& fn) {
ov::parallel_nt(threadNum, [&](const size_t ithr, const size_t nthr) {
ov::parallel_nt_static(threadNum, [&](const size_t ithr, const size_t nthr) {
std::ptrdiff_t start = 0, end = 0;
ov::splitter(total, nthr, ithr, start, end);
for (std::ptrdiff_t i = start; i < end; i++) {
Expand Down

0 comments on commit 7e72456

Please sign in to comment.