MONO_OPT_LOOP | \
MONO_OPT_AOT)
-/* SSAPRE does not work correctly on non x86 platforms (bug #70637) */
#define EXCLUDED_FROM_ALL (MONO_OPT_SHARED | MONO_OPT_PRECOMP)
static guint32
comp_time = elapsed = 0.0;
/* fixme: ugly hack - delete all previously compiled methods */
- for (i = 0; i < mono_image_get_table_rows (image, MONO_TABLE_METHOD); ++i) {
- method = mono_get_method (image, MONO_TOKEN_METHOD_DEF | (i + 1), NULL);
- method->info = NULL;
- }
+ g_hash_table_destroy (mono_domain_get ()->jit_trampoline_hash);
+ mono_domain_get ()->jit_trampoline_hash = g_hash_table_new (mono_aligned_addr_hash, NULL);
g_timer_start (timer);
if (mini_stats_fd)
int verbose = args->verbose;
MonoImage *image = mono_assembly_get_image (ass);
MonoMethod *method;
+ MonoCompile *cfg;
int i, count = 0;
for (i = 0; i < mono_image_get_table_rows (image, MONO_TABLE_METHOD); ++i) {
- method = mono_get_method (image, MONO_TOKEN_METHOD_DEF | (i + 1), NULL);
- if (method->flags & METHOD_ATTRIBUTE_ABSTRACT)
+ guint32 token = MONO_TOKEN_METHOD_DEF | (i + 1);
+ MonoMethodSignature *sig;
+
+ if (mono_metadata_has_generic_params (image, token))
+ continue;
+
+ method = mono_get_method (image, token, NULL);
+ if ((method->iflags & METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL) ||
+ (method->flags & METHOD_ATTRIBUTE_PINVOKE_IMPL) ||
+ (method->iflags & METHOD_IMPL_ATTRIBUTE_RUNTIME) ||
+ (method->flags & METHOD_ATTRIBUTE_ABSTRACT))
continue;
- if (method->iflags & METHOD_IMPL_ATTRIBUTE_INTERNAL_CALL)
+
+ if (method->klass->generic_container)
+ continue;
+ sig = mono_method_signature (method);
+ if (sig->has_type_parameters)
continue;
count++;
g_print ("Compiling %d %s\n", count, desc);
g_free (desc);
}
- mono_compile_method (method);
+ cfg = mini_method_compile (method, DEFAULT_OPTIMIZATIONS, mono_get_root_domain (), FALSE, FALSE, 0);
+ mono_destroy_compile (cfg);
}
}