| OLD | NEW |
| 1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/interpreter/bytecode-array-builder.h" | 7 #include "src/interpreter/bytecode-array-builder.h" |
| 8 #include "src/interpreter/bytecode-array-iterator.h" | 8 #include "src/interpreter/bytecode-array-iterator.h" |
| 9 #include "src/interpreter/bytecode-label.h" | 9 #include "src/interpreter/bytecode-label.h" |
| 10 #include "src/interpreter/bytecode-register-allocator.h" | 10 #include "src/interpreter/bytecode-register-allocator.h" |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 200 builder.LoadUndefined() | 200 builder.LoadUndefined() |
| 201 .CompareOperation(Token::Value::EQ, reg, 1) | 201 .CompareOperation(Token::Value::EQ, reg, 1) |
| 202 .LoadNull() | 202 .LoadNull() |
| 203 .CompareOperation(Token::Value::EQ, reg, 1); | 203 .CompareOperation(Token::Value::EQ, reg, 1); |
| 204 | 204 |
| 205 // Emit conversion operator invocations. | 205 // Emit conversion operator invocations. |
| 206 builder.ConvertAccumulatorToNumber(reg) | 206 builder.ConvertAccumulatorToNumber(reg) |
| 207 .ConvertAccumulatorToObject(reg) | 207 .ConvertAccumulatorToObject(reg) |
| 208 .ConvertAccumulatorToName(reg); | 208 .ConvertAccumulatorToName(reg); |
| 209 | 209 |
| 210 // Emit GetSuperConstructor. |
| 211 builder.GetSuperConstructor(reg); |
| 212 |
| 210 // Short jumps with Imm8 operands | 213 // Short jumps with Imm8 operands |
| 211 { | 214 { |
| 212 BytecodeLabel start, after_jump1, after_jump2, after_jump3, after_jump4; | 215 BytecodeLabel start, after_jump1, after_jump2, after_jump3, after_jump4; |
| 213 builder.Bind(&start) | 216 builder.Bind(&start) |
| 214 .Jump(&after_jump1) | 217 .Jump(&after_jump1) |
| 215 .Bind(&after_jump1) | 218 .Bind(&after_jump1) |
| 216 .JumpIfNull(&after_jump2) | 219 .JumpIfNull(&after_jump2) |
| 217 .Bind(&after_jump2) | 220 .Bind(&after_jump2) |
| 218 .JumpIfUndefined(&after_jump3) | 221 .JumpIfUndefined(&after_jump3) |
| 219 .Bind(&after_jump3) | 222 .Bind(&after_jump3) |
| (...skipping 518 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 738 iterator.Advance(); | 741 iterator.Advance(); |
| 739 } | 742 } |
| 740 CHECK_EQ(iterator.current_bytecode(), Bytecode::kReturn); | 743 CHECK_EQ(iterator.current_bytecode(), Bytecode::kReturn); |
| 741 iterator.Advance(); | 744 iterator.Advance(); |
| 742 CHECK(iterator.done()); | 745 CHECK(iterator.done()); |
| 743 } | 746 } |
| 744 | 747 |
| 745 } // namespace interpreter | 748 } // namespace interpreter |
| 746 } // namespace internal | 749 } // namespace internal |
| 747 } // namespace v8 | 750 } // namespace v8 |
| OLD | NEW |