Skip to content

Commit

Permalink
oops
Browse files Browse the repository at this point in the history
  • Loading branch information
hoholee12 committed Jul 23, 2023
1 parent 8163aaf commit e5c1fea
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 18 deletions.
2 changes: 2 additions & 0 deletions rpcs3/Emu/CPU/CPUThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,8 @@ namespace cpu_counter

void cpu_thread::operator()()
{
thread_ctrl::scoped_priority stock_prio(0);

const auto old_prefix = g_tls_log_prefix;

g_tls_this_thread = this;
Expand Down
10 changes: 2 additions & 8 deletions rpcs3/Emu/Cell/PPUThread.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3413,10 +3413,8 @@ extern void ppu_precompile(std::vector<std::string>& dir_queue, std::vector<ppu_
#ifdef __APPLE__
pthread_jit_write_protect_np(false);
#endif
#ifdef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif

for (usz func_i = fnext++; func_i < file_queue.size(); func_i = fnext++, g_progr_fdone++)
{
Expand Down Expand Up @@ -3530,10 +3528,8 @@ extern void ppu_precompile(std::vector<std::string>& dir_queue, std::vector<ppu_
#ifdef __APPLE__
pthread_jit_write_protect_np(false);
#endif
#ifdef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif

auto slice = possible_exec_file_paths.pop_all();

Expand Down Expand Up @@ -4243,10 +4239,8 @@ bool ppu_initialize(const ppu_module& info, bool check_only)

named_thread_group threads(fmt::format("PPUW.%u.", ++g_fxo->get<thread_index_allocator>().index), thread_count, [&]()
{
#ifdef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);

#ifdef __APPLE__
pthread_jit_write_protect_np(false);
Expand Down
2 changes: 0 additions & 2 deletions rpcs3/Emu/Cell/SPURecompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -660,10 +660,8 @@ void spu_cache::initialize()
#ifdef __APPLE__
pthread_jit_write_protect_np(false);
#endif
#ifdef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif

// Initialize compiler instances for parallel compilation
std::unique_ptr<spu_recompiler_base> compiler;
Expand Down
6 changes: 2 additions & 4 deletions rpcs3/Emu/RSX/GL/GLPipelineCompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -38,10 +38,8 @@ namespace gl

void pipe_compiler::operator()()
{
#ifndef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif
thread_ctrl::scoped_priority stock_prio(0);

while (thread_ctrl::state() != thread_state::aborting)
{
for (auto&& job : m_work_queue.pop_all())
Expand Down
6 changes: 2 additions & 4 deletions rpcs3/Emu/RSX/VK/VKPipelineCompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,8 @@ namespace vk

void pipe_compiler::operator()()
{
#ifndef _WIN32
// Set low priority
thread_ctrl::scoped_priority low_prio(-1);
#endif
thread_ctrl::scoped_priority stock_prio(0);

while (thread_ctrl::state() != thread_state::aborting)
{
for (auto&& job : m_work_queue.pop_all())
Expand Down

0 comments on commit e5c1fea

Please sign in to comment.