Question

Im using aarch64-linux-gnu-objdump to disassemble part of a program for ARM v8. It works well for V8 64 bit instructions, but fails when the mode is changed to V7 instruction set(A32) - the code starts as V8 instruction set, switches to A32 ( AArch32 execution state) and than to T32 - thumb instruction set. how can I disassemble the A32 and T32 instructions? Do I need to break the code to parts when the mode switches, so that i have separate instruction mode blocks?

any help would be appreciated Weselfox

Was it helpful?

Solution

Unlike for A32 ("ARM") and T32 ("Thumb") within a 32-bit toolchain, there is no cross-instruction-set support between 32-bit and 64-bit ARM architectures. A64 really is a completely new instruction set.

Since interworking does not exist between the 64-bit and 32-bit states (you can only change 'width' on taking an exception) this is not an issue in normal usage. But when building a standalone image containing code for several exception levels I can imagine it will get a bit tedious.

You need to use aarch64-linux-gnu- for A64 portions and arm-linux-gnueabihf- for A32/T32 portions.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top