diff --git a/Grid/communicator/SharedMemoryMPI.cc b/Grid/communicator/SharedMemoryMPI.cc index ed465252..0de48cfe 100644 --- a/Grid/communicator/SharedMemoryMPI.cc +++ b/Grid/communicator/SharedMemoryMPI.cc @@ -170,17 +170,24 @@ void GlobalSharedMemory::GetShmDims(const Coordinate &WorldDims,Coordinate &ShmD std::vector primes({2,3,5}); int dim = 0; + int last_dim = ndimension - 1; int AutoShmSize = 1; while(AutoShmSize != WorldShmSize) { - for(int p=0;p