From: rrt Date: Tue, 27 Mar 2001 16:32:46 +0000 (+0000) Subject: [project @ 2001-03-27 16:32:46 by rrt] X-Git-Tag: Approximately_9120_patches~2283 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=7ae5071bfe0842bf8bf83655dcd3345577c84659;p=ghc-hetmet.git [project @ 2001-03-27 16:32:46 by rrt] Tweaks to make it work a bit better. --- diff --git a/ghc/compiler/Makefile b/ghc/compiler/Makefile index d328b7e..4dc4ca4 100644 --- a/ghc/compiler/Makefile +++ b/ghc/compiler/Makefile @@ -1,5 +1,5 @@ # ----------------------------------------------------------------------------- -# $Id: Makefile,v 1.149 2001/03/27 10:32:42 simonmar Exp $ +# $Id: Makefile,v 1.150 2001/03/27 16:32:46 rrt Exp $ TOP = .. include $(TOP)/mk/boilerplate.mk @@ -85,11 +85,12 @@ ifeq ($(GhcWithNativeCodeGen),YES) DIRS += nativeGen else SRC_HC_OPTS += -DOMIT_NATIVE_CODEGEN +endif + ifeq ($(GhcWithIlx),YES) DIRS += ilxGen SRC_HC_OPTS += -DILX endif -endif ifeq "$(BootingFromHc)" "YES" # HC files are always from a self-booted compiler @@ -170,6 +171,7 @@ ifneq "$(mingw32_TARGET_OS)" "1" SRC_HC_OPTS += -package concurrent -package posix -package text -package util else SRC_HC_OPTS += -package concurrent -package text -package util +main/TmpFiles_HC_OPTS += -Dmingw32_TARGET_OS endif SRC_CC_OPTS += -Iparser -I. -I$(TOP)/includes -O diff --git a/ghc/compiler/ilxGen/tests/Makefile b/ghc/compiler/ilxGen/tests/Makefile index 24aa4de..115c0f4 100644 --- a/ghc/compiler/ilxGen/tests/Makefile +++ b/ghc/compiler/ilxGen/tests/Makefile @@ -1,7 +1,7 @@ include ../../../lib/std/Makefile.src # These settings are if you use a visual studio build -CVS=/cvs/cvs +CVS=cvs CORENV_DEBUG= CORENV_RETAIL= LOCALRUN=./ @@ -13,13 +13,13 @@ LOCALRUN=.\\ ILX_FAST= endif -ILXASM_HOME=/devel/fcom/src +ILXASM_HOME=C:/devel/fcom/src ILXASM=$(ILXASM_HOME)/bin/ilxasm$(ILX_FAST).exe ILVALID=$(ILXASM_HOME)/bin/ilvalid$(ILX_FAST).exe ILXASM_FLAGS=-l $(ILXASM_HOME)/ilxasm --no-ilasm --tailcall-indirect ghc: - $(MAKE) -C ../.. ilxGen/IlxGen.o hsc + $(MAKE) -C ../.. ghc ilxasm: $(MAKE) -C $(ILXASM_HOME) bin/ilxasm.exe @@ -89,8 +89,8 @@ ovgtprel: $(MAKE) -C ../../../lib/std ilxasm std.O.vmeth-erased.generic.traced.dll $(MAKE) -C $(ILXASM_HOME) bin/msilxlib.vmeth-erased.generic.traced.dll -%.o: %.hs ../../hsc.exe - ../../../driver/ghc-inplace -o $@ -c $*.hs +%.o: %.hs ../../ghc-4.11 + ../../ghc-inplace -o $@ -c $*.hs std_NONGENERIC_STATIC_IL=$(patsubst %.lhs,../../../lib/std/%.nongeneric.boxed.static.il,$(std_SRC)) ../../../lib/std/PrelGHC.nongeneric.boxed.static.il std_GENERIC_STATIC_IL=$(patsubst %.lhs,../../../lib/std/%.generic.static.il,$(std_SRC)) ../../../lib/std/PrelGHC.generic.static.il @@ -98,11 +98,11 @@ std_GENERIC_STATIC_IL=$(patsubst %.lhs,../../../lib/std/%.generic.static.il,$(st #======================================================================== # 1. From Haskell to ILX -%.Onot.ilx: %.hs ../../hsc.exe - ../../../driver/ghc-inplace -fglasgow-exts -o $@ -i../../../lib/std/.Onot -Onot --ilx $*.hs +%.Onot.ilx: %.hs ../../ghc-4.11 + ../../ghc-inplace -c -fglasgow-exts -o $@ -i../../../lib/std/.Onot -Onot -filx $*.hs -osuf Onot.ilx -%.O.ilx: %.hs ../../hsc.exe - ../../../driver/ghc-inplace -fglasgow-exts -o $@ -i../../../lib/std/.O -O --ilx $*.hs +%.O.ilx: %.hs ../../ghc-4.11 + ../../ghc-inplace -c -fglasgow-exts -o $@ -i../../../lib/std/.O -O -filx $*.hs -osuf O.ilx ../Entry.Onot.ilx: ../Entry.ilx sed -e "s|ilx std|ilx std.Onot|g" ../Entry.ilx > $@.tmp @@ -224,9 +224,10 @@ HSstd_cbits.dll: ../../../lib/std/cbits/HSstd_cbits.dll #------------------------------------------------------------------------ # From IL to .EXE -%.retail.exe: %.il +%.retail.exe: %.il ../Entry.Onot.mono.il + cat %.il ../Entry.Onot.mono.il > $@.tmp echo "$(CORENV_RETAIL)" > $@.bat - echo "ilasm -exe -quiet -out=$(subst /,\\,$@) $(subst /,\\,$<)" >> $@.bat + echo "ilasm -exe -quiet -out=$(subst /,\\,$@.tmp) $(subst /,\\,$<)" >> $@.bat time -p cmd /c $(subst /,\\,$@).bat rm $@.bat @@ -237,6 +238,7 @@ HSstd_cbits.dll: ../../../lib/std/cbits/HSstd_cbits.dll rm $@.bat #------------------------------------------------------------------------ # From .HS to .EXE without using ILX +# Used to run performance comparisons against native code GHC %.Onot.exe: %.hs ghc -Onot -o $@ $< @@ -244,7 +246,11 @@ HSstd_cbits.dll: ../../../lib/std/cbits/HSstd_cbits.dll %.O.exe: %.hs ghc -O -o $@ $< +%.o: %.hs ../../hsc.exe + ../../../driver/ghc-inplace -o $@ -c $*.hs +%.run: %.exe + time -p $< #------------------------------------------------------------------------ # Running: diff --git a/ghc/compiler/main/DriverPipeline.hs b/ghc/compiler/main/DriverPipeline.hs index 3464c57..04392a1 100644 --- a/ghc/compiler/main/DriverPipeline.hs +++ b/ghc/compiler/main/DriverPipeline.hs @@ -1,5 +1,5 @@ ----------------------------------------------------------------------------- --- $Id: DriverPipeline.hs,v 1.59 2001/03/26 12:28:15 simonmar Exp $ +-- $Id: DriverPipeline.hs,v 1.60 2001/03/27 16:32:46 rrt Exp $ -- -- GHC Driver -- @@ -148,6 +148,9 @@ genPipeline todo stop_flag persistent_output lang filename keep_hc <- readIORef v_Keep_hc_files keep_raw_s <- readIORef v_Keep_raw_s_files keep_s <- readIORef v_Keep_s_files +#ifdef ILX + writeIORef v_Object_suf (Just "ilx") +#endif osuf <- readIORef v_Object_suf let