[cig-commits] r19264 - seismo/2D/SPECFEM2D/trunk/src/specfem2D
dkomati1 at geodynamics.org
dkomati1 at geodynamics.org
Fri Dec 2 15:46:59 PST 2011
Author: dkomati1
Date: 2011-12-02 15:46:59 -0800 (Fri, 02 Dec 2011)
New Revision: 19264
Modified:
seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
Log:
allow a code compiled with MPI to run in serial mode
Modified: seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90
===================================================================
--- seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2011-12-02 18:08:06 UTC (rev 19263)
+++ seismo/2D/SPECFEM2D/trunk/src/specfem2D/specfem2D.F90 2011-12-02 23:46:59 UTC (rev 19264)
@@ -887,11 +887,8 @@
call initialize_simulation(nproc,myrank,NUMBER_OF_PASSES, &
ninterface_acoustic,ninterface_elastic,ninterface_poroelastic)
+ if(nproc < 1) stop 'should have nproc >= 1'
-#ifdef USE_MPI
- if(nproc <= 1) stop 'should have nproc > 1 when running an MPI simulation'
-#endif
-
! starts reading in Database file
! it is necessary to duplicate this call before the loop on ipass = 1,NUMBER_OF_PASSES
! because we need to read the value of logical flag PERFORM_CUTHILL_MCKEE
@@ -909,9 +906,7 @@
factor_subsample_image,USE_SNAPSHOT_NUMBER_IN_FILENAME,DRAW_WATER_CONSTANT_BLUE_IN_JPG,US_LETTER, &
POWER_DISPLAY_COLOR,PERFORM_CUTHILL_MCKEE,SU_FORMAT,USER_T0, &
ADD_PERIODIC_CONDITIONS,PERIODIC_horiz_dist,PERIODIC_DETECT_TOL)
-#ifdef USE_MPI
- if(nproc_read_from_database <= 1) stop 'should have nproc_read_from_database > 1 when running an MPI simulation'
-#endif
+ if(nproc_read_from_database < 1) stop 'should have nproc_read_from_database >= 1'
if(nproc /= nproc_read_from_database) stop 'must always have nproc == nproc_read_from_database'
#ifndef USE_MPI
More information about the CIG-COMMITS
mailing list