2001-06-06 20:29:01 +00:00
|
|
|
#!/bin/sh
|
|
|
|
# test that every step outputs something that is consumable by
|
|
|
|
# another step
|
|
|
|
|
|
|
|
rm -f test.bc.temp[12]
|
|
|
|
|
|
|
|
LD_LIBRARY_PATH=../lib/Assembly/Parser/Debug:../lib/Assembly/Writer/Debug:../lib/Analysis/Debug:../lib/VMCore/Debug:../lib/Bytecode/Writer/Debug:../lib/Bytecode/Reader/Debug:../lib/Optimizations/Debug
|
|
|
|
export LD_LIBRARY_PATH
|
|
|
|
|
|
|
|
# Two full cycles are needed for bitwise stability
|
|
|
|
|
2001-09-07 16:58:39 +00:00
|
|
|
../tools/as/as < $1 > $1.bc.1 || exit 1
|
2001-06-06 20:29:01 +00:00
|
|
|
../tools/dis/dis < $1.bc.1 > $1.ll.1 || exit 2
|
|
|
|
../tools/as/as < $1.ll.1 > $1.bc.2 || exit 3
|
|
|
|
../tools/dis/dis < $1.bc.2 > $1.ll.2 || exit 4
|
|
|
|
|
|
|
|
diff $1.ll.[12] || exit 7
|
2001-07-26 16:30:18 +00:00
|
|
|
|
|
|
|
# FIXME: When we sort things correctly and deterministically, we can reenable this
|
|
|
|
#diff $1.bc.[12] || exit 8
|
2001-06-06 20:29:01 +00:00
|
|
|
|
|
|
|
rm $1.[bl][cl].[12]
|
|
|
|
|