if (il_offset == -1 || il_offset == prev_il_offset)
continue;
prev_il_offset = il_offset;
- loc = mono_debug_symfile_lookup_location (minfo, il_offset);
+ loc = mono_debug_method_lookup_location (minfo, il_offset);
if (!(loc && loc->source_file))
continue;
if (loc->row == prev_line) {
- mono_debug_symfile_free_location (loc);
+ mono_debug_free_source_location (loc);
continue;
}
prev_line = loc->row;
options = "";
prologue_end = TRUE;
fprintf (acfg->fp, ".loc %d %d 0%s\n", findex, loc->row, options);
- mono_debug_symfile_free_location (loc);
+ mono_debug_free_source_location (loc);
}
skip = FALSE;
static mono_thread_start_return_t WINAPI
compile_thread_main (gpointer user_data)
{
- MonoDomain *domain = ((MonoDomain **)user_data) [0];
- MonoAotCompile *acfg = ((MonoAotCompile **)user_data) [1];
- GPtrArray *methods = ((GPtrArray **)user_data) [2];
+ MonoAotCompile *acfg = ((MonoAotCompile **)user_data) [0];
+ GPtrArray *methods = ((GPtrArray **)user_data) [1];
int i;
MonoError error;
- MonoThread *thread = mono_thread_attach (domain);
- mono_thread_set_name_internal (thread->internal_thread, mono_string_new (mono_get_root_domain (), "AOT compiler"), TRUE, FALSE, &error);
+ MonoInternalThread *internal = mono_thread_internal_current ();
+ mono_thread_set_name_internal (internal, mono_string_new (mono_domain_get (), "AOT compiler"), TRUE, FALSE, &error);
mono_error_assert_ok (&error);
for (i = 0; i < methods->len; ++i)
methods [i] = (MonoMethod *)g_ptr_array_index (acfg->methods, i);
i = 0;
while (i < methods_len) {
+ MonoError error;
+ MonoInternalThread *thread;
+
frag = g_ptr_array_new ();
for (j = 0; j < len; ++j) {
if (i < methods_len) {
}
user_data = g_new0 (gpointer, 3);
- user_data [0] = mono_domain_get ();
- user_data [1] = acfg;
- user_data [2] = frag;
+ user_data [0] = acfg;
+ user_data [1] = frag;
- thread_handle = mono_threads_create_thread (compile_thread_main, (gpointer) user_data, NULL, NULL);
+ thread = mono_thread_create_internal (mono_domain_get (), compile_thread_main, (gpointer) user_data, MONO_THREAD_CREATE_FLAGS_NONE, &error);
+ mono_error_assert_ok (&error);
+
+ thread_handle = mono_threads_open_thread_handle (thread->handle);
g_ptr_array_add (threads, thread_handle);
}
g_free (methods);