[boehm] Integrate toggleref support into the runtime.
[mono.git] / mono / metadata / sgen-archdep.h
index d0687b2bcaa0247e43892e863a7fec132444695a..5e7b5f8f1a3975641f76ea18f0fbafbad1659488 100755 (executable)
 #define USE_MONO_CTX
 #define ARCH_NUM_REGS 32
 
-#define ARCH_SIGCTX_SP(ctx)    (UCONTEXT_GREGS((ctx))[29])
-#define ARCH_SIGCTX_IP(ctx)    (UCONTEXT_REG_PC((ctx)))
+/*
+ * These casts are necessary since glibc always makes the
+ * gregs 64-bit values in userland.
+ */
+#define ARCH_SIGCTX_SP(ctx)    ((gsize) UCONTEXT_GREGS((ctx))[29])
+#define ARCH_SIGCTX_IP(ctx)    ((gsize) UCONTEXT_REG_PC((ctx)))
 
 #elif defined(__s390x__)