array.array()'s memory shared with multiprocessing.Process()
Op 2017-09-12, gerlando.falauto at gmail.com schreef <gerlando.falauto at gmail.com>:
> Notice however how I'd have to create those Arrays dynamically in the
> producer thread. Would I then be able to pass them to the consumer by
> putting a reference in a queue?
> I wouldn't want them to be pickled at all in that case, of course.
Essentially only an address pointing into a piece of shared memory is
pickled and transmitted then.
> Also, why do you say it only works on Unix? I couldn't find any
> reference to such limitation in the documentation.
There is no such limitation.
It's supposed to work on all platforms (including Windows).