fix for v-flag for ASH shifts of < 32

This commit is contained in:
folkert van heusden 2024-03-29 11:26:04 +01:00
parent 43134223ae
commit 1605d1a9a7
Signed by untrusted user who does not match committer: folkert
GPG key ID: 6B6455EDFEED3BD1

View file

@ -697,7 +697,7 @@ bool cpu::additional_double_operand_instructions(const uint16_t instr)
else if (shift < 32) {
setPSW_c((R << (shift - 16)) & 1);
R = 0;
setPSW_v(!!oldR);
setPSW_v(SIGN(oldR, wm_word) != SIGN(R, wm_word));
}
else if (shift == 32) {
R = -sign;