Cromulent
Posts: 15
Joined: Tue Jun 19, 2018 1:40 pm

32 bit and 64 bit ARM Disassembler

Sun Jul 08, 2018 11:12 am

First of all, I know about objdump and IDA Pro. The problem with objdump is it is not the friendliest of tools on earth to use and IDA Pro costs thousands of dollars to buy so is way outside of my budget.

I was wondering if there was something in the middle somewhere. A tool that offered a GUI and maybe converting raw assembly language into a pseudo-code much as IDA Pro does?

I'd like to be able to see how various things are put together that don't come with source code so disassembling them is my only real option.

Edit: It would be nice if I could run it on my main desktop computer and just SSH into the Raspberry Pi as I have two of them (one 32 bit and one 64 bit).

LizardLad_1
Posts: 126
Joined: Sat Jan 13, 2018 12:29 am

Re: 32 bit and 64 bit ARM Disassembler

Sun Jul 08, 2018 11:31 am

Have you tried https://onlinedisassembler.com/odaweb/ I realise it doesn't convert it into pseudo code and it only disassembles it into asm but it seems like the closest thing to what you want apart from objdump. It does have agraph to display the flow of the program though.

Cromulent
Posts: 15
Joined: Tue Jun 19, 2018 1:40 pm

Re: 32 bit and 64 bit ARM Disassembler

Sun Jul 08, 2018 11:56 am

LizardLad_1 wrote:
Sun Jul 08, 2018 11:31 am
Have you tried https://onlinedisassembler.com/odaweb/ I realise it doesn't convert it into pseudo code and it only disassembles it into asm but it seems like the closest thing to what you want apart from objdump. It does have agraph to display the flow of the program though.
That looks like a cool tool. Thanks for that.

I'll have to improve my ARM assembly knowledge a bit though. Time to read the official ARM instruction set overview.

bzt
Posts: 161
Joined: Sat Oct 14, 2017 9:57 pm

Re: 32 bit and 64 bit ARM Disassembler

Wed Jul 11, 2018 4:26 pm

Well, if you don't mind a little homework, I can offer a really simple disassembler library in C for AArch64. MIT licensed, and you can use it from any app you like (but you have to write the GUI yourself). This library disassembles one instruction at a time, and returns a pointer to the next instruction (which is always +4 with AArch64).

Code: Select all

char asmstr[64];
// call this repeatedly
codeptr = disasm(codeptr, &asmstr);
It's very small, less than 80k, yet supports the full ARMv8.2 instruction set. It can also return a JSON string with more details on the instruction if you compile it in analysis mode.

Cheers,
bzt

Return to “Bare metal, Assembly language”

Who is online

Users browsing this forum: No registered users and 4 guests