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

Unified Diff: src/compiler/js-typed-lowering.cc

Issue 1224083002: Revert of [turbofan] Optimize string "length" property access based on types. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/js-typed-lowering.h ('k') | src/compiler/pipeline.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/js-typed-lowering.cc
diff --git a/src/compiler/js-typed-lowering.cc b/src/compiler/js-typed-lowering.cc
index 4c69c3747ec08507f9de2d2bd5680d7b41f0fe7c..051009dd6ea4b533f3b8a0b67b07467fb0a87d55 100644
--- a/src/compiler/js-typed-lowering.cc
+++ b/src/compiler/js-typed-lowering.cc
@@ -792,27 +792,6 @@
Node* constant = jsgraph()->Constant(constant_value);
ReplaceWithValue(node, constant);
return Replace(constant);
- }
- return NoChange();
-}
-
-
-Reduction JSTypedLowering::ReduceJSLoadNamed(Node* node) {
- DCHECK_EQ(IrOpcode::kJSLoadNamed, node->opcode());
- Node* receiver = NodeProperties::GetValueInput(node, 0);
- Type* receiver_type = NodeProperties::GetBounds(receiver).upper;
- Node* effect = NodeProperties::GetEffectInput(node);
- Node* control = NodeProperties::GetControlInput(node);
- Handle<Name> name = LoadNamedParametersOf(node->op()).name().handle();
- // Optimize "length" property of strings.
- if (name.is_identical_to(factory()->length_string()) &&
- receiver_type->Is(Type::String())) {
- Node* value = effect =
- graph()->NewNode(simplified()->LoadField(
- AccessBuilder::ForStringLength(graph()->zone())),
- receiver, effect, control);
- ReplaceWithValue(node, value, effect);
- return Replace(value);
}
return NoChange();
}
@@ -1642,8 +1621,6 @@
return ReduceJSToString(node);
case IrOpcode::kJSLoadGlobal:
return ReduceJSLoadGlobal(node);
- case IrOpcode::kJSLoadNamed:
- return ReduceJSLoadNamed(node);
case IrOpcode::kJSLoadProperty:
return ReduceJSLoadProperty(node);
case IrOpcode::kJSStoreProperty:
« no previous file with comments | « src/compiler/js-typed-lowering.h ('k') | src/compiler/pipeline.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698