[project @ 2000-05-10 09:00:20 by sewardj]
[ghc-hetmet.git] / ghc / interpreter / connect.h
index 3c9d858..430e130 100644 (file)
@@ -9,8 +9,8 @@
  * included in the distribution.
  *
  * $RCSfile: connect.h,v $
- * $Revision: 1.34 $
- * $Date: 2000/04/04 01:07:49 $
+ * $Revision: 1.41 $
+ * $Date: 2000/05/10 09:00:20 $
  * ------------------------------------------------------------------------*/
 
 /* --------------------------------------------------------------------------
@@ -18,7 +18,7 @@
  * Texts, Names, Instances, Classes, Types, Kinds and Modules
  * ------------------------------------------------------------------------*/
 
-extern Text  textPrimPrel;
+extern Text  textPrelPrim;
 extern Text  textPrelude;
 extern Text  textNum;                   /* used to process default decls   */
 extern Text  textCcall;                 /* used to process foreign import  */
@@ -221,7 +221,7 @@ extern Type typeST;
 extern Type typeIO;
 extern Type typeException;
 
-extern Module modulePrimPrel;
+extern Module modulePrelPrim;
 extern Module modulePrelude;
 
 extern Kind   starToStar;                /* Type -> Type                    */
@@ -312,6 +312,7 @@ extern Int    whnfInt;                  /* integer value of term in whnf   */
 extern Float  whnfFloat;                /* float value of term in whnf     */
 extern Long   numCells;                 /* number of cells allocated       */
 extern Int    numGcs;                   /* number of garbage collections   */
+extern int    numEnters;               /* number of enters                */
 extern Bool   preludeLoaded;            /* TRUE => prelude has been loaded */
 extern Bool   flagAssert;               /* TRUE => assert False <e> causes
                                                    an assertion failure    */
@@ -327,6 +328,9 @@ extern List   diVars;                   /* deriving: cache of names        */
 extern Int    diNum;                    /* also for deriving               */
 extern List   cfunSfuns;                /* List of (Cfun,[SelectorVar])    */
 
+extern Module moduleBeingParsed;        /* so the parser (topModule) knows */
+
+
 #if USE_PREPROCESSOR
 extern String preprocessor;             /* preprocessor command            */
 #endif
@@ -522,20 +526,6 @@ extern FILE *outputStream;             /* current output stream            */
 extern Int  outColumn;                 /* current output column number     */
 
 
-
-/*---------------------------------------------------------------------------
- * Crude profiling (probably doesn't work)
- *-------------------------------------------------------------------------*/
-
-#ifdef CRUDE_PROFILING
-extern void cp_init             ( void );
-extern void cp_enter            ( Cell /*StgVar*/ );
-extern void cp_bill_words       ( int );
-extern void cp_bill_insns       ( int );
-extern void cp_show             ( void );
-#endif
-
-
 /*---------------------------------------------------------------------------
  * For dynamic.c and general object-related stuff
  *-------------------------------------------------------------------------*/
@@ -587,19 +577,6 @@ extern HugsBreakAction setBreakAction ( HugsBreakAction );
  * Environment variables and the registry
  *-------------------------------------------------------------------------*/
 
-/* On Win32 we can use the registry to supplement info in environment 
- * variables.
- */
-/* AJG: Commented out for now for development */
-/* #define USE_REGISTRY (HAVE_WINDOWS_H && !__MSDOS__) */
-
-#ifdef USE_REGISTRY
-Bool   writeRegString          ( String var, String val );
-String         readRegString           ( String var, String def );
-Int    readRegInt              ( String var, Int def );
-Bool   writeRegInt             ( String var, Int val );
-#endif
-
 #define N_INSTALLDIR 200
 extern char installDir[N_INSTALLDIR];
 
@@ -653,6 +630,8 @@ extern void     exit            ( int );
 # define filenamecmp(s1,s2) strcmp(s1,s2)
 #endif
 
+#define HI_ENDING ".u_hi"
+
 
 /*---------------------------------------------------------------------------
  * Pipe-related operations:
@@ -795,7 +774,6 @@ extern Command readCommand      ( struct cmd *, Char, Char );
  * Freevar analysis: list of free vars after
  * Lambda lifting:   freevar list or UNIT on input, discarded after
  * Code generation:  unused
- * Optimisation:     number of uses (sort-of) of let-bound variable
  * ------------------------------------------------------------------------*/
 
 typedef Cell   StgRhs;
@@ -893,16 +871,12 @@ extern  Name  implementRecShw        ( Text );
 extern  Name  implementRecEq         ( Text );
 #endif
 
-/* Association list storing globals assigned to dictionaries, tuples, etc */
-extern List stgGlobals;
-
-extern List    liftBinds        ( List binds );
+extern void    liftModule       ( Module );
 extern StgExpr substExpr        ( List sub, StgExpr e );
 extern List    freeVarsBind     ( List, StgVar );
 
 
-extern Void    cgBinds          ( StgRhs );
-extern void*   closureOfVar     ( StgVar );
+extern Void    cgModule         ( Module );
 extern char*   lookupHugsName   ( void* );