Index: src/wasm/ast-decoder.cc |
diff --git a/src/wasm/ast-decoder.cc b/src/wasm/ast-decoder.cc |
index 13aaba1e85319524d851dccd597dd685817d0d25..a869206e5be5f49aa7e95b6cb50bafa0ba67d15c 100644 |
--- a/src/wasm/ast-decoder.cc |
+++ b/src/wasm/ast-decoder.cc |
@@ -381,6 +381,9 @@ class WasmFullDecoder : public WasmDecoder { |
} |
bool Decode() { |
+ if (FLAG_wasm_code_fuzzer_gen_test) { |
+ PrintAstForDebugging(start_, end_); |
+ } |
base::ElapsedTimer decode_timer; |
if (FLAG_trace_wasm_decode_time) { |
decode_timer.Start(); |
@@ -1928,7 +1931,7 @@ bool PrintAst(AccountingAllocator* allocator, const FunctionBody& body, |
// Print the local declarations. |
AstLocalDecls decls(&zone); |
BytecodeIterator i(body.start, body.end, &decls); |
- if (body.start != i.pc()) { |
+ if (body.start != i.pc() && !FLAG_wasm_code_fuzzer_gen_test) { |
os << "// locals: "; |
for (auto p : decls.local_types) { |
LocalType type = p.first; |