Changeset 126 for trunk/IPs/systemC/processor/Morpheo/Script/execute_n.sh
- Timestamp:
- Jun 17, 2009, 8:10:41 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/IPs/systemC/processor/Morpheo/Script/execute_n.sh
r124 r126 27 27 function execute_n_usage () 28 28 { 29 echo "Usage : ${0} path_word file [ nb_process ]";29 echo "Usage : ${0} path_word file_cmd file_cpt [ nb_process ]"; 30 30 echo "Arguments : "; 31 31 echo " * path_work : directory to execute command"; 32 echo " * file : list of command"; 32 echo " * file_cmd : list of command"; 33 echo " * file_cpt : file to control"; 33 34 echo " * nb_process : number of process (default (and maximum) is the number of processor)"; 34 35 echo ""; … … 45 46 function execute_n_test_usage () 46 47 { 47 if test ${#} -ne 2 -a ${#} -ne 3; then48 if test ${#} -ne 3 -a ${#} -ne 4; then 48 49 execute_n_usage; 49 50 fi; … … 76 77 local PATH_WORK=${1}; 77 78 local FILE_CMD=${2}; 78 local FILE_CPT ;79 local FILE_CPT=${3}; 79 80 local FILE_CPU; 80 81 local ID="cpu-${HOSTNAME}-$$" … … 82 83 execute_n_test_usage ${*}; 83 84 84 if test ${#} -eq 3; then85 if test ${ 3} -lt ${NB_PROCESS}; then86 NB_PROCESS=${ 3};85 if test ${#} -eq 4; then 86 if test ${4} -lt ${NB_PROCESS}; then 87 NB_PROCESS=${4}; 87 88 fi; 88 89 fi; 89 90 90 FILE_CPT="${PATH_WORK}/control-"$(basename ${FILE_CMD});91 91 FILE_CPU="${PATH_WORK}/${ID}"; 92 92
Note: See TracChangeset
for help on using the changeset viewer.