| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 1525 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1536 if (instr->HasPowerOf2Divisor()) { | 1536 if (instr->HasPowerOf2Divisor()) { |
| 1537 ASSERT(!right->CanBeZero()); | 1537 ASSERT(!right->CanBeZero()); |
| 1538 LModI* mod = new(zone()) LModI(UseRegisterAtStart(left), | 1538 LModI* mod = new(zone()) LModI(UseRegisterAtStart(left), |
| 1539 UseOrConstant(right), | 1539 UseOrConstant(right), |
| 1540 NULL); | 1540 NULL); |
| 1541 LInstruction* result = DefineSameAsFirst(mod); | 1541 LInstruction* result = DefineSameAsFirst(mod); |
| 1542 return (left->CanBeNegative() && | 1542 return (left->CanBeNegative() && |
| 1543 instr->CheckFlag(HValue::kBailoutOnMinusZero)) | 1543 instr->CheckFlag(HValue::kBailoutOnMinusZero)) |
| 1544 ? AssignEnvironment(result) | 1544 ? AssignEnvironment(result) |
| 1545 : result; | 1545 : result; |
| 1546 } else if (instr->has_fixed_right_arg()) { | 1546 } else if (instr->fixed_right_arg().has_value) { |
| 1547 LModI* mod = new(zone()) LModI(UseRegister(left), | 1547 LModI* mod = new(zone()) LModI(UseRegister(left), |
| 1548 UseRegisterAtStart(right), | 1548 UseRegisterAtStart(right), |
| 1549 NULL); | 1549 NULL); |
| 1550 return AssignEnvironment(DefineSameAsFirst(mod)); | 1550 return AssignEnvironment(DefineSameAsFirst(mod)); |
| 1551 } else { | 1551 } else { |
| 1552 // The temporary operand is necessary to ensure that right is not | 1552 // The temporary operand is necessary to ensure that right is not |
| 1553 // allocated into edx. | 1553 // allocated into edx. |
| 1554 LModI* mod = new(zone()) LModI(UseFixed(left, eax), | 1554 LModI* mod = new(zone()) LModI(UseFixed(left, eax), |
| 1555 UseRegister(right), | 1555 UseRegister(right), |
| 1556 FixedTemp(edx)); | 1556 FixedTemp(edx)); |
| (...skipping 1249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2806 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2806 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
| 2807 LOperand* object = UseRegister(instr->object()); | 2807 LOperand* object = UseRegister(instr->object()); |
| 2808 LOperand* index = UseTempRegister(instr->index()); | 2808 LOperand* index = UseTempRegister(instr->index()); |
| 2809 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); | 2809 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); |
| 2810 } | 2810 } |
| 2811 | 2811 |
| 2812 | 2812 |
| 2813 } } // namespace v8::internal | 2813 } } // namespace v8::internal |
| 2814 | 2814 |
| 2815 #endif // V8_TARGET_ARCH_IA32 | 2815 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |