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

Unified Diff: src/hydrogen.cc

Issue 17378005: Remove obsolete elements kind check for array literals. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 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 | « no previous file | test/mjsunit/tools/tickprocessor.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index 66b040743746e500ef935bc00f12153124578945..f9adf49b8ff2920b22553400f554f963d39fa6ab 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -6050,26 +6050,6 @@ void HOptimizedGraphBuilder::VisitArrayLiteral(ArrayLiteral* expr) {
Handle<FixedArray> constants = isolate()->factory()->empty_fixed_array();
int literal_index = expr->literal_index();
- // TODO(mstarzinger): The following check and deopt is actually obsolete
- // but test cases for the tick processor fails because profile differs.
-
- // Deopt if the array literal boilerplate ElementsKind is of a type
- // different than the expected one. The check isn't necessary if the
- // boilerplate has already been converted to TERMINAL_FAST_ELEMENTS_KIND.
- if (CanTransitionToMoreGeneralFastElementsKind(
- boilerplate_elements_kind, true)) {
- IfBuilder builder(this);
- HValue* boilerplate = AddInstruction(new(zone())
- HConstant(original_boilerplate_object));
- HValue* elements_kind = AddInstruction(new(zone())
- HElementsKind(boilerplate));
- HValue* expected_kind = AddInstruction(new(zone())
- HConstant(boilerplate_elements_kind));
- builder.IfCompare(elements_kind, expected_kind, Token::EQ);
- builder.Then();
- builder.ElseDeopt();
- }
-
AddInstruction(new(zone()) HPushArgument(AddInstruction(
new(zone()) HConstant(literals))));
AddInstruction(new(zone()) HPushArgument(AddInstruction(
« no previous file with comments | « no previous file | test/mjsunit/tools/tickprocessor.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698