Fine thread control, Run only n bytecodes
Alan Kennedy
alanmk at hotmail.com
Sun Jul 18 11:54:18 EDT 2004
David Pokorny wrote:
> I'd like to be able to take a function or other chunk of code (that someone
> else has written), run it for, say 50 byte codes, and then return control
> back to my program/controlling thread until my program/controlling thread
> indicates that it wants to run the next 50 bytes codes of the foreign
> program, etc...
>
> Is there an extension to the python threading module that supports such fine
> control?
There was a similar thread to this last year which you may find useful.
http://mail.python.org/pipermail/python-list/2003-July/173671.html
http://groups.google.com/groups?threadm=g7xRa.305%24fF.9914%40nnrp1.ozemail.com.au
Multiple possible approaches to the problem were discussed.
Particularly impressive was Duncan Booth's tour-de-force manipulation
of the target program at a byte-code level.
regards,
--
alan kennedy
------------------------------------------------------
check http headers here: http://xhaus.com/headers
email alan: http://xhaus.com/contact/alan
More information about the Python-list
mailing list