Use return addresses to index bitmaps #114

myreen opened this Issue May 4, 2016 · 0 comments


None yet

2 participants

myreen commented May 4, 2016

Currently stackLang programs write a number onto the stack at each function call. The number is an index into the bitmaps (used by the GC if it is called).

An alternative approach is to use the return address as a means to find the right bitmap entry. One could e.g. look up the relevant bitmap index from a hash table that maps return addresses to bitmap indexes.

The advantage with the alternative approach is that each function call only needs to put the return address into a specific location in the stack frame. The index is no longer required. Very neat!

@xrchz xrchz added the enhancement label May 13, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment