multiprocessing module (PEP 371)

John Nagle nagle at animats.com
Sun Jun 8 00:33:02 EDT 2008


sturlamolden wrote:
> On Jun 5, 11:02 am, pataphor <patap... at gmail.com> wrote:
> 
>> This is probably not very central to the main intention of your post,
>> but I see a terminology problem coming up here. It is possible for
>> python objects to share a reference to some other object. This has
>> nothing to do with threads or processes, although it can be used as a
>> *mechanism* for threads and processes to share data.
> 
> It is complicated in the case of processes, because the object must be
> kept in shared memory. The complicating factor is that the base
> address of the memory mapping, which is not guaranteed to be the same
> in the virtual address space of different processes.

    Introducing shared memory in Python would be a terrible idea,
for many reasons, including the need for interprocess garbage
collection and locking.  Don't go there. Use message passing instead.

					John Nagle



More information about the Python-list mailing list