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

Expand m68040 support #10

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open

Conversation

viclw
Copy link

@viclw viclw commented Feb 12, 2021

At a high-level these changes add M68040 floating point disassembly (not lifting) support. This doesn't add support for every floating point instruction, but just the instructions contained in my target binaries.

Support for disassembling the 'cinv' and 'pflush' instructions was also added.

Unfortunately, the changes are more intrusive than I would have liked. To be able to share the existing logic in 'decode_effective_address()' with the floating point logic, I had to modify its API to take a size in bytes. But on the positive side that code can now be shared (and not duplicated).

I also updated the IL methods of the new floating point operand classes, but it is not tested. It won't be needed until proper support for lifting of the floating point instructions is added. Every attempt has been made, though, to test the new disassembly logic. The accuracy of the disassembly was verified using GCC's m68k cross-toolchain.

A few other considerations I'd like to point out:

  • These changes were only tested using M68040 binaries. I did not regression test the other architecture variants
  • I did not test the changes for strict Python 2 compatibility
  • If/when the plug-in changes are accepted, should consider updating 'plugin.json' as required

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.

1 participant