|
|
|
@ -139,6 +139,7 @@ void Scheduler::WorkerThread(std::stop_token stop_token) {
|
|
|
|
|
Common::SetCurrentThreadName("VulkanWorker");
|
|
|
|
|
do {
|
|
|
|
|
std::unique_ptr<CommandChunk> work;
|
|
|
|
|
bool has_submit{false};
|
|
|
|
|
{
|
|
|
|
|
std::unique_lock lock{work_mutex};
|
|
|
|
|
if (work_queue.empty()) {
|
|
|
|
@ -150,9 +151,10 @@ void Scheduler::WorkerThread(std::stop_token stop_token) {
|
|
|
|
|
}
|
|
|
|
|
work = std::move(work_queue.front());
|
|
|
|
|
work_queue.pop();
|
|
|
|
|
}
|
|
|
|
|
const bool has_submit = work->HasSubmit();
|
|
|
|
|
|
|
|
|
|
has_submit = work->HasSubmit();
|
|
|
|
|
work->ExecuteAll(current_cmdbuf);
|
|
|
|
|
}
|
|
|
|
|
if (has_submit) {
|
|
|
|
|
AllocateWorkerCommandBuffer();
|
|
|
|
|
}
|
|
|
|
|