[wasm] Avoid adding an extra arg to native-to-managed wrappers. (mono/mono#17508)
authorZoltan Varga <vargaz@gmail.com>
Wed, 23 Oct 2019 15:06:18 +0000 (11:06 -0400)
committermonojenkins <jo.shields+jenkins@xamarin.com>
Wed, 23 Oct 2019 15:06:18 +0000 (17:06 +0200)
[wasm] Avoid adding an extra arg to native-to-managed wrappers.

Fixes https://github.com/mono/mono/issues/17389.

<!--
Thank you for your Pull Request!

If you are new to contributing to Mono, please try to do your best at conforming to our coding guidelines http://www.mono-project.com/community/contributing/coding-guidelines/ but don't worry if you get something wrong. One of the project members will help you to get things landed.

Does your pull request fix any of the existing issues? Please use the following format: Fixes #issue-number
-->

Commit migrated from https://github.com/mono/mono/commit/31b475e25a4ab5b6d8af731be9bb9e8158da31d9

src/mono/mono/mini/mini-llvm.c

index 4eae20c..d07953b 100644 (file)
@@ -3731,6 +3731,7 @@ needs_extra_arg (EmitContext *ctx, MonoMethod *method)
        case MONO_WRAPPER_ALLOC:
        case MONO_WRAPPER_CASTCLASS:
        case MONO_WRAPPER_WRITE_BARRIER:
+       case MONO_WRAPPER_NATIVE_TO_MANAGED:
                return FALSE;
        case MONO_WRAPPER_STELEMREF:
                if (info->subtype != WRAPPER_SUBTYPE_VIRTUAL_STELEMREF)