MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / SUB

Function SUB

pcsx2/R5900OpcodeImpl.cpp:347–353  ·  view source on GitHub ↗

Rd = Rs - Rt (Exception on Integer Overflow)

Source from the content-addressed store, hash-verified

345
346// Rd = Rs - Rt (Exception on Integer Overflow)
347void SUB()
348{
349 s64 result;
350 bool overflow = _add32_Overflow( cpuRegs.GPR.r[_Rs_].SD[0], -cpuRegs.GPR.r[_Rt_].SD[0], result );
351 if (overflow || !_Rd_) return;
352 cpuRegs.GPR.r[_Rd_].SD[0] = result;
353}
354
355// Rd = Rs - Rt (Exception on Integer Overflow)
356void DSUB()

Callers

nothing calls this directly

Calls 1

_add32_OverflowFunction · 0.85

Tested by

no test coverage detected