[concurrency-interest] Shared Memory ?

Dawid Kurzyniec dawidk at mathcs.emory.edu
Wed Jun 8 09:54:59 EDT 2005

Ernst, Matthias wrote:

>I'm musing about java-to-java/java-to-native, shared memory,
>inter-process communication. Is stuff like that on the list of things
>you see as a possible Java feature?
>I imagine an API for
>* creating/deleting shared-memory descriptors
>* attaching to a shared-memory descriptor, yielding a DirectByteBuffer
>* an extension of j.u.c.atomic to support atomic instructions on such
>* basic IPC abstractions on top
This sounds like a small and nice library that you could write yourself 
using the JNI functions for byte buffers. You probably already have some 
prototype code written. My understanding is that you could only share 
buffers, not objects, due to reachability (gc) / mutability issues. I 
don't think there is any JSR that deals with this at the moment, but the 
beauty of the JSR process is that you could always propose one, I guess...

It seems that except for atomic functions, this sort of library could be 
implemented w/o changes to the Java platform code (atomicity via JNI 
would probably be too expensive).


More information about the Concurrency-interest mailing list