Hi, everyone: I am using Keil C251 verison4.53d, and the Register Coloring OPTIMIZATION compiler option does take effect indeed, code size decreased when it is used. In my Application, there exist timer interrupt when program runs. So I am not sure if the interrupt routine will corrupt the running task function that may be optimized by register coloring option. Anyone knows C251 compiler has take it into account? I am also interested in how the compiler deal with the situation mentioned above. If C251 can not avoid the hidden problem, is there any method exist, that feasible solve this collision.
Thanks.
The interrupt service routine MUST save and restore all registers it changes. If it does this, there should be no negative effects on register coloring.
Jon