How do I assemble assembly that is intended for armas?

Question

How do I assemble assembly that is intended for armas?

Answer

Assembly that is intended for use with ARM's RealView assembler has to be manually converted before it can be used with the GNU assembler (GAS) provided with Sourcery G++. While the two assemblers use generally similar syntax for individual instructions, all of the assembler directives are different.

The GNU comment character is @.

Here is a summary of some commonly used directives:

RealView GNU
AREA .section
CODE32 .code 32
EXPORT .global
EXTERN .extern
FIELD .equate
MAP .equate

The full syntax of the GNU directives is explained in the "Assembler Directives" section of the GNU assembler manual provided with Sourcery G++.


This entry was last updated on 10 March 2010.