Patent ID: 6363473
Filing Date: 2002-03-26
Classification: G06F

Abstract:
A method for performing a subroutine call and return using a simulated memory stack, comprising:(a) loading a destination address corresponding to the subroutine to be called in a CPU general purpose register; (b) loading a return address in a CPU general purpose register, the return address corresponding to the instruction to be returned to following execution of the subroutine; (c) retrieving a pointer value corresponding to a top of stack pointer for the simulated stack; (d) adjusting the pointer value; (e) saving the adjusted pointer value from step (d) in a non-general purpose register; (f) saving the return address in a non-general purpose register pointed to by the adjusted pointer value from step (d); and (g) jumping to the destination address to execute the subroutine.