3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-08-06 11:20:27 +00:00

Add optional SEED=n command line option to Makefile, and -S n command line option to test scripts, for deterministic regression tests.

This commit is contained in:
Eric Smith 2016-09-15 02:00:29 -06:00
parent d8ad889594
commit f4240cc8a4
14 changed files with 175 additions and 24 deletions

View file

@ -5,10 +5,22 @@
set -e
OPTIND=1
count=100
seed="" # default to no seed specified
while getopts "c:S:" opt
do
case "$opt" in
c) count="$OPTARG" ;;
S) seed="-S $OPTARG" ;;
esac
done
shift "$((OPTIND-1))"
rm -rf temp
mkdir -p temp
echo "generating tests.."
python3 generate.py
python3 generate.py -c $count $seed
echo "running tests.."
for i in $( ls temp/*.ys | sed 's,[^0-9],,g; s,^0*\(.\),\1,g;' ); do