[Dart-dev] DART/branches Revision: 12404

dart at ucar.edu dart at ucar.edu
Thu Feb 15 15:36:32 MST 2018


hendric at ucar.edu
2018-02-15 15:36:32 -0700 (Thu, 15 Feb 2018)
62
test code for using MPI_Comm_group to distribute static data




Added: DART/branches/rma_static_data/developer_tests/mpi_groups/Makefile
===================================================================
--- DART/branches/rma_static_data/developer_tests/mpi_groups/Makefile	                        (rev 0)
+++ DART/branches/rma_static_data/developer_tests/mpi_groups/Makefile	2018-02-15 22:36:32 UTC (rev 12404)
@@ -0,0 +1,154 @@
+# DART software - Copyright UCAR. This open source software is provided
+# by UCAR, "as is", without charge, subject to all terms of use at
+# http://www.image.ucar.edu/DAReS/DART/DART_download
+#
+# DART $Id$
+
+# Makefile for various mpi test and timing programs
+#
+# This Makefile directly 'include's the mkmf.template file used by the 
+#  mkmf system.  If the mkmf.template is set wrong for this system, 
+#  these builds will fail.  See ../../mkmf/mkmf.template.* for various
+#  compiler and platform settings.
+
+include ../../../build_templates/mkmf.template
+
+# the include defines the following makefile variables:
+# MPIFC = 
+# MPILD =
+# FC =
+# LD =
+# NETCDF =
+# INCS = 
+# FFLAGS += -I$(INCS)  
+# LIBS =
+# LDFLAGS += -L$(NETCDF)/lib -lnetcdf
+
+# ----------------------------------------------------------------------------
+
+SRC = ftest_f90.f90 ftest_mpi.f90 ftest_nc.f90 \
+      ftest_stop.f90 ftest_go.f90 ctest.c ctest_mpi.c ctest_nc.c
+
+ALLSRC = $(SRC) Makefile README runme_*
+
+EXE = ftest_f90 ftest_mpi ftest_nc
+ALLEXE = $(EXE) ftest_stop ftest_go ctest ctest_mpi ctest_nc
+
+# ----------------------------------------------------------------------------
+
+# default target - build and test only what is necessary for dart
+all:  $(EXE)
+
+
+# all executables - if you are having problems, this might help diagnose
+# what parts of the install are giving problems
+everything: $(ALLEXE)
+
+
+# run the basic executables interactively
+check:  all
+	./ftest_f90                   # this should run
+	./ftest_nc                    # this should run
+	mpirun -np 2 ./ftest_mpi      # this may not be allowed on a login node
+
+# submit the jobs to a batch queue
+batch: ftest_mpi
+	#bsub < runme           # comment this in for LSF
+	#qsub runme             # comment this in for PBS
+	./runme                 # anything else
+
+# check async=4 mode.  comment in the right line for your batch system.
+async4: ftest_stop ftest_go
+	#bsub < runme_async4      # comment this in for LSF
+	#qsub runme_async4        # comment this in for PBS
+	./runme_async4            # anything else
+
+# ----------------------------------------------------------------------------
+
+
+# simple f90 test program without mpi or netcdf
+ftest_f90: ftest_f90.f90
+	$(FC) ftest_f90.f90 $(LDFLAGS) -o ftest_f90
+
+# f90 test program that calls MPI functions
+ftest_mpi: ftest_mpi.f90
+	$(MPIFC) ftest_mpi.f90 $(LDFLAGS) -o ftest_mpi
+
+# f90 test program that calls netCDF functions
+ftest_nc: ftest_nc.f90
+	$(FC) ftest_nc.f90 $(LDFLAGS) -o ftest_nc
+
+
+# test of named pipe (fifo) communication with mpi
+ftest_stop: ftest_stop.f90
+	$(MPIFC) ftest_stop.f90 $(LDFLAGS) -o ftest_stop
+
+ftest_go: ftest_go.f90
+	$(MPIFC) ftest_go.f90 $(LDFLAGS) -o ftest_go
+
+
+
+# DART uses no C code, but if you want to test whether your system has 
+# working C interfaces for MPI or netCDF, you can use these programs.
+# Edit 'gcc' below, if needed, to reference your own C compiler.
+
+# simple c program without mpi or netcdf
+ctest: ctest.c


More information about the Dart-dev mailing list