| OLD | NEW |
| 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_COMPILER_WASM_COMPILER_H_ | 5 #ifndef V8_COMPILER_WASM_COMPILER_H_ |
| 6 #define V8_COMPILER_WASM_COMPILER_H_ | 6 #define V8_COMPILER_WASM_COMPILER_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 // Clients of this interface shouldn't depend on lots of compiler internals. | 10 // Clients of this interface shouldn't depend on lots of compiler internals. |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 uint32_t index_; | 77 uint32_t index_; |
| 78 wasm::Result<wasm::DecodeStruct*> graph_construction_result_; | 78 wasm::Result<wasm::DecodeStruct*> graph_construction_result_; |
| 79 bool ok_; | 79 bool ok_; |
| 80 | 80 |
| 81 DISALLOW_COPY_AND_ASSIGN(WasmCompilationUnit); | 81 DISALLOW_COPY_AND_ASSIGN(WasmCompilationUnit); |
| 82 }; | 82 }; |
| 83 | 83 |
| 84 // Wraps a JS function, producing a code object that can be called from WASM. | 84 // Wraps a JS function, producing a code object that can be called from WASM. |
| 85 Handle<Code> CompileWasmToJSWrapper(Isolate* isolate, Handle<JSReceiver> target, | 85 Handle<Code> CompileWasmToJSWrapper(Isolate* isolate, Handle<JSReceiver> target, |
| 86 wasm::FunctionSig* sig, uint32_t index, | 86 wasm::FunctionSig* sig, uint32_t index, |
| 87 Handle<String> module_name, | 87 Handle<String> import_module, |
| 88 MaybeHandle<String> import_name); | 88 MaybeHandle<String> import_function); |
| 89 | 89 |
| 90 // Wraps a given wasm code object, producing a code object. | 90 // Wraps a given wasm code object, producing a code object. |
| 91 Handle<Code> CompileJSToWasmWrapper(Isolate* isolate, wasm::ModuleEnv* module, | 91 Handle<Code> CompileJSToWasmWrapper(Isolate* isolate, wasm::ModuleEnv* module, |
| 92 Handle<Code> wasm_code, uint32_t index); | 92 Handle<Code> wasm_code, uint32_t index); |
| 93 | 93 |
| 94 // Abstracts details of building TurboFan graph nodes for WASM to separate | 94 // Abstracts details of building TurboFan graph nodes for WASM to separate |
| 95 // the WASM decoder from the internal details of TurboFan. | 95 // the WASM decoder from the internal details of TurboFan. |
| 96 class WasmTrapHelper; | 96 class WasmTrapHelper; |
| 97 typedef ZoneVector<Node*> NodeVector; | 97 typedef ZoneVector<Node*> NodeVector; |
| 98 class WasmGraphBuilder { | 98 class WasmGraphBuilder { |
| (...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 344 } | 344 } |
| 345 | 345 |
| 346 int AddParameterNodes(Node** args, int pos, int param_count, | 346 int AddParameterNodes(Node** args, int pos, int param_count, |
| 347 wasm::FunctionSig* sig); | 347 wasm::FunctionSig* sig); |
| 348 }; | 348 }; |
| 349 } // namespace compiler | 349 } // namespace compiler |
| 350 } // namespace internal | 350 } // namespace internal |
| 351 } // namespace v8 | 351 } // namespace v8 |
| 352 | 352 |
| 353 #endif // V8_COMPILER_WASM_COMPILER_H_ | 353 #endif // V8_COMPILER_WASM_COMPILER_H_ |
| OLD | NEW |