#!/bin/bash wait_qstat() { #astept finalizarea executiei while [ `qstat | wc -l` != 0 ] do sleep 1 done } #compilez sursele for MAKEFILE in `ls makefile*` do make -f $MAKEFILE done for SOLARSIM in `ls bin` do for THREADS in 1 2 3 4 5 6 7 8 do let "SIM_STEPS = 3075840" qsub -q ibm-quad.q -cwd run.sh $THREADS bin/$SOLARSIM data/astro.dat /dev/null $SIM_STEPS 100 0 done done wait_qstat cat $PWD/run.sh.* | \ grep -v "Warning: no access to tty (Bad file descriptor)." | \ grep -v "Thus no job control in this shell." rm run.sh.* rm bin/*