#include "metadata/sgen-gc.h"
#include "metadata/sgen-archdep.h"
#include "metadata/sgen-protocol.h"
+#include "metadata/sgen-thread-pool.h"
#include "metadata/object-internals.h"
#include "metadata/gc-internal.h"
mono_mach_arch_thread_state_to_mcontext (state, mctx);
ctx.uc_mcontext = mctx;
- info->stopped_domain = mono_mach_arch_get_tls_value_from_thread (
- mono_thread_info_get_tid (info), mono_domain_get_tls_key ());
+ info->stopped_domain = mono_thread_info_tls_get (info, TLS_KEY_DOMAIN);
info->stopped_ip = (gpointer) mono_mach_arch_get_ip (state);
info->stack_start = NULL;
stack_start = (char*) mono_mach_arch_get_sp (state) - REDZONE_SIZE;
if (mono_gc_get_gc_callbacks ()->thread_suspend_func)
mono_gc_get_gc_callbacks ()->thread_suspend_func (info->runtime_data, &ctx, NULL);
- SGEN_LOG (2, "thread %p stopped at %p stack_start=%p", (void*)info->info.native_handle, info->stopped_ip, info->stack_start);
+ SGEN_LOG (2, "thread %p stopped at %p stack_start=%p", (void*)(gsize)info->info.native_handle, info->stopped_ip, info->stack_start);
binary_protocol_thread_suspend ((gpointer)mono_thread_info_get_tid (info), info->stopped_ip);
int count = 0;
+ cur_thread->suspend_done = TRUE;
FOREACH_THREAD_SAFE (info) {
- if (info->joined_stw == suspend)
+ if (info == cur_thread || sgen_thread_pool_is_thread_pool_thread (mono_thread_info_get_tid (info)))
continue;
- info->joined_stw = suspend;
- if (info == cur_thread || sgen_is_worker_thread (mono_thread_info_get_tid (info)))
- continue;
+ info->suspend_done = FALSE;
if (info->gc_disabled)
continue;
if (suspend) {
- g_assert (!info->doing_handshake);
- info->doing_handshake = TRUE;
-
if (!sgen_suspend_thread (info))
continue;
} else {
- g_assert (info->doing_handshake);
- info->doing_handshake = FALSE;
-
ret = thread_resume (info->info.native_handle);
if (ret != KERN_SUCCESS)
continue;
{
return -1;
}
+
+int
+mono_gc_get_restart_signal (void)
+{
+ return -1;
+}
#endif
#endif