xmlrpc idea for getting around the GIL
Diez B. Roggisch
deets at nospam.web.de
Sun Nov 22 23:15:01 CET 2009
Daniel Fetchinson schrieb:
>> Has anyone every tried wrapping the CPython lib into a daemon with an
>> RPC mechanism in order to move the GIL out of the process? I have
>> multiple audio threads, each of which use the python interpreter but
>> don't have to interact with each other and can might as well use a
>> separate interpreter handled by a daemon with libpython linked in.
>> I've never used a C xmlrpc lib before and would probably need to set
>> up some shared memory to get it to work. Can anyone suggest a library
>> out there that would at do that sort of thing, maybe with some
>> cross-platform process management?
>> I imagine this is how the multiprocessing module works.
> Yes, it does seem you need multiprocessing. That would take advantage
> of multiple cores and the GIL wouldn't bother you at all. Take a look
> For what you describe (separate tasks running concurrently without
> communicating) the multiprocessing module would be ideal.
The problem is that the OP has a embedded application running threads.
multiprocssing doesn't help there.
More information about the Python-list