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

Unified Diff: src/hydrogen.cc

Issue 10868032: Fix DoDeferredNumberTagU to keep the value in xmm1 instead of xmm0 on x64. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: expose gc Created 8 years, 4 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/arm/lithium-arm.cc ('k') | src/hydrogen-instructions.cc » ('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 7a3e203beb759bad5cd333b715f4a7ef81285dbe..1681128654d377cc273d48b0a24969fd140510f2 100644
--- a/src/hydrogen.cc
+++ b/src/hydrogen.cc
@@ -8270,7 +8270,16 @@ HInstruction* HGraphBuilder::BuildBinaryOperation(BinaryOperation* expr,
case Token::SHR:
instr = HShr::NewHShr(zone(), context, left, right);
if (FLAG_opt_safe_uint32_operations && instr->IsShr()) {
- graph()->RecordUint32Instruction(instr);
+ bool can_be_shift_by_zero = true;
+ if (right->IsConstant()) {
+ HConstant* right_const = HConstant::cast(right);
+ if (right_const->HasInteger32Value() &&
+ (right_const->Integer32Value() & 0x1f) != 0) {
+ can_be_shift_by_zero = false;
+ }
+ }
+
+ if (can_be_shift_by_zero) graph()->RecordUint32Instruction(instr);
}
break;
case Token::SHL:
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/hydrogen-instructions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698