This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: ARM r12 usage


> When using -fomit-frame-pointer with arm-elf-gcc v2.95.2, it seems
> that r11 doesn't get used at all ??
> 
> Is this correct ? (If so why ?) Or have I missed something again :-)

Gcc has to hold r11 (fp) in reserve during the initial register allocation 
in case it is needed as a frame pointer (some functions still require one 
even with -fomit-frame-pointer).  At times it is not very good at making 
use of the register once it has determined that it doesn't require it for 
other purposes.

Note that in gcc-3.0 (and the current snapshots) you will have to use the 
option -mno-apcs-frame to omit the frame pointer from all functions.  When 
optimizing the new compiler will automatically try to eliminate the frame 
pointer from all leaf functions even if -fomit-frame-pointer is not 
requested.

R.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]