[FLASH-USERS] GuardCell filling

Klaus Weide klaus at flash.uchicago.edu
Tue Feb 19 12:40:24 EST 2013


On Tue, 19 Feb 2013, Seyit Hocuk wrote:

> I have a simple question on Grid_fillGuardCells.
> 
> If I run a parallel job, for example on 2 processors, and I call the routine
> "Grid_fillGuardCells(CENTER, ALLDIR, maskSize=NUNK_VARS, mask=gcMask,
> minLayers=2, selectBlockType=LEAF)" in my block loop, what would happen if on
> 1 processor I give a different mask (e.g. DENS_VAR) than on the other
> processor (e.g. PRES_VAR). Or, DENS_VAR+PRES_VAR on one and only PRES_VAR on
> the other. Would it still work?

Hello Seyit,
No, this would not work.

> Also, what would happen if I call the routine on 1 proc but not on the other,
> like "if (meshMe==0) call Grid_fillGuardCells(...)"? Would it freeze/crash?

Again, this will not work, because under the hood Grid_fillGuardCells, 
and the underlying PARAMESH routines, do some communications in which all
MPI tasks in MPI_COMM_WORLD (or more exactly, gr_meshComm) have to 
participate.

Even if this appeared to work in some cases, it would not be doing the 
right thing.  All arguments to Grid_fillGuardCells have to agree, on all 
processes in gr_meshComm.

Klaus



More information about the flash-users mailing list