A processor preferably comprises a processing core that generates memory
addresses to access a memory and on which a plurality of methods operate,
a cache coupled to the processing core, and a programmable register
containing a pointer to a currently active method's set of local
variables. The cache may be used to store one or more sets of local
variables, each set being used by a method. Further, the cache may
include at least two sets of local variables corresponding to different
methods, one method calling the other method and the sets of local
variables may be separated by a pointer to the set of local variables
corresponding to the calling method.