Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(50)

Side by Side Diff: test/unittests/interpreter/bytecode-array-builder-unittest.cc

Issue 2504553003: [es6] Perform the IsConstructor test in GetSuperConstructor. (Closed)
Patch Set: rebase Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « test/test262/test262.status ('k') | test/webkit/class-syntax-call.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 .LoadUndefined() 206 .LoadUndefined()
207 .CompareOperation(Token::Value::EQ_STRICT, reg, 1) 207 .CompareOperation(Token::Value::EQ_STRICT, reg, 1)
208 .LoadNull() 208 .LoadNull()
209 .CompareOperation(Token::Value::EQ_STRICT, reg, 1); 209 .CompareOperation(Token::Value::EQ_STRICT, reg, 1);
210 210
211 // Emit conversion operator invocations. 211 // Emit conversion operator invocations.
212 builder.ConvertAccumulatorToNumber(reg) 212 builder.ConvertAccumulatorToNumber(reg)
213 .ConvertAccumulatorToObject(reg) 213 .ConvertAccumulatorToObject(reg)
214 .ConvertAccumulatorToName(reg); 214 .ConvertAccumulatorToName(reg);
215 215
216 // Emit GetSuperConstructor.
217 builder.GetSuperConstructor(reg);
218
216 // Short jumps with Imm8 operands 219 // Short jumps with Imm8 operands
217 { 220 {
218 BytecodeLabel start, after_jump1, after_jump2, after_jump3, after_jump4, 221 BytecodeLabel start, after_jump1, after_jump2, after_jump3, after_jump4,
219 after_jump5; 222 after_jump5;
220 builder.Bind(&start) 223 builder.Bind(&start)
221 .Jump(&after_jump1) 224 .Jump(&after_jump1)
222 .Bind(&after_jump1) 225 .Bind(&after_jump1)
223 .JumpIfNull(&after_jump2) 226 .JumpIfNull(&after_jump2)
224 .Bind(&after_jump2) 227 .Bind(&after_jump2)
225 .JumpIfUndefined(&after_jump3) 228 .JumpIfUndefined(&after_jump3)
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after
754 iterator.Advance(); 757 iterator.Advance();
755 } 758 }
756 CHECK_EQ(iterator.current_bytecode(), Bytecode::kReturn); 759 CHECK_EQ(iterator.current_bytecode(), Bytecode::kReturn);
757 iterator.Advance(); 760 iterator.Advance();
758 CHECK(iterator.done()); 761 CHECK(iterator.done());
759 } 762 }
760 763
761 } // namespace interpreter 764 } // namespace interpreter
762 } // namespace internal 765 } // namespace internal
763 } // namespace v8 766 } // namespace v8
OLDNEW
« no previous file with comments | « test/test262/test262.status ('k') | test/webkit/class-syntax-call.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698