Dale wrote: > Hi >@2010.06.09_14:42:49_+0200 > > Here's some code which shows this.
This code doesn't show a real bug, because even if the initialize function weren't inlined, the stack would have to grow when calling it. If you have enough RAM to support that, you have enough RAM to support it being left there. The real bug comes from gcc not reusing that space for other variables afterwards, or calling other functions that might need that space without releasing it first. For instance, if you have another array in main but don't use it until after you've called initialize, gcc should reuse the same space for the main array too and not use 100 bytes of stack. Sometimes this doesn't work correctly, but I wasn't able to produce a simple case to show this problem (only very complex programs which I didn't want to post online). :( -- Paulo Marques Software Development Department - Grupo PIE, S.A. Phone: +351 252 290600, Fax: +351 252 290601 Web: www.grupopie.com "To know recursion, you must first know recursion." _______________________________________________ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list