I'm not really sure what you are tryeing to archieve. Why do you need to know where the top is? Also consider that in squirrel 'top' is the end of the function frame, so is always _stackbase + framesize. This because squirrel is not a stack machine, and the top is only used when invoking a metamethod.
Alberto