Disassembling RISC OS ARM code on other systems

by gerph
macOS ◆ xterm-256color ◆ fish 38 views

Disassembling ARM code on RISC OS is easy enough, but doing so on other systems is a little harder. The riscos-disassemble-python repository provides a disassembler which decodes in a similar style to RISC OS, and knows about RISC OS SWI naming. The repository was created out of the RISC OS Pyromaniac work, and is available for installation anywhere there is a Python. To install, use pip3 install riscos-disassemble. The command riscos-dumpi can be used to display the contents of binaries.

This recording shows the disassembly of two small test utilities - one which prints ‘hello world’ and one which reports the OS version. These demonstrate the decoding of some constants, strings and the SWI names.

The final disassembly is of the Hexen game binary, using the filtering to limit to only a single function. This also demonstrates the function name decoding for entry points and branches, constant values and bit decoding, and the recognition of a branch table.