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

Unified Diff: src/hydrogen.cc

Issue 595453002: Pass the ast_id to HandleKeyed to make sure it's the right one (e.g., CountOperation, not just the … (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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/hydrogen.h ('k') | test/mjsunit/keyed-named-access.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 e5a93a7bd5b1f4ec513e0427d54f033b0fdf5dce..848178c4b0741af37292a4532aec80a8962f460f 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -6436,7 +6436,7 @@ void HOptimizedGraphBuilder::BuildStore(Expression* expr,
HValue* key = environment()->ExpressionStackAt(1);
HValue* object = environment()->ExpressionStackAt(2);
bool has_side_effects = false;
- HandleKeyedElementAccess(object, key, value, expr, return_id, STORE,
+ HandleKeyedElementAccess(object, key, value, expr, ast_id, return_id, STORE,
&has_side_effects);
Drop(3);
Push(value);
@@ -7129,7 +7129,7 @@ HValue* HOptimizedGraphBuilder::HandlePolymorphicElementAccess(
HValue* HOptimizedGraphBuilder::HandleKeyedElementAccess(
- HValue* obj, HValue* key, HValue* val, Expression* expr,
+ HValue* obj, HValue* key, HValue* val, Expression* expr, BailoutId ast_id,
BailoutId return_id, PropertyAccessType access_type,
bool* has_side_effects) {
if (key->ActualValue()->IsConstant()) {
@@ -7143,7 +7143,7 @@ HValue* HOptimizedGraphBuilder::HandleKeyedElementAccess(
Handle<String>::cast(constant));
}
HInstruction* instr =
- BuildNamedAccess(access_type, expr->id(), return_id, expr, obj,
+ BuildNamedAccess(access_type, ast_id, return_id, expr, obj,
Handle<String>::cast(constant), val, false);
if (instr == NULL || instr->IsLinked()) {
*has_side_effects = false;
@@ -7365,7 +7365,7 @@ void HOptimizedGraphBuilder::BuildLoad(Property* expr,
bool has_side_effects = false;
HValue* load = HandleKeyedElementAccess(
- obj, key, NULL, expr, expr->LoadId(), LOAD, &has_side_effects);
+ obj, key, NULL, expr, ast_id, expr->LoadId(), LOAD, &has_side_effects);
if (has_side_effects) {
if (ast_context()->IsEffect()) {
Add<HSimulate>(ast_id, REMOVABLE_SIMULATE);
« no previous file with comments | « src/hydrogen.h ('k') | test/mjsunit/keyed-named-access.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698