| OLD | NEW |
| 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 #include "src/wasm/wasm-text.h" | 5 #include "src/wasm/wasm-text.h" |
| 6 | 6 |
| 7 #include "src/ostreams.h" | 7 #include "src/ostreams.h" |
| 8 #include "src/vector.h" | 8 #include "src/vector.h" |
| 9 #include "src/wasm/ast-decoder.h" | 9 #include "src/wasm/ast-decoder.h" |
| 10 #include "src/wasm/wasm-module.h" | 10 #include "src/wasm/wasm-module.h" |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 break; | 225 break; |
| 226 case kExprBrTable: { | 226 case kExprBrTable: { |
| 227 BranchTableOperand operand(&i, i.pc()); | 227 BranchTableOperand operand(&i, i.pc()); |
| 228 BranchTableIterator iterator(&i, operand); | 228 BranchTableIterator iterator(&i, operand); |
| 229 os << "br_table"; | 229 os << "br_table"; |
| 230 while (iterator.has_next()) os << ' ' << iterator.next(); | 230 while (iterator.has_next()) os << ' ' << iterator.next(); |
| 231 break; | 231 break; |
| 232 } | 232 } |
| 233 case kExprCallIndirect: { | 233 case kExprCallIndirect: { |
| 234 CallIndirectOperand operand(&i, i.pc()); | 234 CallIndirectOperand operand(&i, i.pc()); |
| 235 DCHECK_EQ(0U, operand.table_index); | 235 DCHECK_EQ(0, operand.table_index); |
| 236 os << "call_indirect " << operand.index; | 236 os << "call_indirect " << operand.index; |
| 237 break; | 237 break; |
| 238 } | 238 } |
| 239 case kExprCallFunction: { | 239 case kExprCallFunction: { |
| 240 CallFunctionOperand operand(&i, i.pc()); | 240 CallFunctionOperand operand(&i, i.pc()); |
| 241 os << "call " << operand.index; | 241 os << "call " << operand.index; |
| 242 break; | 242 break; |
| 243 } | 243 } |
| 244 case kExprGetLocal: | 244 case kExprGetLocal: |
| 245 case kExprSetLocal: | 245 case kExprSetLocal: |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 default: | 301 default: |
| 302 UNREACHABLE(); | 302 UNREACHABLE(); |
| 303 break; | 303 break; |
| 304 } | 304 } |
| 305 os << '\n'; | 305 os << '\n'; |
| 306 ++line_nr; | 306 ++line_nr; |
| 307 } | 307 } |
| 308 DCHECK_EQ(0, control_depth); | 308 DCHECK_EQ(0, control_depth); |
| 309 DCHECK(i.ok()); | 309 DCHECK(i.ok()); |
| 310 } | 310 } |
| OLD | NEW |