Commit 76cf87d4 authored by titzer's avatar titzer Committed by Commit bot

[wasm] Move the (conditional) installation of the WASM api into bootstrapper.cc.

R=mstarzinger@chromium.org,yangguo@chromium.org
BUG=

Review URL: https://codereview.chromium.org/1319003002

Cr-Commit-Position: refs/heads/master@{#30416}
parent d4e372b4
...@@ -18,6 +18,10 @@ ...@@ -18,6 +18,10 @@
#include "src/snapshot/snapshot.h" #include "src/snapshot/snapshot.h"
#include "third_party/fdlibm/fdlibm.h" #include "third_party/fdlibm/fdlibm.h"
#if defined(V8_WASM)
#include "src/wasm/wasm-js.h"
#endif
namespace v8 { namespace v8 {
namespace internal { namespace internal {
...@@ -2666,6 +2670,11 @@ bool Genesis::InstallSpecialObjects(Handle<Context> native_context) { ...@@ -2666,6 +2670,11 @@ bool Genesis::InstallSpecialObjects(Handle<Context> native_context) {
Handle<Object> global_proxy(debug_context->global_proxy(), isolate); Handle<Object> global_proxy(debug_context->global_proxy(), isolate);
JSObject::AddProperty(global, debug_string, global_proxy, DONT_ENUM); JSObject::AddProperty(global, debug_string, global_proxy, DONT_ENUM);
} }
#if defined(V8_WASM)
WasmJs::Install(isolate, global);
#endif
return true; return true;
} }
......
...@@ -49,10 +49,6 @@ ...@@ -49,10 +49,6 @@
#include "src/v8.h" #include "src/v8.h"
#endif // !V8_SHARED #endif // !V8_SHARED
#if defined(V8_WASM)
#include "src/wasm/wasm-js.h"
#endif
#if !defined(_WIN32) && !defined(_WIN64) #if !defined(_WIN32) && !defined(_WIN64)
#include <unistd.h> // NOLINT #include <unistd.h> // NOLINT
#else #else
...@@ -1182,11 +1178,6 @@ Local<ObjectTemplate> Shell::CreateGlobalTemplate(Isolate* isolate) { ...@@ -1182,11 +1178,6 @@ Local<ObjectTemplate> Shell::CreateGlobalTemplate(Isolate* isolate) {
.ToLocalChecked(), .ToLocalChecked(),
os_templ); os_templ);
#if defined(V8_WASM)
// Install WASM API.
WasmJs::Install(isolate, global_template);
#endif
return global_template; return global_template;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment