From d4fe4982fd4975dd5c11b28dfa6db1f3e90fd531 Mon Sep 17 00:00:00 2001 From: Milos Kotlar Date: Wed, 28 Dec 2022 10:45:08 +0100 Subject: [PATCH] dedup for iOS --- src/mono/mono/mini/aot-compiler.c | 6 +++--- src/mono/mono/mini/mini-llvm.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mono/mono/mini/aot-compiler.c b/src/mono/mono/mini/aot-compiler.c index b8682fa5798c4..f3c18683de30a 100644 --- a/src/mono/mono/mini/aot-compiler.c +++ b/src/mono/mono/mini/aot-compiler.c @@ -10459,9 +10459,6 @@ dedup_skip_methods (MonoAotCompile *acfg) { int i; - if (acfg->aot_opts.llvm_only) - return; - for (guint oindex = 0; oindex < acfg->method_order->len; ++oindex) { MonoCompile *cfg; MonoMethod *method; @@ -10764,6 +10761,9 @@ emit_method_info_table (MonoAotCompile *acfg) for (guint oindex = 0; oindex < acfg->method_order->len; ++oindex) { i = GPOINTER_TO_UINT (g_ptr_array_index (acfg->method_order, oindex)); + if (ignore_cfg (acfg->cfgs [i])) + continue; + if (acfg->cfgs [i]) { emit_method_info (acfg, acfg->cfgs [i]); offsets [i] = acfg->cfgs [i]->method_info_offset; diff --git a/src/mono/mono/mini/mini-llvm.c b/src/mono/mono/mini/mini-llvm.c index 67779805df504..deaed27b45475 100644 --- a/src/mono/mono/mini/mini-llvm.c +++ b/src/mono/mono/mini/mini-llvm.c @@ -11797,7 +11797,7 @@ mono_llvm_emit_method (MonoCompile *cfg) * - the method needs to have a unique mangled name * - llvmonly mode, since the code in aot-runtime.c would initialize got slots in the wrong aot image etc. */ - if (ctx->module->llvm_only && ctx->module->static_link && is_linkonce_method (cfg->method)) + if (ctx->module->static_link && is_linkonce_method (cfg->method)) is_linkonce = TRUE; if (is_linkonce || mono_aot_is_externally_callable (cfg->method)) method_name = mono_aot_get_mangled_method_name (cfg->method);