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

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

Issue 2680923003: Revert of Thread maybe-assigned through the bytecodes. (Closed)
Patch Set: Created 3 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
« no previous file with comments | « src/interpreter/bytecode-array-builder.h ('k') | src/interpreter/bytecode-generator.cc » ('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-builder.h" 5 #include "src/interpreter/bytecode-array-builder.h"
6 6
7 #include "src/globals.h" 7 #include "src/globals.h"
8 #include "src/interpreter/bytecode-array-writer.h" 8 #include "src/interpreter/bytecode-array-writer.h"
9 #include "src/interpreter/bytecode-dead-code-optimizer.h" 9 #include "src/interpreter/bytecode-dead-code-optimizer.h"
10 #include "src/interpreter/bytecode-label.h" 10 #include "src/interpreter/bytecode-label.h"
(...skipping 459 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 size_t name_index = GetConstantPoolEntry(name); 470 size_t name_index = GetConstantPoolEntry(name);
471 if (language_mode == SLOPPY) { 471 if (language_mode == SLOPPY) {
472 OutputStaGlobalSloppy(name_index, feedback_slot); 472 OutputStaGlobalSloppy(name_index, feedback_slot);
473 } else { 473 } else {
474 DCHECK_EQ(language_mode, STRICT); 474 DCHECK_EQ(language_mode, STRICT);
475 OutputStaGlobalStrict(name_index, feedback_slot); 475 OutputStaGlobalStrict(name_index, feedback_slot);
476 } 476 }
477 return *this; 477 return *this;
478 } 478 }
479 479
480 BytecodeArrayBuilder& BytecodeArrayBuilder::LoadContextSlot( 480 BytecodeArrayBuilder& BytecodeArrayBuilder::LoadContextSlot(Register context,
481 Register context, int slot_index, int depth, 481 int slot_index,
482 ContextSlotMutability mutability) { 482 int depth) {
483 if (context.is_current_context() && depth == 0) { 483 if (context.is_current_context() && depth == 0) {
484 if (mutability == kImmutableSlot) { 484 OutputLdaCurrentContextSlot(slot_index);
485 OutputLdaImmutableCurrentContextSlot(slot_index);
486 } else {
487 DCHECK_EQ(kMutableSlot, mutability);
488 OutputLdaCurrentContextSlot(slot_index);
489 }
490 } else if (mutability == kImmutableSlot) {
491 OutputLdaImmutableContextSlot(context, slot_index, depth);
492 } else { 485 } else {
493 DCHECK_EQ(mutability, kMutableSlot);
494 OutputLdaContextSlot(context, slot_index, depth); 486 OutputLdaContextSlot(context, slot_index, depth);
495 } 487 }
496 return *this; 488 return *this;
497 } 489 }
498 490
499 BytecodeArrayBuilder& BytecodeArrayBuilder::StoreContextSlot(Register context, 491 BytecodeArrayBuilder& BytecodeArrayBuilder::StoreContextSlot(Register context,
500 int slot_index, 492 int slot_index,
501 int depth) { 493 int depth) {
502 if (context.is_current_context() && depth == 0) { 494 if (context.is_current_context() && depth == 0) {
503 OutputStaCurrentContextSlot(slot_index); 495 OutputStaCurrentContextSlot(slot_index);
(...skipping 587 matching lines...) Expand 10 before | Expand all | Expand 10 after
1091 RegisterList reg_list) { 1083 RegisterList reg_list) {
1092 DCHECK(RegisterListIsValid(reg_list)); 1084 DCHECK(RegisterListIsValid(reg_list));
1093 if (register_optimizer_) 1085 if (register_optimizer_)
1094 register_optimizer_->PrepareOutputRegisterList(reg_list); 1086 register_optimizer_->PrepareOutputRegisterList(reg_list);
1095 return static_cast<uint32_t>(reg_list.first_register().ToOperand()); 1087 return static_cast<uint32_t>(reg_list.first_register().ToOperand());
1096 } 1088 }
1097 1089
1098 } // namespace interpreter 1090 } // namespace interpreter
1099 } // namespace internal 1091 } // namespace internal
1100 } // namespace v8 1092 } // namespace v8
OLDNEW
« no previous file with comments | « src/interpreter/bytecode-array-builder.h ('k') | src/interpreter/bytecode-generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698