3 # Run some of the tests. If any arguments are provided, pass them to the
6 # -mvhome is needed for the ANL SP, and is ignored by others
10 STOPFILE=${MPITEST_STOPTEST:-"$HOME/.stopmpichtests"}
11 MAKE="make --no-print-directory"
14 # Set mpirun to the name/path of the mpirun program
23 MAKE="make --no-print-directory"
27 basedir=`echo $arg | sed 's/-basedir=//'`
30 srcdir=`echo $arg | sed 's/-srcdir=//'`
36 margs=`echo $arg | sed 's/-margs=//'`
41 summaryfile=`echo A$arg | sed 's/A-summaryfile=//'`
51 echo "runtests [-checkonly] [-margs='...']"
52 echo "run tests in this directory. If -checkonly set, just run"
53 echo "the differences check (do NO rerun the test programs)."
54 echo "If -margs is used, these options are passed to mpirun."
55 echo "If -small is used, the examples are built, run, and deleted."
59 if test -n "$arg" ; then
60 echo "runtests: Unknown argument ($arg)"
68 # Load basic procedures
69 . ${srcdir}/../runbase
71 # If the programs are not available, run make.
72 if [ ! -x attrerr -a $makeeach = 0 -a $runtests = 1 ] ; then
75 mpirun=" ${basedir}/bin/smpirun -platform ${srcdir}/../../../../examples/msg/small_platform_with_routers.xml -hostfile ${srcdir}/../../hostfile --log=root.thres:critical"
77 if [ $runtests = 1 ] ; then
80 # Run Fortran tests ONLY if Fortran available
82 RunTest attrtest 2 "*** Testing attributes from Fortran ***"
84 if [ $test_mpi2 = 1 ] ; then
85 RunTest commnamesf 1 "*** Testing Communicator Names from Fortran ***"
88 #uses attr, not implemented
89 #RunTest attrt 2 "*** Testing attributes ***"
91 RunTest attrerr 1 "*** Testing attributes (2) ***"
93 #fails with unions, excludes or intersections, need debug in smpi to work -> left, but wrong
94 RunTest grouptest_mpich 4 "*** Testing Groups ***"
96 RunTest groupcreate 4 "*** Testing Group creation ***"
98 #uses MPI_Intercomm_create
99 #RunTest ictest 4 "*** Testing Intercommunicators ***"
101 RunTest icdup 3 "*** Testing dup of an intercommunicator ***"
104 # ictest2 relies on a inconsistency in the standard, to wit, that the
105 # leader in both groups can be the same process. This seems to be
106 # essential in a dynamic setting, since the only process both groups can
107 # access may be the single parent process (other than using client/server
108 # intercommunicator creating routines, with the parent providing the common
111 #testfiles="$testfiles ictest2.out"
114 #echo '*** Testing Intercommunicators (2) ***'
115 #echo '*** Testing Intercommunicators (2) ***' >> ictest2.out
116 #$mpirun $args -np 4 ictest2 $* >> ictest2.out 2>&1
117 #echo '*** Testing Intercommunicators (2) ***' >> ictest2.out
119 #uses MPI_Comm_test_inter and MPI_Intercomm_create
120 #RunTest ictest3 4 "*** Testing Intercommunicators (3) ***"
124 RunTest commnames 2 "*** Testing Communicator Names ***"
128 testfiles=`echo *.out`
131 echo '*** Checking for differences from expected output ***'
132 CheckAllOutput context.diff