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

Unified Diff: src/hydrogen.cc

Issue 15735005: Collect type feedback for power-of-2 right operands in BinaryOps. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebased. Created 7 years, 7 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
Index: src/hydrogen.cc
diff --git a/src/hydrogen.cc b/src/hydrogen.cc
index b473f58933d2975a9430e0368c16a88e02889d3a..d55a42b27003555373db32a09dc615459730b86f 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -9361,7 +9361,8 @@ HInstruction* HOptimizedGraphBuilder::BuildBinaryOperation(
TypeInfo left_info = expr->left_type();
TypeInfo right_info = expr->right_type();
TypeInfo result_info = expr->result_type();
- TypeInfo combined_info;
+ bool has_fixed_right_arg = expr->has_fixed_right_arg();
+ int fixed_right_arg_value = expr->fixed_right_arg_value();
Representation left_rep = ToRepresentation(left_info);
Representation right_rep = ToRepresentation(right_info);
Representation result_rep = ToRepresentation(result_info);
@@ -9391,7 +9392,12 @@ HInstruction* HOptimizedGraphBuilder::BuildBinaryOperation(
instr = HMul::New(zone(), context, left, right);
break;
case Token::MOD:
- instr = HMod::New(zone(), context, left, right);
+ instr = HMod::New(zone(),
+ context,
+ left,
+ right,
+ has_fixed_right_arg,
+ fixed_right_arg_value);
break;
case Token::DIV:
instr = HDiv::New(zone(), context, left, right);
« no previous file with comments | « src/code-stubs.h ('k') | src/hydrogen-instructions.h » ('j') | src/ia32/lithium-codegen-ia32.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698