3.8.3. Disassembly Modes

The CADI Disassembler interface supports different disassembly modes. Such modes might, for example, represent different instruction sets that are supported by a processing unit. A simple example is an ARM core which supports the ARM instruction set and the Thumb instruction set.

A debugger can use the GetModeCount() and the GetModeNames() methods to determine which modes are supported. Typically all CADI Disassembler implementations support at least one mode which can be considered as a don’t care mode. The ID for this mode is reserved as 0. The mode ID enables the instruction at the requested address to be disassembled with consideration of the instruction set and the current mode for the processing unit.


Querying the disassembly for a specific memory address with a non-zero mode ID results in the interpretation of the memory contents according to the instruction set for that mode. The disassembler proceeds even if it is an instruction of a different set. This might lead to an incorrect, but apparently successful, disassembly if the memory contents accidentally represents a valid instruction in the ISA for the other mode.

Copyright © 2008-2010 ARM Limited. All rights reserved.ARM DUI 0444F