[Stackless] Ann: Stackless Python is DEAD! Long live Stackless Python
Sam Rushing
rushing at nightmare.com
Sat Jan 19 01:33:51 CET 2002
Christian Tismer wrote:
> What I now do is to enforce stacklessness.
> The key function is PyEval_EvalCodeEx.
> This function calls
> retval = eval_frame(f);
> and this is exactly what I capture.
> This call to eval_frame is wrapped by a special function
> of mine, which does the forbidden things.
> It checks, whether a recursive call of PyEval_EvalCodeEx
> is running. If so, the stack area between the current
> PyEval_EvalCodeEx and the former is saved into extra memory.
> Then, the current invocation's locals are moved up,
> and execution continues there.
Let me see if I understand this correctly - you are in effect changing
C's execution model to one that uses a linked list of heap-allocated
frames? With PyEval_EvalCodeEx() being the 'frame granularity'?
Seems like this could run into trouble with an optimizing compiler...
-Sam
_______________________________________________
Stackless mailing list
Stackless at www.tismer.com
http://www.tismer.com/mailman/listinfo/stackless
More information about the Stackless
mailing list