Keil Logo

Directives

The AARM Assembler provides a number of directives you may use to control source file assembly. Directives are composed of one or more letters or digits and, unless otherwise specified, may be specified after the filename on the command line or within the source file when preceded by a dollar sign ('$'). For example:

AARM SAMPLE.S SYMBOLS DEBUG

or

$SYMBOLS DEBUG

or

$SYMBOLS
$DEBUG

The source file to assemble is SAMPLE.AS and SYMBOLS and DEBUG are the directives.

Assembler directives may be divided into two groups:

  • Primary directives are specified on the assembler command line or in first few lines of the assembly source file. These directives control how the assembler behaves for the entire module. If conflicting primary directives are specified on the command line and in the source file, the command line directive takes precedence.
  • General directives may be specified on the command line or anywhere in the source file. These directives control the immediate behaviour of the assembler and may be changed during assembly.

Note

  • Syntax is the same for directives specified on the command line and those specified in the source file.
  • Some directives may not be specified on the command line. If one of these directives is specified on the command line, the assembler generates a fatal error and aborts.

The following table is an alphabetical list of the control directives available in the AARM Assembler.

Directive Group Description
ARM7TDMI Primary Enables the ARM7 instruction set.
ARM9E Primary Enables the ARM9E instruction set.
ARM9ExP Primary Enables the ARM9ExP instruction set.
BIGENDIAN Primary Generates instructions in big-endian format.
CASE Primary Enables case-sensitive symbol names.
COND General Includes (in the listing file) conditional source lines skipped by the preprocessor.
DATE Primary Specifies the date to use in the listing file header.
DEBUG Primary Includes debugging information in the object file.
EJECT1 General Inserts a form feed character into the listing file.
ERRORPRINT Primary Specifies the file name for error messages.
GEN General Includes all macro expansions in the listing file.
GENONLY General Includes first level macro expansions in the listing file.
INCDIR Primary Sets additional include file paths.
INCLUDE2 General Includes the contents of another file.
LIST General Includes the assembly source text in the listing file.
LITTLEENDIAN Primary Generates instructions in little-endian format.
MACRO Primary Enables preprocessor expansion of standard macros.
NOAMAKE Primary Excludes build information from the object file.
NOCASE Primary Disables case-sensitive symbol names. All symbols are converted to uppercase.
NOCOND Primary Excludes (from the listing file) conditional source lines skipped by the preprocessor.
NODEBUG Primary Excludes debugging information from the object file.
NOERRORPRINT Primary Disables error messages output to the screen.
NOGEN General Excludes macro expansions from the listing file.
NOLINES Primary Excludes line number information from the generated object module.
NOLIST General Excludes the assembly source text from the listing file.
NOMACRO Primary Disables preprocessor expansion of standard and MPL macros.
NOOBJECT Primary Disables object file generation.
NOPRINT Primary Disables listing file generation.
NOSYMBOLS Primary Excludes the symbol table from the listing file.
NOSYMLIST General Excludes subsequently defined symbols from the symbol table.
NOXREF Primary Excludes the cross-reference table from the listing file.
OBJECT Primary Specifies the name for the object file.
PAGELENGTH Primary Specifies the number of lines on a page in the listing file.
PAGEWIDTH Primary Specifies the number of characters on a line in the listing file.
PRINT Primary Specifies the name for the listing file.
RESTORE1 General Restores settings for the LIST and GEN directives.
SAVE1 General Saves settings for the LIST and GEN directives.
SYMBOLS Primary Includes the symbol table in the listing file.
SYMLIST General Includes subsequently defined symbols in the symbol table.
TABS Primary Specifies the number of blanks required for tab characters in the listing file.
TITLE Primary Specifies the page header title in the listing file.
XREF Primary Includes the cross-reference table in the listing file.

Note

  1. These directives may not be specified on the command line. They may only be specified in the source file.
  2. Primary directives may not be specified after an INCLUDE directive.
  Arm logo
Important information

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies.

Change Settings

Privacy Policy Update

Arm’s Privacy Policy has been updated. By continuing to use our site, you consent to Arm’s Privacy Policy. Please review our Privacy Policy to learn more about our collection, use and transfers
of your data.