Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(231)

Side by Side Diff: src/wasm/wasm-objects.h

Issue 2629853004: [wasm] Skip serialization of breakpoints and certion stubs (Closed)
Patch Set: Move implementation to .cc file Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/wasm/wasm-module.cc ('k') | src/wasm/wasm-objects.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef V8_WASM_OBJECTS_H_ 5 #ifndef V8_WASM_OBJECTS_H_
6 #define V8_WASM_OBJECTS_H_ 6 #define V8_WASM_OBJECTS_H_
7 7
8 #include "src/debug/debug.h" 8 #include "src/debug/debug.h"
9 #include "src/debug/interface-types.h" 9 #include "src/debug/interface-types.h"
10 #include "src/objects-inl.h" 10 #include "src/objects-inl.h"
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 DECLARE_OPTIONAL_GETTER(breakpoint_infos, FixedArray); 174 DECLARE_OPTIONAL_GETTER(breakpoint_infos, FixedArray);
175 175
176 static Handle<WasmSharedModuleData> New( 176 static Handle<WasmSharedModuleData> New(
177 Isolate* isolate, Handle<Foreign> module_wrapper, 177 Isolate* isolate, Handle<Foreign> module_wrapper,
178 Handle<SeqOneByteString> module_bytes, Handle<Script> script, 178 Handle<SeqOneByteString> module_bytes, Handle<Script> script,
179 Handle<ByteArray> asm_js_offset_table); 179 Handle<ByteArray> asm_js_offset_table);
180 180
181 // Check whether this module was generated from asm.js source. 181 // Check whether this module was generated from asm.js source.
182 bool is_asm_js(); 182 bool is_asm_js();
183 183
184 // Recreate the ModuleWrapper from the module bytes after deserialization. 184 static void ReinitializeAfterDeserialization(Isolate*,
185 static void RecreateModuleWrapper(Isolate*, Handle<WasmSharedModuleData>); 185 Handle<WasmSharedModuleData>);
186 186
187 static void AddBreakpoint(Handle<WasmSharedModuleData>, int position, 187 static void AddBreakpoint(Handle<WasmSharedModuleData>, int position,
188 Handle<Object> break_point_object); 188 Handle<Object> break_point_object);
189 189
190 static void SetBreakpointsOnNewInstance(Handle<WasmSharedModuleData>, 190 static void SetBreakpointsOnNewInstance(Handle<WasmSharedModuleData>,
191 Handle<WasmInstanceObject>); 191 Handle<WasmInstanceObject>);
192 }; 192 };
193 193
194 class WasmCompiledModule : public FixedArray { 194 class WasmCompiledModule : public FixedArray {
195 public: 195 public:
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
313 FORWARD_SHARED(SeqOneByteString*, module_bytes) 313 FORWARD_SHARED(SeqOneByteString*, module_bytes)
314 FORWARD_SHARED(wasm::WasmModule*, module) 314 FORWARD_SHARED(wasm::WasmModule*, module)
315 FORWARD_SHARED(Script*, script) 315 FORWARD_SHARED(Script*, script)
316 FORWARD_SHARED(bool, is_asm_js) 316 FORWARD_SHARED(bool, is_asm_js)
317 #undef FORWARD_SHARED 317 #undef FORWARD_SHARED
318 318
319 static bool IsWasmCompiledModule(Object* obj); 319 static bool IsWasmCompiledModule(Object* obj);
320 320
321 void PrintInstancesChain(); 321 void PrintInstancesChain();
322 322
323 // Recreate the ModuleWrapper from the module bytes after deserialization. 323 static void ReinitializeAfterDeserialization(Isolate*,
324 static void RecreateModuleWrapper(Isolate* isolate, 324 Handle<WasmCompiledModule>);
325 Handle<WasmCompiledModule> compiled_module);
326 325
327 // Get the function name of the function identified by the given index. 326 // Get the function name of the function identified by the given index.
328 // Returns a null handle if the function is unnamed or the name is not a valid 327 // Returns a null handle if the function is unnamed or the name is not a valid
329 // UTF-8 string. 328 // UTF-8 string.
330 static MaybeHandle<String> GetFunctionNameOrNull( 329 static MaybeHandle<String> GetFunctionNameOrNull(
331 Isolate* isolate, Handle<WasmCompiledModule> compiled_module, 330 Isolate* isolate, Handle<WasmCompiledModule> compiled_module,
332 uint32_t func_index); 331 uint32_t func_index);
333 332
334 // Get the function name of the function identified by the given index. 333 // Get the function name of the function identified by the given index.
335 // Returns "<WASM UNNAMED>" if the function is unnamed or the name is not a 334 // Returns "<WASM UNNAMED>" if the function is unnamed or the name is not a
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 }; 479 };
481 }; 480 };
482 481
483 #undef DECLARE_ACCESSORS 482 #undef DECLARE_ACCESSORS
484 #undef DECLARE_OPTIONAL_ACCESSORS 483 #undef DECLARE_OPTIONAL_ACCESSORS
485 484
486 } // namespace internal 485 } // namespace internal
487 } // namespace v8 486 } // namespace v8
488 487
489 #endif // V8_WASM_OBJECTS_H_ 488 #endif // V8_WASM_OBJECTS_H_
OLDNEW
« no previous file with comments | « src/wasm/wasm-module.cc ('k') | src/wasm/wasm-objects.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698