| Index: src/runtime/runtime-function.cc
|
| diff --git a/src/runtime/runtime-function.cc b/src/runtime/runtime-function.cc
|
| index 939bd53e6a82799a6ce53a466fb4074a8146964c..a19511296bde7b4ee08574d06dc9b6d5caf9bfa4 100644
|
| --- a/src/runtime/runtime-function.cc
|
| +++ b/src/runtime/runtime-function.cc
|
| @@ -11,6 +11,7 @@
|
| #include "src/isolate-inl.h"
|
| #include "src/messages.h"
|
| #include "src/profiler/cpu-profiler.h"
|
| +#include "src/wasm/wasm-module.h"
|
|
|
| namespace v8 {
|
| namespace internal {
|
| @@ -305,5 +306,16 @@ RUNTIME_FUNCTION(Runtime_FunctionToString) {
|
| : *JSFunction::ToString(Handle<JSFunction>::cast(function));
|
| }
|
|
|
| +RUNTIME_FUNCTION(Runtime_WasmGetFunctionName) {
|
| + HandleScope scope(isolate);
|
| + DCHECK_EQ(2, args.length());
|
| +
|
| + CONVERT_ARG_HANDLE_CHECKED(JSObject, wasm, 0);
|
| + CONVERT_SMI_ARG_CHECKED(func_index, 1);
|
| + RUNTIME_ASSERT(wasm->map()->instance_type() == JS_WASM_TYPE);
|
| +
|
| + return *wasm::GetWasmFunctionName(wasm, func_index);
|
| +}
|
| +
|
| } // namespace internal
|
| } // namespace v8
|
|
|