Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keep the V flag on the 68030 #127

Merged
merged 1 commit into from
Jan 9, 2018
Merged

Keep the V flag on the 68030 #127

merged 1 commit into from
Jan 9, 2018

Conversation

mikrosk
Copy link
Contributor

@mikrosk mikrosk commented Jan 9, 2018

While doing some experiments with BCD arithmetic corner cases I have noticed that the V flag isn't handled properly on the 030 -- it shouldn't be involved in the calculation (contrary to the 68000). I can't test how it performs on the 020, most likely the same, i.e. xBCD_KEEPS_V_FLAG should be changed to 2 after confirmation.

Tested & implemented on Hatari's cpu/gencpu.c and backported by hand, I hope I didn't miss anything. Tested on all possible combinations of Z, C and both byte operands (2 * 2 * 256 * 256 tests).

@tonioni tonioni merged commit 83fcc48 into tonioni:master Jan 9, 2018
@mikrosk mikrosk deleted the bcd-fixes branch January 9, 2018 21:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants