7.6.11 Options for Code Generation Conventions
Options of the form -fflag
specify machine-independent
flags. Most flags have both positive and negative forms; the negative form of
-ffoo
would be -fno-foo
. In the table below, only
one of the forms is listed (the one that is not the default.)
Option | Definition |
---|---|
-fargument-alias
| Specify the possible relationships
among parameters and between parameters and global data.
Each language will automatically use whatever option is required by the language standard. You should not need to use these options yourself. |
-fcall-saved-reg | Treat the register named
reg as an allocatable register saved by
functions. It may be allocated even for temporaries or variables that
live across a call. Functions compiled this way will save and restore
the register reg if they use it.It is an error to used this flag with the Frame Pointer or Stack Pointer. Use of this flag for other registers that have fixed pervasive roles in the machine’s execution model will produce disastrous results. A different sort of disaster will result from the use of this flag for a register in which function values may be returned. This flag should be used consistently through all modules. |
-fcall-used-reg | Treat the register named
reg as an allocatable register that is
clobbered by function calls. It may be allocated for temporaries or
variables that do not live across a call. Functions compiled this way
will not save and restore the register reg .It is an error to use this flag with the Frame Pointer or Stack Pointer. Use of this flag for other registers that have fixed pervasive roles in the machine’s execution model will produce disastrous results. This flag should be used consistently through all modules. |
-ffixed-reg | Treat the register named
reg as a fixed register; generated code
should never refer to it (except perhaps as a Stack Pointer, Frame
Pointer or in some other fixed role).
|
-fno-ident | Ignore the #ident
directive. |
-fpack-struct | Pack all structure members together
without holes. Usually you would not want to use this option, since it
makes the code sub-optimal, and the offsets of structure members won’t
agree with system libraries. The dsPIC® DSC device requires that words be aligned on even byte boundaries; so, care must be taken when using the packed attribute to avoid run time addressing errors. |
-fpcc-struct-
return | Return short struct
and union values in memory like longer ones, rather
than in registers. This convention is less efficient, but it has the
advantage of allowing capability between the 16-bit compiler compiled
files and files compiled with other compilers.Short structures and unions are those whose size and alignment match that of an integer type. |
-fno-short-double | By default, the compiler uses a
double type equivalent to float .
This option makes double equivalent to long
double . Mixing this option across modules can have
unexpected results if modules share double data either directly through
argument passage or indirectly through shared buffer space. Libraries
provided with the product function with either switch setting. |
-fshort-enums | Allocate to an enum
type only as many bytes as it needs for the declared range of possible
values. Specifically, the enum type will be equivalent
to the smallest integer type which has enough room. |
-fverbose-asm
| Put extra commentary information in the
generated assembly code to make it more readable.
|