gcc: RX Options

1 
1 3.18.41 RX Options
1 ------------------
1 
1 These command-line options are defined for RX targets:
1 
1 '-m64bit-doubles'
1 '-m32bit-doubles'
1      Make the 'double' data type be 64 bits ('-m64bit-doubles') or 32
1      bits ('-m32bit-doubles') in size.  The default is
1      '-m32bit-doubles'.  _Note_ RX floating-point hardware only works on
1      32-bit values, which is why the default is '-m32bit-doubles'.
1 
1 '-fpu'
1 '-nofpu'
1      Enables ('-fpu') or disables ('-nofpu') the use of RX
1      floating-point hardware.  The default is enabled for the RX600
1      series and disabled for the RX200 series.
1 
1      Floating-point instructions are only generated for 32-bit
1      floating-point values, however, so the FPU hardware is not used for
1      doubles if the '-m64bit-doubles' option is used.
1 
1      _Note_ If the '-fpu' option is enabled then
1      '-funsafe-math-optimizations' is also enabled automatically.  This
1      is because the RX FPU instructions are themselves unsafe.
1 
1 '-mcpu=NAME'
1      Selects the type of RX CPU to be targeted.  Currently three types
1      are supported, the generic 'RX600' and 'RX200' series hardware and
1      the specific 'RX610' CPU. The default is 'RX600'.
1 
1      The only difference between 'RX600' and 'RX610' is that the 'RX610'
1      does not support the 'MVTIPL' instruction.
1 
1      The 'RX200' series does not have a hardware floating-point unit and
1      so '-nofpu' is enabled by default when this type is selected.
1 
1 '-mbig-endian-data'
1 '-mlittle-endian-data'
1      Store data (but not code) in the big-endian format.  The default is
1      '-mlittle-endian-data', i.e. to store data in the little-endian
1      format.
1 
1 '-msmall-data-limit=N'
1      Specifies the maximum size in bytes of global and static variables
1      which can be placed into the small data area.  Using the small data
1      area can lead to smaller and faster code, but the size of area is
1      limited and it is up to the programmer to ensure that the area does
1      not overflow.  Also when the small data area is used one of the
1      RX's registers (usually 'r13') is reserved for use pointing to this
1      area, so it is no longer available for use by the compiler.  This
1      could result in slower and/or larger code if variables are pushed
1      onto the stack instead of being held in this register.
1 
1      Note, common variables (variables that have not been initialized)
1      and constants are not placed into the small data area as they are
1      assigned to other sections in the output executable.
1 
1      The default value is zero, which disables this feature.  Note, this
1      feature is not enabled by default with higher optimization levels
1      ('-O2' etc) because of the potentially detrimental effects of
1      reserving a register.  It is up to the programmer to experiment and
1      discover whether this feature is of benefit to their program.  See
1      the description of the '-mpid' option for a description of how the
1      actual register to hold the small data area pointer is chosen.
1 
1 '-msim'
1 '-mno-sim'
1      Use the simulator runtime.  The default is to use the libgloss
1      board-specific runtime.
1 
1 '-mas100-syntax'
1 '-mno-as100-syntax'
1      When generating assembler output use a syntax that is compatible
1      with Renesas's AS100 assembler.  This syntax can also be handled by
1      the GAS assembler, but it has some restrictions so it is not
1      generated by default.
1 
1 '-mmax-constant-size=N'
1      Specifies the maximum size, in bytes, of a constant that can be
1      used as an operand in a RX instruction.  Although the RX
1      instruction set does allow constants of up to 4 bytes in length to
1      be used in instructions, a longer value equates to a longer
1      instruction.  Thus in some circumstances it can be beneficial to
1      restrict the size of constants that are used in instructions.
1      Constants that are too big are instead placed into a constant pool
1      and referenced via register indirection.
1 
1      The value N can be between 0 and 4.  A value of 0 (the default) or
1      4 means that constants of any size are allowed.
1 
1 '-mrelax'
1      Enable linker relaxation.  Linker relaxation is a process whereby
1      the linker attempts to reduce the size of a program by finding
1      shorter versions of various instructions.  Disabled by default.
1 
1 '-mint-register=N'
1      Specify the number of registers to reserve for fast interrupt
1      handler functions.  The value N can be between 0 and 4.  A value of
1      1 means that register 'r13' is reserved for the exclusive use of
1      fast interrupt handlers.  A value of 2 reserves 'r13' and 'r12'.  A
1      value of 3 reserves 'r13', 'r12' and 'r11', and a value of 4
1      reserves 'r13' through 'r10'.  A value of 0, the default, does not
1      reserve any registers.
1 
1 '-msave-acc-in-interrupts'
1      Specifies that interrupt handler functions should preserve the
1      accumulator register.  This is only necessary if normal code might
1      use the accumulator register, for example because it performs
1      64-bit multiplications.  The default is to ignore the accumulator
1      as this makes the interrupt handlers faster.
1 
1 '-mpid'
1 '-mno-pid'
1      Enables the generation of position independent data.  When enabled
1      any access to constant data is done via an offset from a base
1      address held in a register.  This allows the location of constant
1      data to be determined at run time without requiring the executable
1      to be relocated, which is a benefit to embedded applications with
1      tight memory constraints.  Data that can be modified is not
1      affected by this option.
1 
1      Note, using this feature reserves a register, usually 'r13', for
1      the constant data base address.  This can result in slower and/or
1      larger code, especially in complicated functions.
1 
1      The actual register chosen to hold the constant data base address
1      depends upon whether the '-msmall-data-limit' and/or the
1      '-mint-register' command-line options are enabled.  Starting with
1      register 'r13' and proceeding downwards, registers are allocated
1      first to satisfy the requirements of '-mint-register', then '-mpid'
1      and finally '-msmall-data-limit'.  Thus it is possible for the
1      small data area register to be 'r8' if both '-mint-register=4' and
1      '-mpid' are specified on the command line.
1 
1      By default this feature is not enabled.  The default can be
1      restored via the '-mno-pid' command-line option.
1 
1 '-mno-warn-multiple-fast-interrupts'
1 '-mwarn-multiple-fast-interrupts'
1      Prevents GCC from issuing a warning message if it finds more than
1      one fast interrupt handler when it is compiling a file.  The
1      default is to issue a warning for each extra fast interrupt handler
1      found, as the RX only supports one such interrupt.
1 
1 '-mallow-string-insns'
1 '-mno-allow-string-insns'
1      Enables or disables the use of the string manipulation instructions
1      'SMOVF', 'SCMPU', 'SMOVB', 'SMOVU', 'SUNTIL' 'SWHILE' and also the
1      'RMPA' instruction.  These instructions may prefetch data, which is
1      not safe to do if accessing an I/O register.  (See section 12.2.7
1      of the RX62N Group User's Manual for more information).
1 
1      The default is to allow these instructions, but it is not possible
1      for GCC to reliably detect all circumstances where a string
1      instruction might be used to access an I/O register, so their use
1      cannot be disabled automatically.  Instead it is reliant upon the
1      programmer to use the '-mno-allow-string-insns' option if their
1      program accesses I/O space.
1 
1      When the instructions are enabled GCC defines the C preprocessor
1      symbol '__RX_ALLOW_STRING_INSNS__', otherwise it defines the symbol
1      '__RX_DISALLOW_STRING_INSNS__'.
1 
1 '-mjsr'
1 '-mno-jsr'
1      Use only (or not only) 'JSR' instructions to access functions.
1      This option can be used when code size exceeds the range of 'BSR'
1      instructions.  Note that '-mno-jsr' does not mean to not use 'JSR'
1      but instead means that any type of branch may be used.
1 
1  _Note:_ The generic GCC command-line option '-ffixed-REG' has special
1 significance to the RX port when used with the 'interrupt' function
1 attribute.  This attribute indicates a function intended to process fast
1 interrupts.  GCC ensures that it only uses the registers 'r10', 'r11',
1 'r12' and/or 'r13' and only provided that the normal use of the
1 corresponding registers have been restricted via the '-ffixed-REG' or
1 '-mint-register' command-line options.
1