diff options
author | Yann Herklotz <ymherklotz@gmail.com> | 2018-03-10 22:53:48 +0000 |
---|---|---|
committer | Yann Herklotz <ymherklotz@gmail.com> | 2018-03-10 22:53:48 +0000 |
commit | 733e278a3c20988cfe1ae386fe057945a805bbb3 (patch) | |
tree | 33768c321ed595677a456c2c104944df275a4b5e /test_compiler.sh | |
parent | e05e2206c362c541766c0b12abdfd4355c4b232a (diff) | |
download | Compiler-733e278a3c20988cfe1ae386fe057945a805bbb3.tar.gz Compiler-733e278a3c20988cfe1ae386fe057945a805bbb3.zip |
[Doc] Writing more
Diffstat (limited to 'test_compiler.sh')
-rwxr-xr-x | test_compiler.sh | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/test_compiler.sh b/test_compiler.sh index 23e2749..cae3988 100755 --- a/test_compiler.sh +++ b/test_compiler.sh @@ -10,7 +10,7 @@ echo " Force building lexer" make -B bin/c_compiler if [[ "$?" -ne 0 ]]; then - echo "Build failed."; + echo "Build failed."; fi echo "" @@ -26,15 +26,15 @@ mkdir -p c_compiler/test/ref for i in c_compiler/test/in/*.c; do echo "===========================" - echo "" - echo "Input file : ${i}" + echo "" + echo "Input file : ${i}" BASENAME=$(basename $i .c); - cat $i | ./bin/c_compiler > c_compiler/test/out/$BASENAME.s 2> c_compiler/test/out/$BASENAME.stderr.txt + cat $i | ./bin/c_compiler > c_compiler/test/out/$BASENAME.s 2> c_compiler/test/out/$BASENAME.stderr.txt mips-linux-gnu-gcc -O0 -S -c c_compiler/test/in/$BASENAME.c -o c_compiler/test/ref/$BASENAME.s mips-linux-gnu-gcc -O0 -static c_compiler/test/ref/$BASENAME.s -o c_compiler/test/ref/$BASENAME - mips-linux-gnu-gcc -O0 -static c_compiler/test/out/$BASENAME.s -o c_compiler/test/out/$BASENAME + mips-linux-gnu-gcc -O0 -static c_compiler/test/out/$BASENAME.s -o c_compiler/test/out/$BASENAME qemu-mips c_compiler/test/ref/$BASENAME REFOUTPUT=$? |