[llvm-commits] CVS: llvm/projects/Stacker/samples/Makefile

Reid Spencer reid at x10sys.com
Wed Oct 27 21:08:16 PDT 2004



Changes in directory llvm/projects/Stacker/samples:

Makefile updated: 1.4 -> 1.5
---
Log message:

Use llvmc to compile the Stacker programs

---
Diffs of the changes:  (+7 -30)

Index: llvm/projects/Stacker/samples/Makefile
diff -u llvm/projects/Stacker/samples/Makefile:1.4 llvm/projects/Stacker/samples/Makefile:1.5
--- llvm/projects/Stacker/samples/Makefile:1.4	Wed Oct 27 18:18:45 2004
+++ llvm/projects/Stacker/samples/Makefile	Wed Oct 27 23:08:05 2004
@@ -16,49 +16,26 @@
 
 SAMPLES = fibonacci hello prime
 
-LLC_EXEC = $(BUILD_OBJ_ROOT)/tools/$(CONFIGURATION)/llc
-OPT_EXEC = $(BUILD_OBJ_ROOT)/tools/$(CONFIGURATION)/opt
-STKRC_EXEC = $(BUILD_OBJ_ROOT)/tools/$(CONFIGURATION)/stkrc
-LLVMDIS_EXEC = $(BUILD_OBJ_ROOT)/tools/$(CONFIGURATION)/llvm-dis
+LLVMC_EXEC = $(TOOLDIR)/llvmc
 
 all :: $(SAMPLES)
 
 ifdef OPTIMIZE
 % : %.st 
-	@$(ECHO) "Compiling and Optimizing $< to $*.bc"
-	$(VERB)$(STKRC_EXEC) -e -o - $< | opt -stats -q -f -o $*.bc \
-	    -aa-eval -adce -branch-combine -cee -constmerge -constprop -dce -die -ds-aa \
-	    -ds-opt -gcse -globaldce -indvars -inline -instcombine \
-	    -ipconstprop -licm -loopsimplify -mem2reg -pre -sccp -simplifycfg \
-	    -tailcallelim -verify
+	@$(ECHO) "Compiling and Optimizing $(<F)"
+	$(VERB)$(LLVMC_EXEC) -O3 $< -o $@
 else
-%.bc : %.st
-	@$(ECHO) "Compiling $< to $*.bc"
-	$(VERB)$(STKRC_EXEC) -e -f -o $*.bc $< 
+% : %.st
+	@$(ECHO) "Compiling $(<F)"
+	$(VERB)$(LLVMC_EXEC) $< -o $@
 endif
 
-%.s : %.bc
-	@$(ECHO) "Compiling $< to $*.s"
-	$(VERB)$(LLC_EXEC) -f -o $*.s $<
-
-% : %.s
-	@$(ECHO) "Compiling and Linking $< to $*"
-	$(VERB)gcc -g -L$(BUILD_OBJ_ROOT)/lib/$(CONFIGURATION) -lstkr_runtime -o $* $*.s
-
-%.ll : %.bc
-	@$(ECHO) "Disassembling $< to $*.ll"
-	$(VERB)$(LLVMDIS_EXEC) -f -o $*.ll $<
-
-%.bc :  $(STKRC_EXEC)
-
-.PRECIOUS: %.bc %.s %.ll %.st
-
 SAMPLES_LL = $(SAMPLES:%=%.ll)
 SAMPLES_BC = $(SAMPLES:%=%.bc)
 SAMPLES_S  = $(SAMPLES:%=%.s)
 
 clean ::
-	$(VERB)rm -f gmon.out $(SAMPLES_LL) $(SAMPLES_BC) $(SAMPLES_S) $(SAMPLES)
+	$(VERB)rm -f gmon.out $(SAMPLES)
 #
 # Include the Master Makefile that knows how to build all.
 #






More information about the llvm-commits mailing list