1 LLC := ../tools/Debug/llc
2 AS := ../tools/Debug/as
5 TESTS := $(wildcard *.ll)
7 LLCTESTS := $(shell /bin/ls *.ll | grep -v testmemory | grep -v testswitch | grep -v sumarray | grep -v globalvars)
10 test all : testasmdis testopt testcodegen
11 @echo "All tests successfully completed!"
13 testasmdis : $(TESTS:%.ll=%.ll.asmdis)
14 @echo "All assembler/disassembler test succeeded!"
16 testopt : $(TESTS:%.ll=%.ll.opt)
18 testselect : $(LLCTESTS:%.ll=%.mc)
20 testsched : $(LLCTESTS:%.ll=%.mc)
22 testcodegen : $(LLCTESTS:%.ll=%.mc)
25 rm -f *.[123] *.bc *.mc core
28 @echo "Running assembler/disassembler test on $<"
29 @./TestAsmDisasm.sh $<
32 @echo "Running optimizier test on $<"
33 @./TestOptimizer.sh $<
38 %.mc: %.ll $(LLC) $(AS)
39 @echo "Generating machine instructions for $<"
40 $(AS) < $< | $(LLC) -dsched=t > $@