On Wednesday 22 October 2008 10:39, Ruud Vlaming wrote:
> -Wl,--defsym=__stack=xOS+xOSstackShift
> However, that trick does not longer functions. 
Got it. 

This trick does function if you leave the quotes out, so
-Wl,--defsym=__stack="xOS+xOSstackShift" is wrong and
-Wl,--defsym=__stack=xOS+xOSstackShift is correct.

Furthermore, you must set xOSstackShift as a global
symbol now (previously that was not needed) so:
    asm(".global xOSstackShift \n\t ");
    asm(".set xOSstackShift, "  DefToString(OSstackInit) " \n\t ");
somewhere will do. xOSstackShift  may only be a constant however
(and not be linked to some other symbol).
This way you can intialize the stack at the top of the predefined
array xOS, so at &xOS[SstackInit].

Hope this helps anyone with similar questions.

What keeps puzzling me is why this is not allowed:
    asm(".global __stack    \n\t ");
    asm(".set __stack, xOS \n\t ");

Ruud.


_______________________________________________
AVR-GCC-list mailing list
AVR-GCC-list@nongnu.org
http://lists.nongnu.org/mailman/listinfo/avr-gcc-list

Reply via email to