Fix https://github.com/dotnet/runtime/issues/46698. (#49293)
authorZoltan Varga <vargaz@gmail.com>
Mon, 8 Mar 2021 20:10:03 +0000 (15:10 -0500)
committerGitHub <noreply@github.com>
Mon, 8 Mar 2021 20:10:03 +0000 (15:10 -0500)
src/mono/mono/mini/method-to-ir.c

index 1b900f4..24a5b3a 100644 (file)
@@ -3326,7 +3326,7 @@ mini_emit_box (MonoCompile *cfg, MonoInst *val, MonoClass *klass, int context_us
                MonoMethod* method = get_method_nofail (klass, "Box", 1, 0);
 
                if (context_used) {
-                       if (cfg->llvm_only && cfg->gsharedvt) {
+                       if (cfg->llvm_only) {
                                MonoInst *addr = emit_get_rgctx_method (cfg, context_used, method,
                                                                                                                MONO_RGCTX_INFO_METHOD_FTNDESC);
                                return mini_emit_llvmonly_calli (cfg, mono_method_signature_internal (method), &val, addr);