From 3d4dba8892d9d17e80cf7f4c76e61267876ab8f0 Mon Sep 17 00:00:00 2001 From: sewardj Date: Thu, 24 Feb 2000 14:05:55 +0000 Subject: [PATCH 1/1] [project @ 2000-02-24 14:05:55 by sewardj] Wibbles for Win32 standalone compilation of Hugs: -- Turn off debugging miniinterpreter -- Change SIZEOF_INTP (which no longer exists) into SIZEOF_VOID_P --- ghc/interpreter/machdep.c | 8 ++++---- ghc/interpreter/storage.c | 8 ++++---- ghc/interpreter/storage.h | 7 ++++--- ghc/rts/StgCRun.c | 4 ++-- 4 files changed, 14 insertions(+), 13 deletions(-) diff --git a/ghc/interpreter/machdep.c b/ghc/interpreter/machdep.c index f8536ca..ad1d572 100644 --- a/ghc/interpreter/machdep.c +++ b/ghc/interpreter/machdep.c @@ -13,8 +13,8 @@ * included in the distribution. * * $RCSfile: machdep.c,v $ - * $Revision: 1.18 $ - * $Date: 1999/12/20 16:55:27 $ + * $Revision: 1.19 $ + * $Date: 2000/02/24 14:05:55 $ * ------------------------------------------------------------------------*/ #ifdef HAVE_SIGNAL_H @@ -942,7 +942,7 @@ void gcCStack() { Void gcCStack() { /* Garbage collect elements off */ Cell stackTop = NIL; /* C stack */ Cell *ptr = &stackTop; -#if SIZEOF_INTP == 2 +#if SIZEOF_VOID_P == 2 if (((long)(ptr) - (long)(CStackBase))&1) fatal("gcCStack"); #elif STACK_ALIGNMENT == 2 /* eg Macintosh 68000 */ @@ -972,7 +972,7 @@ Void gcCStack() { /* Garbage collect elements off */ GuessDirection; #endif -#if SIZEOF_INTP==4 && STACK_ALIGNMENT == 2 /* eg Macintosh 68000 */ +#if SIZEOF_VOID_P==4 && STACK_ALIGNMENT == 2 /* eg Macintosh 68000 */ ptr = (Cell *)((long)(&stackTop) + 2); StackGrowsDown; #endif diff --git a/ghc/interpreter/storage.c b/ghc/interpreter/storage.c index d6db5f3..39d969f 100644 --- a/ghc/interpreter/storage.c +++ b/ghc/interpreter/storage.c @@ -9,8 +9,8 @@ * included in the distribution. * * $RCSfile: storage.c,v $ - * $Revision: 1.43 $ - * $Date: 2000/02/15 13:16:20 $ + * $Revision: 1.44 $ + * $Date: 2000/02/24 14:05:55 $ * ------------------------------------------------------------------------*/ #include "prelude.h" @@ -2441,7 +2441,7 @@ Int n; { : pair(INTCELL,n); } -#if SIZEOF_INTP == SIZEOF_INT +#if SIZEOF_VOID_P == SIZEOF_INT typedef union {Int i; Ptr p;} IntOrPtr; Cell mkPtr(p) Ptr p; @@ -2475,7 +2475,7 @@ Cell c; x.i = snd(c); return x.p; } -#elif SIZEOF_INTP == 2*SIZEOF_INT +#elif SIZEOF_VOID_P == 2*SIZEOF_INT typedef union {struct {Int i1; Int i2;} i; Ptr p;} IntOrPtr; Cell mkPtr(p) Ptr p; diff --git a/ghc/interpreter/storage.h b/ghc/interpreter/storage.h index 8806d29..ea6a78d 100644 --- a/ghc/interpreter/storage.h +++ b/ghc/interpreter/storage.h @@ -10,8 +10,8 @@ * included in the distribution. * * $RCSfile: storage.h,v $ - * $Revision: 1.26 $ - * $Date: 2000/02/15 13:16:20 $ + * $Revision: 1.27 $ + * $Date: 2000/02/24 14:05:55 $ * ------------------------------------------------------------------------*/ /* -------------------------------------------------------------------------- @@ -300,7 +300,8 @@ extern Ptr cptrOf Args((Cell)); #define DICTAP 80 /* DICTAP snd :: (QClassId,[Type]) */ #define UNBOXEDTUP 81 /* UNBOXEDTUP snd :: [Type] */ -#if SIZEOF_INTP != SIZEOF_INT +#if SIZEOF_VOID_P != SIZEOF_INT +wuiwiuwuiwmn SIZEOF_INT cc #define PTRCELL 82 /* C Heap Pointer snd :: (Int,Int) */ #endif diff --git a/ghc/rts/StgCRun.c b/ghc/rts/StgCRun.c index 5f732cc..c2eb50f 100644 --- a/ghc/rts/StgCRun.c +++ b/ghc/rts/StgCRun.c @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: StgCRun.c,v 1.11 2000/02/15 13:16:20 sewardj Exp $ + * $Id: StgCRun.c,v 1.12 2000/02/24 14:05:55 sewardj Exp $ * * (c) The GHC Team, 1998-1999 * @@ -38,7 +38,7 @@ static jmp_buf jmp_environment; -#if 0 +#if 1 extern StgThreadReturnCode StgRun(StgFunPtr f, StgRegTable *basereg) { -- 1.7.10.4