| OLD | NEW |
| 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 1115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1126 LOperand* value = UseRegister(instr->value()); | 1126 LOperand* value = UseRegister(instr->value()); |
| 1127 LOperand* temp1 = instr->CanTruncateToInt32() ? TempRegister() : NULL; | 1127 LOperand* temp1 = instr->CanTruncateToInt32() ? TempRegister() : NULL; |
| 1128 LOperand* temp2 = instr->CanTruncateToInt32() ? TempRegister() : NULL; | 1128 LOperand* temp2 = instr->CanTruncateToInt32() ? TempRegister() : NULL; |
| 1129 LDoubleToI* result = new(zone()) LDoubleToI(value, temp1, temp2); | 1129 LDoubleToI* result = new(zone()) LDoubleToI(value, temp1, temp2); |
| 1130 return AssignEnvironment(DefineAsRegister(result)); | 1130 return AssignEnvironment(DefineAsRegister(result)); |
| 1131 } | 1131 } |
| 1132 } else if (from.IsInteger32()) { | 1132 } else if (from.IsInteger32()) { |
| 1133 info()->MarkAsDeferredCalling(); | 1133 info()->MarkAsDeferredCalling(); |
| 1134 if (to.IsTagged()) { | 1134 if (to.IsTagged()) { |
| 1135 HValue* val = instr->value(); | 1135 HValue* val = instr->value(); |
| 1136 LOperand* value = UseRegisterAtStart(val); | |
| 1137 | 1136 |
| 1138 if (val->CheckFlag(HInstruction::kUint32)) { | 1137 if (val->CheckFlag(HInstruction::kUint32)) { |
| 1138 LOperand* value = UseRegister(val); |
| 1139 LNumberTagU* result = new(zone()) LNumberTagU(value, | 1139 LNumberTagU* result = new(zone()) LNumberTagU(value, |
| 1140 TempRegister(), | 1140 TempRegister(), |
| 1141 TempRegister()); | 1141 TempRegister()); |
| 1142 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result))); | 1142 return AssignEnvironment(AssignPointerMap(DefineAsRegister(result))); |
| 1143 } else { | 1143 } else { |
| 1144 STATIC_ASSERT((kMinInt == Smi::kMinValue) && | 1144 STATIC_ASSERT((kMinInt == Smi::kMinValue) && |
| 1145 (kMaxInt == Smi::kMaxValue)); | 1145 (kMaxInt == Smi::kMaxValue)); |
| 1146 LOperand* value = UseRegisterAtStart(val); |
| 1146 return DefineAsRegister(new(zone()) LSmiTag(value)); | 1147 return DefineAsRegister(new(zone()) LSmiTag(value)); |
| 1147 } | 1148 } |
| 1148 } else if (to.IsSmi()) { | 1149 } else if (to.IsSmi()) { |
| 1149 LOperand* value = UseRegisterAtStart(instr->value()); | 1150 LOperand* value = UseRegisterAtStart(instr->value()); |
| 1150 // This cannot deoptimize because an A64 smi can represent any int32. | 1151 // This cannot deoptimize because an A64 smi can represent any int32. |
| 1151 return DefineAsRegister(new(zone()) LInteger32ToSmi(value)); | 1152 return DefineAsRegister(new(zone()) LInteger32ToSmi(value)); |
| 1152 } else { | 1153 } else { |
| 1153 ASSERT(to.IsDouble()); | 1154 ASSERT(to.IsDouble()); |
| 1154 if (instr->value()->CheckFlag(HInstruction::kUint32)) { | 1155 if (instr->value()->CheckFlag(HInstruction::kUint32)) { |
| 1155 return DefineAsRegister( | 1156 return DefineAsRegister( |
| (...skipping 1301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2457 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) { | 2458 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) { |
| 2458 LOperand* receiver = UseRegister(instr->receiver()); | 2459 LOperand* receiver = UseRegister(instr->receiver()); |
| 2459 LOperand* function = UseRegisterAtStart(instr->function()); | 2460 LOperand* function = UseRegisterAtStart(instr->function()); |
| 2460 LOperand* temp = TempRegister(); | 2461 LOperand* temp = TempRegister(); |
| 2461 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function, temp); | 2462 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function, temp); |
| 2462 return AssignEnvironment(DefineAsRegister(result)); | 2463 return AssignEnvironment(DefineAsRegister(result)); |
| 2463 } | 2464 } |
| 2464 | 2465 |
| 2465 | 2466 |
| 2466 } } // namespace v8::internal | 2467 } } // namespace v8::internal |
| OLD | NEW |