From: "Omar G. Stradella" <omar@boston.sgi.com>
Newsgroups: comp.parallel
Subject: Re: Origin2000 Shared Memory
Date: 14 May 1999 05:58:14 GMT
Organization: Silicon Graphics, Inc.
Approved: bigrigg@cs.cmu.edu
Message-Id: <7hge1m$lp6$1@goldenapple.srv.cs.cmu.edu>
Originator: bigrigg@ux6.sp.cs.cmu.edu
Xref: ukc comp.parallel:15600


Randy Crawford wrote:
> NUM_THREADS
>   Not a standard Irix environment variable.  Often used by pthread
>   programmers.  However, Irix tools do not recognize this variable.

Not true. NUM_THREADS is recognized by the IRIX MP library.

> OMP_NUM_THREADS
>   Used by OpenMP binaries only (C or Fortran).

Partially true, see below.

> MPC_NUM_THREADS
>   Should be MPC_SET_NUMTHREADS.  Used by the Irix MP multithreading
>   library, for Power C/Fortran and their shared-memory parallel
>   directives (like $do_across).

In practice all these are equivalent and you can use any of them to
specify the number of processes to be created for a program containing
parallel directives (either the traditional ones like DOACROSS or the
new ones from OpenMP). But, if you set more than one, there is a
precedence order that is:

OMP_NUM_THREADS takes precedence over MP_SET_NUMTHREADS, which takes
precedence over MPC_NUM_THREADS, which takes precedence over
NUM_THREADS.

Omar.

-- 
+---------------------------------------------------------------------+
Omar G. Stradella, Ph.D.                    
SGI / Chemistry and Biology Applications Group
One Cabot Road, Hudson, MA 01749, USA           N 42 22'40" W 71 33'44"
E-mail: omar@boston.sgi.com Phone: +1-978-567-2258 FAX: +1-978-562-4755 
http://www.sgi.com/chembio                  http://reality.sgi.com/omar 
+--------  Ph-nglui mglw'nafh Cthulhu R'lyeh wgah'nagl fhtagn  -------+

--
Articles to bigrigg+parallel@cs.cmu.edu (Admin: bigrigg@cs.cmu.edu)
Archive: http://www.hensa.ac.uk/parallel/internet/usenet/comp.parallel

