5 symbols, 1 symbol naming rules, Symbols -12 – ARM VERSION 1.2 User Manual

Page 90

Advertising
background image

Assembler Reference

3-12

Copyright © 2000, 2001 ARM Limited. All rights reserved.

ARM DUI 0068B

3.5

Symbols

You can use symbols to represent variables, addresses, and numeric constants. Symbols
representing addresses are also called labels. See:

Variables on page 3-13

Numeric constants on page 3-13

Labels on page 3-15

Local labels on page 3-16.

3.5.1

Symbol naming rules

The following general rules apply to symbol names:

You can use uppercase letters, lowercase letters, numeric characters, or the
underscore character in symbol names.

Do not use numeric characters for the first character of symbol names, except in
local labels (see Local labels on page 3-16).

Symbol names are case-sensitive.

All characters in the symbol name are significant.

Symbol names must be unique within their scope.

Symbols must not use built-in variable names or predefined symbol names (see
Predefined register and coprocessor names on page 3-9 and Built-in variables on
page 3-10).

Symbols must not use the same name as instruction mnemonics or directives. If
you use the same name as an instruction mnemonic or directive, use double bars
to delimit the symbol name. For example:

||ASSERT||

The bars are not part of the symbol.

If you need to use a wider range of characters in symbols, for example, when working
with compilers, use single bars to delimit the symbol name. For example:

|.text|

The bars are not part of the symbol. You cannot use bars, semicolons, or newlines within
the bars.

Advertising