Re: [arm-gnu] sprintf issue on Cortex-M3
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [arm-gnu] sprintf issue on Cortex-M3



James Kehl pisze:
I remember hearing that later ARMs got really picky about keeping the
stack aligned, and that failure to do so would cause weird problems with
64-bit vars (like doubles) - especially with odd call chains and
interrupts.

I don't think this is Cortex-M3-specific, but I cannot try on ARM7 - I only got LPC2103 right now, and sprintf() won't fit in it...

Is it possible that --gc-sections is affecting the start address of your
stack?

I've just checked, and in both cases the stack is at least word aligned (without --gc-sections [when sprintf fails] it is even quad-word aligned), so I don't think that's the issue here.

4\/3!!