diff options
author | clairexen <claire@symbioticeda.com> | 2020-10-01 18:12:31 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-01 18:12:31 +0200 |
commit | 2412e754953595627e8c87ff0aa773929c71a852 (patch) | |
tree | bc02013f6312a0c1cb8351e213bd7e08255d79f9 /tests/opt_share/run-test.sh | |
parent | c4bfbecca60eaf8c02a792627c1e49b5dde3cdeb (diff) | |
parent | bed14241efbf9949d0ed9d84836d7a019895dfde (diff) | |
download | yosys-2412e754953595627e8c87ff0aa773929c71a852.tar.gz yosys-2412e754953595627e8c87ff0aa773929c71a852.tar.bz2 yosys-2412e754953595627e8c87ff0aa773929c71a852.zip |
Merge pull request #2380 from Xiretza/parallel-tests
Clean up and parallelize testsuite
Diffstat (limited to 'tests/opt_share/run-test.sh')
-rwxr-xr-x | tests/opt_share/run-test.sh | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/tests/opt_share/run-test.sh b/tests/opt_share/run-test.sh index e01552646..e0008a259 100755 --- a/tests/opt_share/run-test.sh +++ b/tests/opt_share/run-test.sh @@ -22,12 +22,23 @@ mkdir -p temp echo "generating tests.." python3 generate.py -c $count $seed +{ + echo ".PHONY: all" + echo "all:" + + for i in $( ls temp/*.ys | sed 's,[^0-9],,g; s,^0*\(.\),\1,g;' ); do + idx=$( printf "%05d" $i ) + echo ".PHONY: test-$idx" + echo "all: test-$idx" + echo "test-$idx:" + printf "\t@%s\n" \ + "echo -n [$i]" \ + "../../yosys -ql temp/uut_${idx}.log temp/uut_${idx}.ys" + done +} > temp/makefile + echo "running tests.." -for i in $( ls temp/*.ys | sed 's,[^0-9],,g; s,^0*\(.\),\1,g;' ); do - echo -n "[$i]" - idx=$( printf "%05d" $i ) - ../../yosys -ql temp/uut_${idx}.log temp/uut_${idx}.ys -done +${MAKE:-make} -f temp/makefile echo failed_share=$( echo $( gawk '/^#job#/ { j=$2; db[j]=0; } /^Removing [246] cells/ { delete db[j]; } END { for (j in db) print(j); }' temp/all_share_log.txt ) ) |