Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 26 May 2003 12:39:53 +1000
From:      Tim Robbins <tjr@FreeBSD.ORG>
To:        Anthony Schneider <anthony@x-anthony.com>
Cc:        freebsd-current@freebsd.org
Subject:   Re: mpi + shmem issues
Message-ID:  <20030526123953.A91078@dilbert.robbins.dropbear.id.au>
In-Reply-To: <20030525211730.GA5226@x-anthony.com>; from anthony@x-anthony.com on Sun, May 25, 2003 at 05:17:30PM -0400
References:  <20030525064929.GA96588@x-anthony.com> <20030525211730.GA5226@x-anthony.com>

index | next in thread | previous in thread | raw e-mail

On Sun, May 25, 2003 at 05:17:30PM -0400, Anthony Schneider wrote:

> so, does this mean that mpich somehow exhausted all shmem locks?
> after running the program only 10 times, i see this as infeasible,
> considering
> 	a) mpich (presumably in MPI_Init()) would only want 1 or
> 	   2 locks on init
> and
> 	b) any shared memory locks mpich grabs should be freed
> 	   upon process completion (whether clean or not) by the
> 	   operating system, no?

No, semaphores stay around until they are removed. Perhaps there's an MPI_Xyz
function you should be calling before your program exits. In any case, you can
use "ipcs -s" to list semaphores, and "ipcrm -s semid" to remove semaphores.

It looks like the program is leaking semaphores -- notice how your program
fails when you run it for the 11th time, and the default maximum number of
semaphores in the GENERIC kernel is 10 (sysctl kern.ipc.semmni).


Tim


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030526123953.A91078>