[cig-commits] r12511 - seismo/3D/SPECFEM3D_GLOBE/trunk/UTILS/estimate_best_values_runs

dkomati1 at geodynamics.org dkomati1 at geodynamics.org
Sun Aug 3 05:37:24 PDT 2008


Author: dkomati1
Date: 2008-08-03 05:37:24 -0700 (Sun, 03 Aug 2008)
New Revision: 12511

Modified:
   seismo/3D/SPECFEM3D_GLOBE/trunk/UTILS/estimate_best_values_runs/estimate_best_values_runs.f90
Log:
fixed a small bug: potentially an infinite loop on NEX_XI for very large values


Modified: seismo/3D/SPECFEM3D_GLOBE/trunk/UTILS/estimate_best_values_runs/estimate_best_values_runs.f90
===================================================================
--- seismo/3D/SPECFEM3D_GLOBE/trunk/UTILS/estimate_best_values_runs/estimate_best_values_runs.f90	2008-08-03 11:54:29 UTC (rev 12510)
+++ seismo/3D/SPECFEM3D_GLOBE/trunk/UTILS/estimate_best_values_runs/estimate_best_values_runs.f90	2008-08-03 12:37:24 UTC (rev 12511)
@@ -147,12 +147,21 @@
 
     counter = 1
     c = 0
+    NEX_XI = 0
     already_printed = .false.
 
+! loop on the columns of the table
     do while (counter <= NB_COLUMNS_TABLE)
+
       c = c + 1
       NEX_XI = BASE_VALUE * c * NPROC_XI
 
+! impose an upper limit on current "reasonably large" values to avoid an infinite loop
+! these values should be okay for the next few years (i.e., on machines around 1 petaflops)
+! (this written in August 2008)
+      if(c > 15 .or. NEX_XI > 6000) exit
+
+! also exclude very coarse meshes below NEX_XI = 64
       if(NEX_XI >= 64 .and. mod(NEX_XI,2*BASE_VALUE) == 0) then
 
         counter = counter + 1



More information about the cig-commits mailing list