Merge remote-tracking branch 'mfoliveira/ppc64el-v2'
[mono.git] / mono / mini / mini-gc.c
index a528b3fea6d5ed651627453ed3450e17512bec0a..fddca9c6c346e7be93d95e0a204e6a679a28b2e7 100644 (file)
@@ -12,8 +12,8 @@
 #include "mini-gc.h"
 #include <mono/metadata/gc-internal.h>
 
-//#if 0
-#if defined(MONO_ARCH_GC_MAPS_SUPPORTED)
+#if 0
+//#if defined(MONO_ARCH_GC_MAPS_SUPPORTED)
 
 #include <mono/metadata/sgen-conf.h>
 #include <mono/metadata/gc-internal.h>
@@ -436,6 +436,13 @@ static int callee_saved_regs [] = { ARMREG_V1, ARMREG_V2, ARMREG_V3, ARMREG_V4,
 static int callee_saved_regs [] = { };
 #elif defined(TARGET_S390X)
 static int callee_saved_regs [] = { s390_r6, s390_r7, s390_r8, s390_r9, s390_r10, s390_r11, s390_r12, s390_r13, s390_r14 };
+#elif defined(TARGET_POWERPC64) && _CALL_ELF == 2
+static int callee_saved_regs [] = {
+  ppc_r13, ppc_r14, ppc_r15, ppc_r16,
+  ppc_r17, ppc_r18, ppc_r19, ppc_r20,
+  ppc_r21, ppc_r22, ppc_r23, ppc_r24,
+  ppc_r25, ppc_r26, ppc_r27, ppc_r28,
+  ppc_r29, ppc_r30, ppc_r31 };
 #elif defined(TARGET_POWERPC)
 static int callee_saved_regs [] = { ppc_r6, ppc_r7, ppc_r8, ppc_r9, ppc_r10, ppc_r11, ppc_r12, ppc_r13, ppc_r14 };
 #endif
@@ -609,7 +616,7 @@ thread_suspend_func (gpointer user_data, void *sigctx, MonoContext *ctx)
                tls->unwind_state.unwind_data [MONO_UNWIND_DATA_LMF] = mono_get_lmf ();
                if (sigctx) {
 #ifdef MONO_ARCH_HAVE_SIGCTX_TO_MONOCTX
-                       mono_arch_sigctx_to_monoctx (sigctx, &tls->unwind_state.ctx);
+                       mono_sigctx_to_monoctx (sigctx, &tls->unwind_state.ctx);
                        tls->unwind_state.valid = TRUE;
 #else
                        tls->unwind_state.valid = FALSE;