Instruction width specifiers

The instruction width specifiers .W and .N control the instruction size of Thumb code assembled for ARMv6T2 or later.

In Thumb code (ARMv6T2 or later) the .W width specifier forces the assembler to generate a 32-bit encoding, even if a 16-bit encoding is available. The .W specifier has no effect when assembling to ARM code.

In Thumb code the .N width specifier forces the assembler to generate a 16-bit encoding. In this case, if the instruction cannot be encoded in 16 bits or if .N is used in ARM code, the assembler generates an error.

If you use an instruction width specifier, you must place it immediately after the instruction mnemonic and any condition code, for example:

    BCS.W   label   ; forces 32-bit instruction even for a short branch
    B.N     label   ; faults if label out of range for 16-bit instruction
Copyright © 2010-2011 ARM. All rights reserved.ARM DUI 0489F
Non-ConfidentialID091611