/[escript]/trunk/run-escript.in
ViewVC logotype

Diff of /trunk/run-escript.in

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 4973 by sshaw, Wed May 28 06:02:38 2014 UTC revision 4993 by sshaw, Thu Jun 5 03:04:56 2014 UTC
# Line 483  then Line 483  then
483    
484     if [ ! -z "$HOSTFILE" ]     if [ ! -z "$HOSTFILE" ]
485     then     then
486        mpdboot -n $ESCRIPT_NUM_NODES -r ssh -f "$HOSTFILE"          CMD="mpirun -hostfile $HOSTFILE -n $TOTPROC -ppn $ESCRIPT_NUM_PROCS $EXEC_CMD"
       if [ $? -ne 0 ]  
       then  
          echo "mpdboot with host file $HOSTFILE for $ESCRIPT_NUM_NODES nodes failed."  
          exit 1  
       else  
           if [ ! -z $ESCRIPT_VERBOSE ]; then echo "mpdboot was started with host file $HOSTFILE for $ESCRIPT_NUM_NODES nodes."; fi  
       fi  
487     else     else
488        mpdboot -n 1 -r ssh          if [ ! -z $ESCRIPT_VERBOSE ]; then echo "Empty hostfile, running on single node"; fi
489        if [ $? -ne 0 ]          CMD="mpirun -n 1 -ppn $ESCRIPT_NUM_PROCS $EXEC_CMD"
       then  
          echo "mpdboot failed."  
          exit 1  
       else  
           if [ ! -z $ESCRIPT_VERBOSE ]; then echo "mpdboot was started."; fi  
       fi  
490     fi     fi
    CMD="mpiexec -perhost $ESCRIPT_NUM_PROCS -envall -n $TOTPROC $EXEC_CMD"  
491     if [ ! -z $ESCRIPT_VERBOSE ]; then echo "MPI command is \"$CMD\"."; fi     if [ ! -z $ESCRIPT_VERBOSE ]; then echo "MPI command is \"$CMD\"."; fi
492     $CMD     $CMD
493     EXIT_CODE=$?     EXIT_CODE=$?
    mpdallexit  
    if [ ! -z $ESCRIPT_VERBOSE ]; then echo "mpdallexit executed."; fi  
494  #=============== SGI's MPIMPT ===================================  #=============== SGI's MPIMPT ===================================
495  elif [ "$MPI_FLAVOUR" = "MPT" ]  elif [ "$MPI_FLAVOUR" = "MPT" ]
496  then  then
# Line 544  then Line 528  then
528           mpdboot -n $ESCRIPT_NUM_NODES -r ssh -f "$HOSTFILE"           mpdboot -n $ESCRIPT_NUM_NODES -r ssh -f "$HOSTFILE"
529           if [ $? -ne 0 ]           if [ $? -ne 0 ]
530           then           then
531              echo "mpdboot with host file $HOSTFILE for $ESCRIPT_NUM_NODES nodes failed."              echo "mpdboot with host file $ESCRIPT_HOSTFILE for $ESCRIPT_NUM_NODES nodes failed."
532              exit 1              exit 1
533           else           else
534               if [ ! -z $ESCRIPT_VERBOSE ]; then echo "mpdboot was started with host file $HOSTFILE for $ESCRIPT_NUM_NODES nodes."; fi               if [ ! -z $ESCRIPT_VERBOSE ]; then echo "mpdboot was started with host file $HOSTFILE for $ESCRIPT_NUM_NODES nodes."; fi

Legend:
Removed from v.4973  
changed lines
  Added in v.4993

  ViewVC Help
Powered by ViewVC 1.1.26