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

Side by Side Diff: src/compiler/js-typed-lowering.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-operator.cc ('k') | src/crankshaft/arm/lithium-arm.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 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/code-factory.h" 5 #include "src/code-factory.h"
6 #include "src/compiler/access-builder.h" 6 #include "src/compiler/access-builder.h"
7 #include "src/compiler/js-graph.h" 7 #include "src/compiler/js-graph.h"
8 #include "src/compiler/js-typed-lowering.h" 8 #include "src/compiler/js-typed-lowering.h"
9 #include "src/compiler/linkage.h" 9 #include "src/compiler/linkage.h"
10 #include "src/compiler/node-matchers.h" 10 #include "src/compiler/node-matchers.h"
(...skipping 1024 matching lines...) Expand 10 before | Expand all | Expand 10 after
1035 check_true); 1035 check_true);
1036 Node* if_true = graph()->NewNode(common()->IfTrue(), branch); 1036 Node* if_true = graph()->NewNode(common()->IfTrue(), branch);
1037 Node* if_false = graph()->NewNode(common()->IfFalse(), branch); 1037 Node* if_false = graph()->NewNode(common()->IfFalse(), branch);
1038 check_false->AppendInput(graph()->zone(), if_false); 1038 check_false->AppendInput(graph()->zone(), if_false);
1039 NodeProperties::ChangeOp(check_false, 1039 NodeProperties::ChangeOp(check_false,
1040 common()->Merge(check_false->InputCount())); 1040 common()->Merge(check_false->InputCount()));
1041 check_true = if_true; 1041 check_true = if_true;
1042 } 1042 }
1043 1043
1044 // Fast case, because variable is not shadowed. Perform global object load. 1044 // Fast case, because variable is not shadowed. Perform global object load.
1045 Node* global = graph()->NewNode(
1046 javascript()->LoadContext(0, Context::GLOBAL_OBJECT_INDEX, true), context,
1047 context, effect);
1048 Node* fast = graph()->NewNode( 1045 Node* fast = graph()->NewNode(
1049 javascript()->LoadGlobal(access.name(), access.feedback(), 1046 javascript()->LoadGlobal(access.name(), access.feedback(),
1050 access.typeof_mode()), 1047 access.typeof_mode()),
1051 context, global, vector, context, state1, state2, global, check_true); 1048 vector, context, state1, state2, effect, check_true);
1052 1049
1053 // Slow case, because variable potentially shadowed. Perform dynamic lookup. 1050 // Slow case, because variable potentially shadowed. Perform dynamic lookup.
1054 uint32_t check_bitset = DynamicGlobalAccess::kFullCheckRequired; 1051 uint32_t check_bitset = DynamicGlobalAccess::kFullCheckRequired;
1055 Node* slow = graph()->NewNode( 1052 Node* slow = graph()->NewNode(
1056 javascript()->LoadDynamicGlobal(access.name(), check_bitset, 1053 javascript()->LoadDynamicGlobal(access.name(), check_bitset,
1057 access.feedback(), access.typeof_mode()), 1054 access.feedback(), access.typeof_mode()),
1058 vector, context, context, state1, state2, effect, check_false); 1055 vector, context, context, state1, state2, effect, check_false);
1059 1056
1060 // Replace value, effect and control uses accordingly. 1057 // Replace value, effect and control uses accordingly.
1061 Node* new_control = 1058 Node* new_control =
(...skipping 778 matching lines...) Expand 10 before | Expand all | Expand 10 after
1840 } 1837 }
1841 1838
1842 1839
1843 MachineOperatorBuilder* JSTypedLowering::machine() const { 1840 MachineOperatorBuilder* JSTypedLowering::machine() const {
1844 return jsgraph()->machine(); 1841 return jsgraph()->machine();
1845 } 1842 }
1846 1843
1847 } // namespace compiler 1844 } // namespace compiler
1848 } // namespace internal 1845 } // namespace internal
1849 } // namespace v8 1846 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-operator.cc ('k') | src/crankshaft/arm/lithium-arm.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698