Maker Pro
Maker Pro

hardware and software stack

juantravel

May 14, 2010
41
Joined
May 14, 2010
Messages
41
I was reading the manual for hitch c compiler. I came across software stack. The pic im using is the 16f628a and that has a hardware stack that's 8 levels deep. The allows me to nest up too 7 functions. Which is more then i need. Since the hardware stack only stores the return address's, then I'm assuming that the software stack(compiled stack) allows for local variables, arguments, and return to be implemented. But then you would have to emulate a stack for every function. Is that correct?
 

(*steve*)

¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd
Moderator
Jan 21, 2010
25,510
Joined
Jan 21, 2010
Messages
25,510
There are other ways to pass parameters and to handle local variables. You can sometimes use registers, for example.
 
Top