[wasm] Add one more wasm_invoke entry.
authorRodrigo Kumpera <kumpera@gmail.com>
Tue, 12 Sep 2017 20:12:06 +0000 (13:12 -0700)
committerRodrigo Kumpera <kumpera@gmail.com>
Tue, 12 Sep 2017 20:12:06 +0000 (13:12 -0700)
mono/mini/aot-runtime-wasm.c

index 4fb8906941cb2debcb65916bc9beb051db1101a0..d2ce4fd23ffb0d421d37825d2d64dc925009b430 100644 (file)
@@ -204,6 +204,15 @@ typedef union {
        } pair;
 } interp_pair;
 
+static void
+wasm_invoke_l (void *target_func, InterpMethodArguments *margs)
+{
+       gint64 (*func)(void) = target_func;
+
+       gint64 res = func ();
+       *(gint64*)margs->retval = res;
+}
+
 static void
 wasm_invoke_ll (void *target_func, InterpMethodArguments *margs)
 {
@@ -345,6 +354,8 @@ wasm_enter_icall_trampoline (void *target_func, InterpMethodArguments *margs)
                wasm_invoke_iiiii (target_func, margs);
        else if (!strcmp ("IIIIII", cookie))
                wasm_invoke_iiiiii (target_func, margs);
+       else if (!strcmp ("L", cookie))
+               wasm_invoke_l (target_func, margs);
        else if (!strcmp ("LL", cookie))
                wasm_invoke_ll (target_func, margs);
        else if (!strcmp ("LI", cookie))