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

Side by Side Diff: src/x87/lithium-x87.cc

Issue 630023002: Remove FLAG_opt_safe_uint32_operations. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « src/x64/lithium-x64.cc ('k') | test/mjsunit/compiler/shift-shr.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_X87 7 #if V8_TARGET_ARCH_X87
8 8
9 #include "src/hydrogen-osr.h" 9 #include "src/hydrogen-osr.h"
10 #include "src/lithium-inl.h" 10 #include "src/lithium-inl.h"
(...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after
729 if (instr->representation().IsSmi() && constant_value > 0) { 729 if (instr->representation().IsSmi() && constant_value > 0) {
730 does_deopt = !instr->CheckUsesForFlag(HValue::kTruncatingToSmi); 730 does_deopt = !instr->CheckUsesForFlag(HValue::kTruncatingToSmi);
731 } 731 }
732 } else { 732 } else {
733 right = UseFixed(right_value, ecx); 733 right = UseFixed(right_value, ecx);
734 } 734 }
735 735
736 // Shift operations can only deoptimize if we do a logical shift by 0 and 736 // Shift operations can only deoptimize if we do a logical shift by 0 and
737 // the result cannot be truncated to int32. 737 // the result cannot be truncated to int32.
738 if (op == Token::SHR && constant_value == 0) { 738 if (op == Token::SHR && constant_value == 0) {
739 if (FLAG_opt_safe_uint32_operations) { 739 does_deopt = !instr->CheckFlag(HInstruction::kUint32);
740 does_deopt = !instr->CheckFlag(HInstruction::kUint32);
741 } else {
742 does_deopt = !instr->CheckUsesForFlag(HValue::kTruncatingToInt32);
743 }
744 } 740 }
745 741
746 LInstruction* result = 742 LInstruction* result =
747 DefineSameAsFirst(new(zone()) LShiftI(op, left, right, does_deopt)); 743 DefineSameAsFirst(new(zone()) LShiftI(op, left, right, does_deopt));
748 return does_deopt ? AssignEnvironment(result) : result; 744 return does_deopt ? AssignEnvironment(result) : result;
749 } else { 745 } else {
750 return DoArithmeticT(op, instr); 746 return DoArithmeticT(op, instr);
751 } 747 }
752 } 748 }
753 749
(...skipping 1957 matching lines...) Expand 10 before | Expand all | Expand 10 after
2711 LOperand* function = UseRegisterAtStart(instr->function()); 2707 LOperand* function = UseRegisterAtStart(instr->function());
2712 LAllocateBlockContext* result = 2708 LAllocateBlockContext* result =
2713 new(zone()) LAllocateBlockContext(context, function); 2709 new(zone()) LAllocateBlockContext(context, function);
2714 return MarkAsCall(DefineFixed(result, esi), instr); 2710 return MarkAsCall(DefineFixed(result, esi), instr);
2715 } 2711 }
2716 2712
2717 2713
2718 } } // namespace v8::internal 2714 } } // namespace v8::internal
2719 2715
2720 #endif // V8_TARGET_ARCH_X87 2716 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/x64/lithium-x64.cc ('k') | test/mjsunit/compiler/shift-shr.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698