On Jun 25, 7:22 am, "Mohan kumar" <mohankumar_be...@[EMAIL PROTECTED]
>
wrote:
> Below code is part of powerpc 555 boot up code, could any one explain,
why
> stack is terminated by "stwu r0,-64(r1)"
>addi r0,r0,0 # Clear r0.
>stwu r0,-64(r1) # Terminate stack.
A little googling shows that it's powerpc convention to store a
pointer to the previous stack frame in a new one, basically making
them a linked list. This seems to be setting up the first-ever stack
frame, and so it's storing zero to indicate there was no previous
one. I'm not completely sure, but this may not actually be necessary
for execution, but instead just to be to help a debugger figure out
that it's the first frame and there are no previous ones that can be
examined.


|