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

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

Issue 2416543002: [wasm] Fix bounds check for zero initial memory. (Closed)
Patch Set: Fix bot failure Created 4 years, 2 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/compiler/wasm-compiler.cc ('k') | src/wasm/wasm-module.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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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_MODULE_H_ 5 #ifndef V8_WASM_MODULE_H_
6 #define V8_WASM_MODULE_H_ 6 #define V8_WASM_MODULE_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "src/api.h" 10 #include "src/api.h"
(...skipping 497 matching lines...) Expand 10 before | Expand all | Expand 10 after
508 bool WasmIsAsmJs(Object* wasm, Isolate* isolate); 508 bool WasmIsAsmJs(Object* wasm, Isolate* isolate);
509 509
510 // Get the script for the asm.js origin of the wasm module. 510 // Get the script for the asm.js origin of the wasm module.
511 Handle<Script> GetAsmWasmScript(Handle<JSObject> wasm); 511 Handle<Script> GetAsmWasmScript(Handle<JSObject> wasm);
512 512
513 // Get the asm.js source position for the given byte offset in the given 513 // Get the asm.js source position for the given byte offset in the given
514 // function. 514 // function.
515 int GetAsmWasmSourcePosition(Handle<JSObject> wasm, int func_index, 515 int GetAsmWasmSourcePosition(Handle<JSObject> wasm, int func_index,
516 int byte_offset); 516 int byte_offset);
517 517
518 // Update memory references of code objects associated with the module
519 bool UpdateWasmModuleMemory(Handle<JSObject> object, Address old_start,
520 Address new_start, uint32_t old_size,
521 uint32_t new_size);
522
523 // Constructs a single function table as a FixedArray of double size, 518 // Constructs a single function table as a FixedArray of double size,
524 // populating it with function signature indices and function indices. 519 // populating it with function signature indices and function indices.
525 Handle<FixedArray> BuildFunctionTable(Isolate* isolate, uint32_t index, 520 Handle<FixedArray> BuildFunctionTable(Isolate* isolate, uint32_t index,
526 const WasmModule* module); 521 const WasmModule* module);
527 522
528 // Populates a function table by replacing function indices with handles to 523 // Populates a function table by replacing function indices with handles to
529 // the compiled code. 524 // the compiled code.
530 void PopulateFunctionTable(Handle<FixedArray> table, uint32_t table_size, 525 void PopulateFunctionTable(Handle<FixedArray> table, uint32_t table_size,
531 const std::vector<Handle<Code>>* code_table); 526 const std::vector<Handle<Code>>* code_table);
532 527
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 int instance_count); 561 int instance_count);
567 void ValidateModuleState(Isolate* isolate, Handle<JSObject> module_obj); 562 void ValidateModuleState(Isolate* isolate, Handle<JSObject> module_obj);
568 void ValidateOrphanedInstance(Isolate* isolate, Handle<JSObject> instance); 563 void ValidateOrphanedInstance(Isolate* isolate, Handle<JSObject> instance);
569 564
570 } // namespace testing 565 } // namespace testing
571 } // namespace wasm 566 } // namespace wasm
572 } // namespace internal 567 } // namespace internal
573 } // namespace v8 568 } // namespace v8
574 569
575 #endif // V8_WASM_MODULE_H_ 570 #endif // V8_WASM_MODULE_H_
OLDNEW
« no previous file with comments | « src/compiler/wasm-compiler.cc ('k') | src/wasm/wasm-module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698