mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-15 03:08:36 +12:00
rsx: Some shader compiler threads tuning
- Allow more threads for wide CPUs - Simplify 'auto' selection a bit
This commit is contained in:
parent
14358d5e84
commit
cab4c78b7b
4 changed files with 16 additions and 12 deletions
|
@ -94,15 +94,19 @@ namespace gl
|
|||
std::function<void(draw_context_t)> context_destroy_func,
|
||||
int num_worker_threads)
|
||||
{
|
||||
if (num_worker_threads == -1)
|
||||
if (num_worker_threads == 0)
|
||||
{
|
||||
// Select optimal number of compiler threads
|
||||
const auto hw_threads = std::thread::hardware_concurrency();
|
||||
if (hw_threads >= 12)
|
||||
if (hw_threads > 12)
|
||||
{
|
||||
num_worker_threads = 6;
|
||||
}
|
||||
else if (hw_threads > 8)
|
||||
{
|
||||
num_worker_threads = 4;
|
||||
}
|
||||
else if (hw_threads >= 8)
|
||||
else if (hw_threads == 8)
|
||||
{
|
||||
num_worker_threads = 2;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue