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

Side by Side Diff: src/interpreter/bytecode-array-writer.cc

Issue 2557593004: [ignition] desugar GetIterator() via bytecode rather than via AST (Closed)
Patch Set: georg's comments 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 | « src/interpreter/bytecode-array-builder.cc ('k') | src/interpreter/bytecode-generator.h » ('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 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/interpreter/bytecode-array-writer.h" 5 #include "src/interpreter/bytecode-array-writer.h"
6 6
7 #include "src/api.h" 7 #include "src/api.h"
8 #include "src/interpreter/bytecode-label.h" 8 #include "src/interpreter/bytecode-label.h"
9 #include "src/interpreter/bytecode-register.h" 9 #include "src/interpreter/bytecode-register.h"
10 #include "src/interpreter/constant-array-builder.h" 10 #include "src/interpreter/constant-array-builder.h"
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 case Bytecode::kJumpIfToBooleanTrue: 156 case Bytecode::kJumpIfToBooleanTrue:
157 return Bytecode::kJumpIfToBooleanTrueConstant; 157 return Bytecode::kJumpIfToBooleanTrueConstant;
158 case Bytecode::kJumpIfToBooleanFalse: 158 case Bytecode::kJumpIfToBooleanFalse:
159 return Bytecode::kJumpIfToBooleanFalseConstant; 159 return Bytecode::kJumpIfToBooleanFalseConstant;
160 case Bytecode::kJumpIfNotHole: 160 case Bytecode::kJumpIfNotHole:
161 return Bytecode::kJumpIfNotHoleConstant; 161 return Bytecode::kJumpIfNotHoleConstant;
162 case Bytecode::kJumpIfNull: 162 case Bytecode::kJumpIfNull:
163 return Bytecode::kJumpIfNullConstant; 163 return Bytecode::kJumpIfNullConstant;
164 case Bytecode::kJumpIfUndefined: 164 case Bytecode::kJumpIfUndefined:
165 return Bytecode::kJumpIfUndefinedConstant; 165 return Bytecode::kJumpIfUndefinedConstant;
166 case Bytecode::kJumpIfJSReceiver:
167 return Bytecode::kJumpIfJSReceiverConstant;
166 default: 168 default:
167 UNREACHABLE(); 169 UNREACHABLE();
168 return Bytecode::kIllegal; 170 return Bytecode::kIllegal;
169 } 171 }
170 } 172 }
171 173
172 void BytecodeArrayWriter::PatchJumpWith8BitOperand(size_t jump_location, 174 void BytecodeArrayWriter::PatchJumpWith8BitOperand(size_t jump_location,
173 int delta) { 175 int delta) {
174 Bytecode jump_bytecode = Bytecodes::FromByte(bytecodes()->at(jump_location)); 176 Bytecode jump_bytecode = Bytecodes::FromByte(bytecodes()->at(jump_location));
175 DCHECK(Bytecodes::IsJumpImmediate(jump_bytecode)); 177 DCHECK(Bytecodes::IsJumpImmediate(jump_bytecode));
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
317 node->set_bytecode(node->bytecode(), k32BitJumpPlaceholder); 319 node->set_bytecode(node->bytecode(), k32BitJumpPlaceholder);
318 break; 320 break;
319 } 321 }
320 } 322 }
321 EmitBytecode(node); 323 EmitBytecode(node);
322 } 324 }
323 325
324 } // namespace interpreter 326 } // namespace interpreter
325 } // namespace internal 327 } // namespace internal
326 } // namespace v8 328 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/bytecode-array-builder.cc ('k') | src/interpreter/bytecode-generator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698