#2112: move CCTK_MyHost and friends into flesh --------------------------+------------------------------------------------- Reporter: rhaas | Owner: Type: enhancement | Status: new Priority: minor | Milestone: Component: Cactus | Version: development version Resolution: | Keywords: Carpet PUGH driver --------------------------+-------------------------------------------------
Comment (by rhaas):
I attach a sample code using mmap. Note that it is not bulletproof. The bug that exists is that if there are more than one independent Cactus runs on the same node (eg on your workstation while running testsuites) then they all compete for the same shared memory section and only one of them will get it.
To avoid it one needs some name for the shared memory section that is unique to the simulation. This is quite hard to do and I am somewhat sure that it is not always possible. One cannot for example choose the name of the executable or the name of the parfile since neither one needs to be unique. So it is the opposite problem the Erik mentioned on a BG since the problem with the mmap approach is to limit the mapping to just the processes in the current run.