Fixed uninitialised FunBind fun_tick field
[ghc-hetmet.git] / rts / StgCRun.c
index 302e910..5138851 100644 (file)
@@ -50,6 +50,7 @@
  * in libc.a clobbers $s6.
  */
 #include "ghcconfig.h"
+#ifndef USE_MINIINTERPRETER
 #ifdef alpha_HOST_ARCH
 #define alpha_EXTRA_CAREFUL
 register long   fake_ra __asm__("$26");
@@ -60,6 +61,7 @@ register double fake_f8 __asm__("$f8");
 register double fake_f9 __asm__("$f9");
 #endif
 #endif
+#endif
 
 /* include Stg.h first because we want real machine regs in here: we
  * have to get the value of R1 back from Stg land to C land intact.
@@ -105,6 +107,12 @@ StgFunPtr StgReturn(void)
 #else /* !USE_MINIINTERPRETER */
 
 #ifdef LEADING_UNDERSCORE
+#define STG_RUN "_StgRun"
+#else
+#define STG_RUN "StgRun"
+#endif
+
+#ifdef LEADING_UNDERSCORE
 #define STG_RETURN "_StgReturn"
 #else
 #define STG_RETURN "StgReturn"
@@ -205,8 +213,8 @@ StgRunIsImplementedInAssembler(void)
        /*
         * save callee-saves registers on behalf of the STG code.
         */
-       ".globl StgRun\n"
-       "StgRun:\n\t"
+       ".globl " STG_RUN "\n"
+       STG_RUN ":\n\t"
        "subq %0, %%rsp\n\t"
        "movq %%rsp, %%rax\n\t"
        "addq %0-48, %%rax\n\t"
@@ -226,7 +234,7 @@ StgRunIsImplementedInAssembler(void)
         "movq %%rdi,%%rax\n\t"
         "jmp *%%rax\n\t"
 
-       ".global " STG_RETURN "\n"
+       ".globl " STG_RETURN "\n"
                STG_RETURN ":\n\t"
 
        "movq %%rbx, %%rax\n\t"   /* Return value in R1  */