use less threads on cache
By using one thread per logical CPU thread, we seemed to completely saturate the CPU which would kill the performance of the main/GUI thread (despite the other threads being low priority). We now use half of the logical threads, which still sees good CPU usage and minimal performance impact while allowing the main thread to respond to user actions.
This commit is contained in:
@@ -20,7 +20,7 @@ bool RenderBackend::Init()
|
||||
return true;
|
||||
}
|
||||
|
||||
threads_.resize(QThread::idealThreadCount());
|
||||
threads_.resize(qMax(1, QThread::idealThreadCount() / 2));
|
||||
|
||||
for (int i=0;i<threads_.size();i++) {
|
||||
QThread* thread = new QThread(this);
|
||||
|
||||
Reference in New Issue
Block a user