From: Jacob Lifshay Date: Fri, 4 Sep 2020 03:24:09 +0000 (-0700) Subject: fix addex X-Git-Tag: v0.2.0~17 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6e7d5f83b315d05f5a9362f54368b005376775f7;p=power-instruction-analyzer.git fix addex --- diff --git a/src/instr_models.rs b/src/instr_models.rs index 9ee3996..4de58fe 100644 --- a/src/instr_models.rs +++ b/src/instr_models.rs @@ -274,14 +274,12 @@ pub fn addex(inputs: InstructionInput) -> InstructionResult { let carry32 = u32::try_from(result32_u128).is_err(); Ok(InstructionOutput { rt: Some(result), - overflow: Some(propagate_so( - OverflowFlags { - so, - ov: carry, - ov32: carry32, - }, - inputs, - )?), + // doesn't change `so` on purpose + overflow: Some(OverflowFlags { + so, + ov: carry, + ov32: carry32, + }), ..InstructionOutput::default() }) }