Bill Florac

CodeWarrior register usage for ColdFire

Discussion created by Bill Florac on Mar 23, 2007
Latest reply on Mar 24, 2007 by Bill Florac
I'm using CodeWarrior to develop C code for the MCF52233 ColdFire processor.  I seems that the C compiler does not take advantage of registers D1-D7 and A2-A5.  Is this seem correct?  I have not optimization turned on and the parameter passing is "standard". Does register utilization improve if optimizations are turned on?
 
When calling a assembly functions from C code, since the compliler does not use the registers, would it safe (but perhaps sloppy) code not to perserve the register values since they are not used by the compiler?
 
FlashToo

Outcomes