mirror of
https://github.com/doitsujin/dxvk.git
synced 2025-02-20 10:54:16 +01:00
[dxvk] Set low thread priority for pipeline compiler threads
This currently does not have any effect when using regular wine, but if it ever gets supported then these background jobs should have less of an influence on the game's performance when they kick in.
This commit is contained in:
parent
305168d2bb
commit
d49de734b7
@ -74,8 +74,10 @@ namespace dxvk {
|
||||
Logger::info(str::format("DXVK: Using ", numWorkers, " compiler threads"));
|
||||
|
||||
// Start the worker threads and the file writer
|
||||
for (uint32_t i = 0; i < numWorkers; i++)
|
||||
for (uint32_t i = 0; i < numWorkers; i++) {
|
||||
m_workerThreads.emplace_back([this] () { workerFunc(); });
|
||||
m_workerThreads[i].set_priority(ThreadPriority::Lowest);
|
||||
}
|
||||
|
||||
m_writerThread = dxvk::thread([this] () { writerFunc(); });
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user