mirror of
https://github.com/dingusdev/dingusppc.git
synced 2024-12-25 18:29:49 +00:00
poweropcodes: Fix nabs.
Calculate overflow first before calculating condition codes because the overflow condition is copied from XER.
This commit is contained in:
parent
1e57ac408a
commit
d897acfd3c
@ -332,10 +332,10 @@ void dppc_interpreter::power_nabs() {
|
||||
ppc_grab_regsda(ppc_cur_instruction);
|
||||
uint32_t ppc_result_d = (int32_t(ppc_result_a) < 0) ? ppc_result_a : -ppc_result_a;
|
||||
|
||||
if (rec)
|
||||
ppc_changecrf0(ppc_result_d);
|
||||
if (ov)
|
||||
ppc_state.spr[SPR::XER] &= ~XER::OV;
|
||||
if (rec)
|
||||
ppc_changecrf0(ppc_result_d);
|
||||
|
||||
ppc_store_iresult_reg(reg_d, ppc_result_d);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user