Re: Memory sharing question

2007-02-24 Thread Alan
> with the address as the "start" parameter and MAP_FIXED. However, that > tends to fail, and MAP_FIXED can have annoying side-effects (killing > off other mappings). MAP_FIXED requires you know in advance a good place to put the memory, which isn't too hard with some planning but does get fairly

Memory sharing question

2007-02-24 Thread Stephen Dolan
Hi. I'd like to know if it is possible to get two processes to share a memory segment at the same address, e.g. both mmap() the same file and have it return the same address in both. This could be done by mmap()ing it in one of them, communicating the address to the other (via a socket or

Memory sharing question

2007-02-24 Thread Stephen Dolan
Hi. I'd like to know if it is possible to get two processes to share a memory segment at the same address, e.g. both mmap() the same file and have it return the same address in both. This could be done by mmap()ing it in one of them, communicating the address to the other (via a socket or

Re: Memory sharing question

2007-02-24 Thread Alan
with the address as the start parameter and MAP_FIXED. However, that tends to fail, and MAP_FIXED can have annoying side-effects (killing off other mappings). MAP_FIXED requires you know in advance a good place to put the memory, which isn't too hard with some planning but does get fairly