Index: src/wasm/wasm-module.h |
diff --git a/src/wasm/wasm-module.h b/src/wasm/wasm-module.h |
index bbee2ad889b13806f8334b404e216691ac4d7106..ac75042392ddf1d7c77acd31fa11f6c8f916e65c 100644 |
--- a/src/wasm/wasm-module.h |
+++ b/src/wasm/wasm-module.h |
@@ -86,16 +86,12 @@ |
double f64_const; |
uint32_t global_index; |
} val; |
- |
- WasmInitExpr() : kind(kNone) {} |
- explicit WasmInitExpr(int32_t v) : kind(kI32Const) { val.i32_const = v; } |
- explicit WasmInitExpr(int64_t v) : kind(kI64Const) { val.i64_const = v; } |
- explicit WasmInitExpr(float v) : kind(kF32Const) { val.f32_const = v; } |
- explicit WasmInitExpr(double v) : kind(kF64Const) { val.f64_const = v; } |
- WasmInitExpr(WasmInitKind kind, uint32_t global_index) : kind(kGlobalIndex) { |
- val.global_index = global_index; |
- } |
-}; |
+}; |
+ |
+#define NO_INIT \ |
+ { \ |
+ WasmInitExpr::kNone, { 0u } \ |
+ } |
// Static representation of a WASM function. |
struct WasmFunction { |
@@ -388,9 +384,8 @@ |
#define CORE_WCM_PROPERTY_TABLE(MACRO) \ |
MACRO(OBJECT, FixedArray, code_table) \ |
- MACRO(OBJECT, FixedArray, imports) \ |
+ MACRO(OBJECT, FixedArray, import_data) \ |
MACRO(OBJECT, FixedArray, exports) \ |
- MACRO(OBJECT, FixedArray, inits) \ |
MACRO(OBJECT, FixedArray, startup_function) \ |
MACRO(OBJECT, FixedArray, indirect_function_tables) \ |
MACRO(OBJECT, String, module_bytes) \ |
@@ -400,6 +395,7 @@ |
MACRO(OBJECT, ByteArray, data_segments) \ |
MACRO(SMALL_NUMBER, uint32_t, globals_size) \ |
MACRO(OBJECT, JSArrayBuffer, heap) \ |
+ MACRO(SMALL_NUMBER, bool, export_memory) \ |
MACRO(SMALL_NUMBER, ModuleOrigin, origin) \ |
MACRO(WEAK_LINK, WasmCompiledModule, next_instance) \ |
MACRO(WEAK_LINK, WasmCompiledModule, prev_instance) \ |
@@ -428,6 +424,7 @@ |
static Handle<WasmCompiledModule> New(Isolate* isolate, |
uint32_t min_memory_pages, |
uint32_t globals_size, |
+ bool export_memory, |
ModuleOrigin origin); |
static Handle<WasmCompiledModule> Clone(Isolate* isolate, |
@@ -457,6 +454,9 @@ |
void PrintInstancesChain(); |
private: |
+#if DEBUG |
+ static uint32_t instance_id_counter_; |
+#endif |
void Init(); |
DISALLOW_IMPLICIT_CONSTRUCTORS(WasmCompiledModule); |