Changeset 143

Show
Ignore:
Timestamp:
05/30/07 17:59:38
Author:
apokayi
Message:

modified the collectives script for portability

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • guts_collectives/guts_collectives.sh

    r131 r143  
    1414 
    1515# Initial cleanup 
    16 if [ -e units.passed ]; then 
     16if test -f units.passed; then 
    1717        rm -f units.passed 
    1818fi 
    1919 
    20 if [ -e units.notpassed ]; then 
     20if test -f units.notpassed; then 
    2121        rm -f units.notpassed 
    2222fi 
    2323 
    24 echo -ne "\n\n" 
    25 echo -e "_______________      Script for compiling and running GUTS      _______________\n" 
     24printf "\n\n" 
     25printf "_______________      Script for compiling and running GUTS      _______________\n\n" 
    2626 
    2727NP=$1 
     
    2929 
    3030echo "Running the testing suite for ${NP} threads" 
    31 echo -ne "\n" 
     31printf "\n" 
    3232 
    3333UPCC=upcc 
    3434 
    3535for UNIT in `cat ${UNITS}`; do 
    36         echo -e "-------------->      Working on unit -- $UNIT\n" 
     36        printf ">-------------->      Working on unit -- $UNIT\n" 
    3737 
    3838        build_output=`$UPCC upc_collective.o $UNIT.c -o $UNIT` 
    3939 
    40         if [ $? -eq 0 ] ; then 
     40        if test $? -eq 0; then 
    4141                echo "Compilation was SUCCESSFUL for the unit [${UNIT}]" 
    4242                echo "Now the unit [${UNIT}] will be run for ${NP} threads ..." 
     
    4444                echo $RUN 
    4545                exe_output=`$RUN`  
    46                 if [ $? -eq 0 ] ; then 
     46                if test $? -eq 0 ; then 
    4747                        echo $exe_output 
    4848                else 
     
    5757 
    5858        `rm -f ${UNIT}.o ${UNIT} ${UNIT}.*out` 
    59         echo -ne "\n" 
    60         echo -e "===============================================================================\n" 
     59        printf "\n" 
     60        printf "===============================================================================\n\n" 
    6161 
    6262done