Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 2 additions & 29 deletions rpcs3/Emu/Cell/SPULLVMRecompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1577,11 +1577,10 @@ class spu_llvm_recompiler : public spu_recompiler_base, public cpu_translator
return add_loc->compiled;
}

bool add_to_file = false;

if (auto& cache = g_fxo->get<spu_cache>(); cache && g_cfg.core.spu_cache && !add_loc->cached.exchange(1))
{
add_to_file = true;
cache.add(func);
spu_log.success("New SPU block detected (size=%u)", func_size);
}

{
Expand Down Expand Up @@ -2815,14 +2814,6 @@ class spu_llvm_recompiler : public spu_recompiler_base, public cpu_translator
fs::write_file(m_spurt->get_cache_path() + "spu-ir.log", fs::write + fs::append, llvm_log);
}

if (auto& cache = g_fxo->get<spu_cache>())
{
if (add_to_file)
{
cache.add(func);
}
}

fmt::throw_exception("Compilation failed");
}

Expand Down Expand Up @@ -2851,14 +2842,6 @@ class spu_llvm_recompiler : public spu_recompiler_base, public cpu_translator
// Rebuild trampoline if necessary
if (!m_spurt->rebuild_ubertrampoline(func.data[0]))
{
if (auto& cache = g_fxo->get<spu_cache>())
{
if (add_to_file)
{
cache.add(func);
}
}

return nullptr;
}

Expand All @@ -2879,16 +2862,6 @@ class spu_llvm_recompiler : public spu_recompiler_base, public cpu_translator
asm("DSB ISH");
#endif

if (auto& cache = g_fxo->get<spu_cache>())
{
if (add_to_file)
{
cache.add(func);
}

spu_log.success("New SPU block compiled successfully (size=%u)", func_size);
}

return fn;
}

Expand Down
Loading