mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-04 15:53:45 +08:00
fix: use condition variables instead of busy waits in worker threads
Resolves: NEO-16085, GSD-11678, HSD-14025819208 Signed-off-by: Igor Venevtsev <igor.venevtsev@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
49293fcac6
commit
452475a0b9
@@ -8,13 +8,13 @@
|
||||
#include "shared/source/direct_submission/direct_submission_controller.h"
|
||||
#include "shared/source/helpers/sleep.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <chrono>
|
||||
namespace NEO {
|
||||
bool DirectSubmissionController::sleep(std::unique_lock<std::mutex> &lock) {
|
||||
return NEO::waitOnConditionWithPredicate(condVar, lock, getSleepValue(), [&] { return !pagingFenceRequests.empty(); });
|
||||
return NEO::waitOnConditionWithPredicate(syncData.condVar, lock, getSleepValue(), [&] { return !pagingFenceRequests.empty(); });
|
||||
}
|
||||
|
||||
void DirectSubmissionController::overrideDirectSubmissionTimeouts(const ProductHelper &productHelper) {
|
||||
}
|
||||
|
||||
} // namespace NEO
|
||||
} // namespace NEO
|
||||
|
||||
Reference in New Issue
Block a user