2.3.7. Specifying the target processor and architecture

The options described below specify the target processor or architecture for a compilation. The compiler may take advantage of certain features of the selected processor or architecture, such as support for halfword instructions and instruction scheduling. This may make the code incompatible with other ARM processors.

If neither a -processor or -architecture option is specified, the default is -processor ARM7TDMI.

The following general points apply to processor and architecture options:

The following options are available:

-architecture n

Specifies the ARM architecture version that compiled code will comply with. Valid values for n are:

  • 3

  • 3M

  • 4

  • 4M

  • 4xM. This is architecture 4M without long multiply instructions.

  • 4T

  • 4TxM. This is architecture 4T without long multiply instructions.

It is not necessary to specify both -architecture and -processor. If a -architecture option is specified and a -processor option is not, the default processor is generic.

-cpu , name

This is a synonym for the -processor option.

-fpu, name

Select the target FPU, where name is one of:

none

No FPU. Use software floating point library. This option implies /softfp.

amp

Attached Media Processor

fpa

Floating Point Accelerator. This option implies /hardfp.

-processor, name

Compiles code for the specified ARM processor where name is the name of the ARM processor. It is not necessary to specify both -architecture and -processor. The -processor option is specific to an individual processor. The -architecture option compiles code for any processor that conforms to the specified architecture. Valid values are:

ARM6

Implements architecture 3.

ARM7

Implements architecture 3.

ARM7M

Implements architecture 3M.

ARM7TM

Implements architecture 4T.

ARM7T

Implements architecture 4TxM.

ARM7TDI

Implements architecture 4TxM.

ARM7TDMI

Implements architecture 4T. This is the default if no -processor and no -architecture options are specified. If -architecture is specified and -processor is not, the default processor is generic.

ARM8

Implements architecture 4.

ARM9

Implements architecture 4.

ARM9TDMI

Implements architecture 4T.

SA-110

Implements architecture 4.

StrongARM1

Implements architecture 4.

SA1500

Implements architecture 4. Selecting this processor option implies -fpu amp and -APCS /softdoubles.

generic

This processor name is used when compiling for a specified architecture and no -processor option is specified.

Copyright © 1997, 1998 ARM Limited. All rights reserved.ARM DUI 0041C