mirror of
https://github.com/marketideas/qasm.git
synced 2025-02-05 15:30:33 +00:00
test
This commit is contained in:
parent
065a247cc2
commit
3286572aa7
3
asm.h
3
asm.h
@ -347,13 +347,14 @@ public:
|
||||
|
||||
std::string savepath;
|
||||
TSymbol *currentsym;
|
||||
TSymbol topSymbol;
|
||||
|
||||
std::string currentsymstr;
|
||||
std::vector<MerlinLine> lines;
|
||||
Poco::HashMap<std::string, TSymbol>opcodes;
|
||||
Poco::HashMap<std::string, TSymbol> macros;
|
||||
Poco::HashMap<std::string, TSymbol> symbols;
|
||||
Poco::HashMap<std::string, TSymbol> variables;
|
||||
TSymbol topSymbol;
|
||||
|
||||
TOriginSection PC;
|
||||
TLUPstruct curLUP;
|
||||
|
29
runtests.sh
29
runtests.sh
@ -25,6 +25,8 @@ for S in $SRC ; do
|
||||
S1=${S1/.S/.bin}
|
||||
S1=${S1/.s/.bin}
|
||||
|
||||
BASE=${S/.S/}
|
||||
BASE=${BASE/.s/}
|
||||
./qasm -o 0/$OUTDIR/$S1 ./testdata/$S >> $TMPFILE
|
||||
|
||||
R=?$
|
||||
@ -32,10 +34,33 @@ for S in $SRC ; do
|
||||
R=`cat $TMPFILE | grep "End qASM assembly"`
|
||||
E=`echo $R | awk -e '{ print $6; }'`
|
||||
ect=`echo $(($E))`
|
||||
|
||||
MSHA="Q"
|
||||
QSHA="M"
|
||||
|
||||
if [ -f ./testdata/M32_expected/$BASE ] ; then
|
||||
MSHA=`sha256sum ./testdata/M32_expected/$BASE | awk '{ print $1;}'` 2>/dev/null >/dev/null
|
||||
fi
|
||||
|
||||
if [ -f $OUTDIR/$BASE.bin ] ; then
|
||||
QSHA=`sha256sum $OUTDIR/$BASE.bin |awk '{print $1;}'` 2>/dev/null >/dev/null
|
||||
fi
|
||||
#echo "$MSHA $QSHA"
|
||||
|
||||
shapass=0;
|
||||
CX=" "
|
||||
|
||||
if [ "$MSHA""L" != "$QSHA""L" ] ; then
|
||||
shapass=1
|
||||
CX="!"
|
||||
fi
|
||||
|
||||
P="PASS: "
|
||||
TOTAL=$(($TOTAL+1))
|
||||
if [ $ect != 0 ] ; then
|
||||
printf 'FAIL: (%3s) ' $ect
|
||||
pct=$(($ect+$shapass))
|
||||
if [ $pct != 0 ] ; then
|
||||
printf 'FAIL: (%3s) ' $ect
|
||||
printf '%s ' $CX
|
||||
|
||||
FAILCT=$(($FAILCT+1))
|
||||
else
|
||||
|
21
todo.txt
21
todo.txt
@ -1,2 +1,19 @@
|
||||
2019-11-17 - BRK does not detect a lable that can't be evaluated
|
||||
2019-11-17 - ASCII parsing in both eval and for ASC type commands
|
||||
(0) 2019-11-17 - BRK does not detect a lable that can't be evaluated
|
||||
(0) 2019-11-17 - ASCII parsing in both eval and for ASC type commands
|
||||
(0) 2019-11-17 -s IF processing for character compare mode
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
(0) 2019-11-17 -s
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user