diff options
Diffstat (limited to 'deps/v8/src/wasm/function-body-decoder.h')
-rw-r--r-- | deps/v8/src/wasm/function-body-decoder.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/deps/v8/src/wasm/function-body-decoder.h b/deps/v8/src/wasm/function-body-decoder.h index a1470f4937..7dbb800399 100644 --- a/deps/v8/src/wasm/function-body-decoder.h +++ b/deps/v8/src/wasm/function-body-decoder.h @@ -20,6 +20,7 @@ class BitVector; // forward declaration class Counters; namespace compiler { // external declarations from compiler. +class NodeOriginTable; class WasmGraphBuilder; } @@ -27,6 +28,7 @@ namespace wasm { typedef compiler::WasmGraphBuilder TFBuilder; struct WasmModule; // forward declaration of module interface. +enum ModuleOrigin : uint8_t; // A wrapper around the signature and bytes of a function. struct FunctionBody { @@ -48,16 +50,23 @@ V8_EXPORT_PRIVATE DecodeResult VerifyWasmCode(AccountingAllocator* allocator, // isolate::async_counters() to guarantee usability of counters argument. DecodeResult VerifyWasmCodeWithStats(AccountingAllocator* allocator, const wasm::WasmModule* module, - FunctionBody& body, bool is_wasm, + FunctionBody& body, ModuleOrigin origin, Counters* counters); DecodeResult BuildTFGraph(AccountingAllocator* allocator, TFBuilder* builder, - FunctionBody& body); + FunctionBody& body, + compiler::NodeOriginTable* node_origins); enum PrintLocals { kPrintLocals, kOmitLocals }; V8_EXPORT_PRIVATE bool PrintRawWasmCode(AccountingAllocator* allocator, const FunctionBody& body, const wasm::WasmModule* module, PrintLocals print_locals); +V8_EXPORT_PRIVATE +bool PrintRawWasmCode(AccountingAllocator* allocator, const FunctionBody& body, + const wasm::WasmModule* module, PrintLocals print_locals, + std::ostream& out, + std::vector<int>* line_numbers = nullptr); + // A simplified form of AST printing, e.g. from a debugger. void PrintRawWasmCode(const byte* start, const byte* end); @@ -72,7 +81,7 @@ inline DecodeResult BuildTFGraph(AccountingAllocator* allocator, TFBuilder* builder, FunctionSig* sig, const byte* start, const byte* end) { FunctionBody body(sig, 0, start, end); - return BuildTFGraph(allocator, builder, body); + return BuildTFGraph(allocator, builder, body, nullptr); } struct BodyLocalDecls { |