137 |
if [ $quick -eq 0 -o ! -r Makefile ]; then |
if [ $quick -eq 0 -o ! -r Makefile ]; then |
138 |
printf 'genmake ... ' 1>&2 |
printf 'genmake ... ' 1>&2 |
139 |
if [ $ieee -eq 0 ]; then |
if [ $ieee -eq 0 ]; then |
140 |
../../../tools/genmake -mods=../code > make.log 2>&1 |
../../../tools/$genmake -mods=../code > make.log 2>&1 |
141 |
else |
else |
142 |
../../../tools/genmake -ieee -mods=../code > make.log 2>&1 |
../../../tools/$genmake -ieee -mods=../code > make.log 2>&1 |
143 |
fi |
fi |
144 |
if [ $? -ne 0 ]; then |
if [ $? -ne 0 ]; then |
145 |
tail make.log |
tail make.log |
146 |
echo genmakemodel: genmake failed 1>&2 |
echo genmakemodel: $genmake failed 1>&2 |
147 |
return 1 |
return 1 |
148 |
else |
else |
149 |
echo succesful 1>&2 |
echo succesful 1>&2 |
331 |
-noieee By default, $0 uses the -ieee option for genmake. This turns it off. |
-noieee By default, $0 uses the -ieee option for genmake. This turns it off. |
332 |
-cleanup Aggresively removes all model output, executables and object files |
-cleanup Aggresively removes all model output, executables and object files |
333 |
and then exits. Use with care. |
and then exits. Use with care. |
334 |
|
-2 Use genmake2 rather than genmake |
335 |
|
|
336 |
Normal usage: |
Normal usage: |
337 |
$0 * Configure, compile, run and analyze in all experiment directories |
$0 * Configure, compile, run and analyze in all experiment directories |
376 |
ieee=1 |
ieee=1 |
377 |
longtest=1 |
longtest=1 |
378 |
expts='' |
expts='' |
379 |
|
genmake=genmake |
380 |
|
|
381 |
# Process arguments |
# Process arguments |
382 |
for arg in $@ |
for arg in $@ |
388 |
-debug) debug=1;; |
-debug) debug=1;; |
389 |
-force) force=1;; |
-force) force=1;; |
390 |
-clean) clean=1;; |
-clean) clean=1;; |
391 |
|
-2) genmake=genmake2;; |
392 |
-noieee) ieee=0;; |
-noieee) ieee=0;; |
393 |
-shorttest) longtest=0;; |
-shorttest) longtest=0;; |
394 |
-quiet) verbose=0;; |
-quiet) verbose=0;; |
444 |
echo |
echo |
445 |
echo Experiment: $dir |
echo Experiment: $dir |
446 |
echo |
echo |
447 |
unset genmake makedepend make run |
unset genmakepass makedepend make run |
448 |
if [ $longtest -gt 0 ]; then |
if [ $longtest -gt 0 ]; then |
449 |
results='-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --' |
results='-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --' |
450 |
else |
else |
461 |
builddir=input |
builddir=input |
462 |
rundir=input |
rundir=input |
463 |
fi |
fi |
464 |
genmakemodel $dir/$builddir && genmake=Y \ |
genmakemodel $dir/$builddir && genmakepass=Y \ |
465 |
&& makecleancompile $dir/$builddir \ |
&& makecleancompile $dir/$builddir \ |
466 |
&& makedependmodel $dir/$builddir && makedepend=Y \ |
&& makedependmodel $dir/$builddir && makedepend=Y \ |
467 |
&& makemodel $dir/$builddir && make=Y \ |
&& makemodel $dir/$builddir && make=Y \ |
470 |
&& results=`testoutput $dir $rundir` \ |
&& results=`testoutput $dir $rundir` \ |
471 |
&& makecleanupafter $dir/$builddir |
&& makecleanupafter $dir/$builddir |
472 |
echo |
echo |
473 |
formatresults $dir ${genmake:-N} ${makedepend:-N} ${make:-N} ${run:-N} $results |
formatresults $dir ${genmakepass:-N} ${makedepend:-N} ${make:-N} ${run:-N} $results |
474 |
echo |
echo |
475 |
formatresults $dir ${genmake:-N} ${makedepend:-N} ${make:-N} ${run:-N} $results >> summary.txt |
formatresults $dir ${genmakepass:-N} ${makedepend:-N} ${make:-N} ${run:-N} $results >> summary.txt |
476 |
fi |
fi |
477 |
done |
done |
478 |
|
|