Skip to content

Commit

Permalink
CPU/Recompiler: Eliminate redundant speculative reg read
Browse files Browse the repository at this point in the history
  • Loading branch information
stenzek committed Jul 14, 2024
1 parent 59a2309 commit 640ed4a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/core/cpu_recompiler_code_generator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3049,8 +3049,7 @@ bool CodeGenerator::Compile_cop2(Instruction instruction, const CodeCache::Instr
if (g_settings.gpu_pgxp_enable)
EmitFunctionCall(nullptr, PGXP::CPU_SWC2, Value::FromConstantU32(instruction.bits), address, value);

SpeculativeValue spec_base = SpeculativeReadReg(instruction.i.rs);
if (spec_base)
if (spec_address)
SpeculativeWriteMemory(*spec_address, std::nullopt);
}

Expand Down

0 comments on commit 640ed4a

Please sign in to comment.