/* -----------------------------------------------------------------------------
- * $Id: StgMacros.h,v 1.33 2000/08/15 14:18:43 simonmar Exp $
+ * $Id: StgMacros.h,v 1.38 2001/07/24 06:31:35 ken Exp $
*
* (c) The GHC Team, 1998-1999
*
} \
} \
} \
- SET_INFO(R1.cl,&BLACKHOLE_info)
+ SET_INFO(R1.cl,&stg_BLACKHOLE_info)
# define UPD_BH_SINGLE_ENTRY(info) \
TICK_UPD_BH_SINGLE_ENTRY(); \
{ \
} \
} \
} \
- SET_INFO(R1.cl,&BLACKHOLE_info)
+ SET_INFO(R1.cl,&stg_BLACKHOLE_info)
# else
# define UPD_BH_UPDATABLE(info) \
TICK_UPD_BH_UPDATABLE(); \
- SET_INFO(R1.cl,&BLACKHOLE_info)
+ SET_INFO(R1.cl,&stg_BLACKHOLE_info)
# define UPD_BH_SINGLE_ENTRY(info) \
TICK_UPD_BH_SINGLE_ENTRY(); \
- SET_INFO(R1.cl,&SE_BLACKHOLE_info)
+ SET_INFO(R1.cl,&stg_SE_BLACKHOLE_info)
# endif
#else /* !EAGER_BLACKHOLING */
# define UPD_BH_UPDATABLE(thunk) /* nothing */
y.iu.dlo = p_src[1];
return(y.i);
}
+
+#elif SIZEOF_VOID_P == 8
+
+static inline void ASSIGN_Word64(W_ p_dest[], StgWord64 src)
+{
+ p_dest[0] = src;
+}
+
+static inline StgWord64 PK_Word64(W_ p_src[])
+{
+ return p_src[0];
+}
+
+static inline void ASSIGN_Int64(W_ p_dest[], StgInt64 src)
+{
+ p_dest[0] = src;
+}
+
+static inline StgInt64 PK_Int64(W_ p_src[])
+{
+ return p_src[0];
+}
+
#endif
/* -----------------------------------------------------------------------------
Catch frames
-------------------------------------------------------------------------- */
-extern DLL_IMPORT_DATA const StgPolyInfoTable catch_frame_info;
+extern DLL_IMPORT_RTS const StgPolyInfoTable stg_catch_frame_info;
/* -----------------------------------------------------------------------------
Seq frames
an update...
-------------------------------------------------------------------------- */
-extern DLL_IMPORT_DATA const StgPolyInfoTable seq_frame_info;
+extern DLL_IMPORT_RTS const StgPolyInfoTable stg_seq_frame_info;
#define PUSH_SEQ_FRAME(sp) \
{ \
StgSeqFrame *__frame; \
TICK_SEQF_PUSHED(); \
__frame = (StgSeqFrame *)(sp); \
- SET_HDR_(__frame,&seq_frame_info,CCCS); \
+ SET_HDR_(__frame,&stg_seq_frame_info,CCCS); \
__frame->link = Su; \
Su = (StgUpdateFrame *)__frame; \
}
-------------------------------------------------------------------------- */
#if defined(USE_SPLIT_MARKERS)
+#if defined(cygwin32_TARGET_OS) || defined(mingw32_TARGET_OS)
+#define __STG_SPLIT_MARKER __asm__("\n___stg_split_marker:");
+#else
#define __STG_SPLIT_MARKER __asm__("\n__stg_split_marker:");
+#endif
#else
#define __STG_SPLIT_MARKER /* nothing */
#endif
Module initialisation
-------------------------------------------------------------------------- */
-#if 1 /* old init stuff */
-
#define PUSH_INIT_STACK(reg_function) \
*(Sp++) = (W_)reg_function
JMP_(POP_INIT_STACK()); \
FE_ }
-#else
-
-#define PUSH_INIT_STACK(reg_function) /* nothing */
-#define POP_INIT_STACK() /* nothing */
-#define REGISTER_IMPORT(reg_mod_name) /* nothing */
-
-#define START_MOD_INIT(reg_mod_name) \
- FN_(reg_mod_name) { \
- EF_(StgReturn); \
- TEXT_SET(hs_init_set, reg_mod_name); \
- FB_;
- /* extern decls go here, followed by init code */
-
-#define REGISTER_FOREIGN_EXPORT(reg_fe_binder) \
- STGCALL1(getStablePtr,reg_fe_binder)
-
-
-#define END_MOD_INIT() \
- JMP_(StgReturn); \
- FE_ } \
-
-#endif
-
/* -----------------------------------------------------------------------------
Support for _ccall_GC_ and _casm_GC.
-------------------------------------------------------------------------- */