#!/bin/sh tc () { echo -n $1 ./smvtoaig log/$1.smv log/$1.aig || exit 1 ./aigtosmv -b log/$1.aig log/$1.smvfromaig || exit 1 old="`nusmv log/$1.smv 2>/dev/null|grep tion\ AG|awk '{printf $NF}'`" echo -n " $old" new="`nusmv log/$1.smvfromaig 2>/dev/null|grep tion\ AG|awk '{print $NF}'`" echo -n " $new" if [ $old = $new ] then ok=`expr $ok + 1` echo " OK" else failed=`expr $failed + 1` echo " FAILED" fi } ok=0 failed=0 tc inittrans0det tc inittrans0 tc inittrans1det tc inittrans1 tc initinvar0 tc initinvar1 tc nonext tc cnt1e tc cnt1re tc cnt1 tc cnt2e tc cnt2re tc cnt2 tc cnt3e tc cnt3re tc cnt3 tc nonext tc regr0 tc dp2 tc dp3 tc dp4 tc nextnoinit echo "$ok ok, $failed failed"