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

Side by Side Diff: src/interpreter/bytecodes.cc

Issue 1634153002: [Interpreter] Adds support for const/let variables to interpreter. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Refactored VisitVariableAssignment. Created 4 years, 10 months 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
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/bytecodes.h" 5 #include "src/interpreter/bytecodes.h"
6 6
7 #include "src/frames.h" 7 #include "src/frames.h"
8 #include "src/interpreter/bytecode-traits.h" 8 #include "src/interpreter/bytecode-traits.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 } 189 }
190 190
191 191
192 // static 192 // static
193 bool Bytecodes::IsConditionalJumpImmediate(Bytecode bytecode) { 193 bool Bytecodes::IsConditionalJumpImmediate(Bytecode bytecode) {
194 return bytecode == Bytecode::kJumpIfTrue || 194 return bytecode == Bytecode::kJumpIfTrue ||
195 bytecode == Bytecode::kJumpIfFalse || 195 bytecode == Bytecode::kJumpIfFalse ||
196 bytecode == Bytecode::kJumpIfToBooleanTrue || 196 bytecode == Bytecode::kJumpIfToBooleanTrue ||
197 bytecode == Bytecode::kJumpIfToBooleanFalse || 197 bytecode == Bytecode::kJumpIfToBooleanFalse ||
198 bytecode == Bytecode::kJumpIfNull || 198 bytecode == Bytecode::kJumpIfNull ||
199 bytecode == Bytecode::kJumpIfUndefined; 199 bytecode == Bytecode::kJumpIfUndefined ||
200 bytecode == Bytecode::kJumpIfHole ||
201 bytecode == Bytecode::kJumpIfNotHole;
200 } 202 }
201 203
202 204
203 // static 205 // static
204 bool Bytecodes::IsConditionalJumpConstant(Bytecode bytecode) { 206 bool Bytecodes::IsConditionalJumpConstant(Bytecode bytecode) {
205 return bytecode == Bytecode::kJumpIfTrueConstant || 207 return bytecode == Bytecode::kJumpIfTrueConstant ||
206 bytecode == Bytecode::kJumpIfFalseConstant || 208 bytecode == Bytecode::kJumpIfFalseConstant ||
207 bytecode == Bytecode::kJumpIfToBooleanTrueConstant || 209 bytecode == Bytecode::kJumpIfToBooleanTrueConstant ||
208 bytecode == Bytecode::kJumpIfToBooleanFalseConstant || 210 bytecode == Bytecode::kJumpIfToBooleanFalseConstant ||
209 bytecode == Bytecode::kJumpIfNullConstant || 211 bytecode == Bytecode::kJumpIfNullConstant ||
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
567 } else { 569 } else {
568 std::ostringstream s; 570 std::ostringstream s;
569 s << "r" << index(); 571 s << "r" << index();
570 return s.str(); 572 return s.str();
571 } 573 }
572 } 574 }
573 575
574 } // namespace interpreter 576 } // namespace interpreter
575 } // namespace internal 577 } // namespace internal
576 } // namespace v8 578 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698