I'm using the latest CCS and gcc with an LM4F120XL launchpad and was investigating porting some code from an AVR project. During debugging, I found that global variables that were assigned an initial value were being initialized to random data. The startup ISR seems to be attempting to zero BSS and initialize data during startup, but apparently not in the way I hoped. I simplified the code to something like:
int j = 7;
main( ...
{
// j is random at this point.
}
Any ideas on what I might be doing wrong?