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

Side by Side Diff: src/compiler/js-native-context-specialization.cc

Issue 1419823003: Remove support for "loads and stores to global vars through property cell shortcuts inst… (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@disable-shortcuts
Patch Set: Addressing comments Created 5 years, 2 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/compiler/js-generic-lowering.cc ('k') | src/compiler/js-operator.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/compiler/js-native-context-specialization.h" 5 #include "src/compiler/js-native-context-specialization.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/compilation-dependencies.h" 8 #include "src/compilation-dependencies.h"
9 #include "src/compiler/access-builder.h" 9 #include "src/compiler/access-builder.h"
10 #include "src/compiler/js-graph.h" 10 #include "src/compiler/js-graph.h"
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 Node* value = effect = graph()->NewNode( 129 Node* value = effect = graph()->NewNode(
130 simplified()->LoadField(AccessBuilder::ForPropertyCellValue()), 130 simplified()->LoadField(AccessBuilder::ForPropertyCellValue()),
131 jsgraph()->Constant(property_cell), effect, control); 131 jsgraph()->Constant(property_cell), effect, control);
132 return Replace(node, value, effect); 132 return Replace(node, value, effect);
133 } 133 }
134 134
135 135
136 Reduction JSNativeContextSpecialization::ReduceJSStoreGlobal(Node* node) { 136 Reduction JSNativeContextSpecialization::ReduceJSStoreGlobal(Node* node) {
137 DCHECK_EQ(IrOpcode::kJSStoreGlobal, node->opcode()); 137 DCHECK_EQ(IrOpcode::kJSStoreGlobal, node->opcode());
138 Handle<Name> name = StoreGlobalParametersOf(node->op()).name(); 138 Handle<Name> name = StoreGlobalParametersOf(node->op()).name();
139 Node* value = NodeProperties::GetValueInput(node, 2); 139 Node* value = NodeProperties::GetValueInput(node, 0);
140 Node* frame_state = NodeProperties::GetFrameStateInput(node, 1); 140 Node* frame_state = NodeProperties::GetFrameStateInput(node, 1);
141 Node* effect = NodeProperties::GetEffectInput(node); 141 Node* effect = NodeProperties::GetEffectInput(node);
142 Node* control = NodeProperties::GetControlInput(node); 142 Node* control = NodeProperties::GetControlInput(node);
143 143
144 // Try to lookup the name on the script context table first (lexical scoping). 144 // Try to lookup the name on the script context table first (lexical scoping).
145 ScriptContextTableLookupResult result; 145 ScriptContextTableLookupResult result;
146 if (LookupInScriptContextTable(name, &result)) { 146 if (LookupInScriptContextTable(name, &result)) {
147 if (result.context->is_the_hole(result.index)) return NoChange(); 147 if (result.context->is_the_hole(result.index)) return NoChange();
148 if (result.immutable) return NoChange(); 148 if (result.immutable) return NoChange();
149 Node* context = jsgraph()->Constant(result.context); 149 Node* context = jsgraph()->Constant(result.context);
(...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after
709 } 709 }
710 710
711 711
712 SimplifiedOperatorBuilder* JSNativeContextSpecialization::simplified() const { 712 SimplifiedOperatorBuilder* JSNativeContextSpecialization::simplified() const {
713 return jsgraph()->simplified(); 713 return jsgraph()->simplified();
714 } 714 }
715 715
716 } // namespace compiler 716 } // namespace compiler
717 } // namespace internal 717 } // namespace internal
718 } // namespace v8 718 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-generic-lowering.cc ('k') | src/compiler/js-operator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698