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

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

Issue 195023002: Fix uses of range analysis results in HChange. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 9 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/a64/lithium-a64.h ('k') | src/a64/lithium-codegen-a64.cc » ('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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after
1134 TempRegister()); 1134 TempRegister());
1135 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result))); 1135 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result)));
1136 } else { 1136 } else {
1137 STATIC_ASSERT((kMinInt == Smi::kMinValue) && 1137 STATIC_ASSERT((kMinInt == Smi::kMinValue) &&
1138 (kMaxInt == Smi::kMaxValue)); 1138 (kMaxInt == Smi::kMaxValue));
1139 LOperand* value = UseRegisterAtStart(instr->value()); 1139 LOperand* value = UseRegisterAtStart(instr->value());
1140 return DefineAsRegister(new(zone()) LSmiTag(value)); 1140 return DefineAsRegister(new(zone()) LSmiTag(value));
1141 } 1141 }
1142 } else if (to.IsSmi()) { 1142 } else if (to.IsSmi()) {
1143 LOperand* value = UseRegisterAtStart(instr->value()); 1143 LOperand* value = UseRegisterAtStart(instr->value());
1144 LInstruction* result = DefineAsRegister(new(zone()) LSmiTag(value));
1144 if (instr->value()->CheckFlag(HInstruction::kUint32)) { 1145 if (instr->value()->CheckFlag(HInstruction::kUint32)) {
1145 LUint32ToSmi* result = new(zone()) LUint32ToSmi(value); 1146 result = AssignEnvironment(result);
1146 return AssignEnvironment(DefineAsRegister(result));
1147 } else {
1148 // This cannot deoptimize because an A64 smi can represent any int32.
1149 return DefineAsRegister(new(zone()) LInteger32ToSmi(value));
1150 } 1147 }
1148 return result;
1151 } else { 1149 } else {
1152 ASSERT(to.IsDouble()); 1150 ASSERT(to.IsDouble());
1153 if (instr->value()->CheckFlag(HInstruction::kUint32)) { 1151 if (instr->value()->CheckFlag(HInstruction::kUint32)) {
1154 return DefineAsRegister( 1152 return DefineAsRegister(
1155 new(zone()) LUint32ToDouble(UseRegisterAtStart(instr->value()))); 1153 new(zone()) LUint32ToDouble(UseRegisterAtStart(instr->value())));
1156 } else { 1154 } else {
1157 return DefineAsRegister( 1155 return DefineAsRegister(
1158 new(zone()) LInteger32ToDouble(UseRegisterAtStart(instr->value()))); 1156 new(zone()) LInteger32ToDouble(UseRegisterAtStart(instr->value())));
1159 } 1157 }
1160 } 1158 }
(...skipping 1396 matching lines...) Expand 10 before | Expand all | Expand 10 after
2557 2555
2558 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) { 2556 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) {
2559 LOperand* receiver = UseRegister(instr->receiver()); 2557 LOperand* receiver = UseRegister(instr->receiver());
2560 LOperand* function = UseRegister(instr->function()); 2558 LOperand* function = UseRegister(instr->function());
2561 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function); 2559 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function);
2562 return AssignEnvironment(DefineAsRegister(result)); 2560 return AssignEnvironment(DefineAsRegister(result));
2563 } 2561 }
2564 2562
2565 2563
2566 } } // namespace v8::internal 2564 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/a64/lithium-a64.h ('k') | src/a64/lithium-codegen-a64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698