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 1630 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1641 | 1641 |
1642 | 1642 |
1643 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { | 1643 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { |
1644 LOperand* object = UseRegister(instr->value()); | 1644 LOperand* object = UseRegister(instr->value()); |
1645 LValueOf* result = new(zone()) LValueOf(object, TempRegister()); | 1645 LValueOf* result = new(zone()) LValueOf(object, TempRegister()); |
1646 return DefineSameAsFirst(result); | 1646 return DefineSameAsFirst(result); |
1647 } | 1647 } |
1648 | 1648 |
1649 | 1649 |
1650 LInstruction* LChunkBuilder::DoDateField(HDateField* instr) { | 1650 LInstruction* LChunkBuilder::DoDateField(HDateField* instr) { |
1651 LOperand* date = UseRegister(instr->value()); | 1651 LOperand* date = UseFixed(instr->value(), eax); |
1652 LDateField* result = | 1652 LDateField* result = |
1653 new(zone()) LDateField(date, TempRegister(), instr->index()); | 1653 new(zone()) LDateField(date, FixedTemp(ecx), instr->index()); |
1654 return DefineSameAsFirst(result); | 1654 return MarkAsCall(DefineFixed(result, eax), instr); |
1655 } | 1655 } |
1656 | 1656 |
1657 | 1657 |
1658 LInstruction* LChunkBuilder::DoSetDateField(HSetDateField* instr) { | |
1659 LOperand* date = UseTempRegister(instr->OperandAt(1)); | |
1660 LOperand* value = UseTempRegister(instr->OperandAt(2)); | |
1661 LSetDateField* result = | |
1662 new(zone()) LSetDateField(date, value, TempRegister(), instr->index()); | |
1663 return DefineAsRegister(result); | |
1664 } | |
1665 | |
1666 | |
1667 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { | 1658 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { |
1668 return AssignEnvironment(new(zone()) LBoundsCheck( | 1659 return AssignEnvironment(new(zone()) LBoundsCheck( |
1669 UseRegisterOrConstantAtStart(instr->index()), | 1660 UseRegisterOrConstantAtStart(instr->index()), |
1670 UseAtStart(instr->length()))); | 1661 UseAtStart(instr->length()))); |
1671 } | 1662 } |
1672 | 1663 |
1673 | 1664 |
1674 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { | 1665 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { |
1675 // The control instruction marking the end of a block that completed | 1666 // The control instruction marking the end of a block that completed |
1676 // abruptly (e.g., threw an exception). There is nothing specific to do. | 1667 // abruptly (e.g., threw an exception). There is nothing specific to do. |
(...skipping 756 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2433 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2424 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2434 LOperand* object = UseRegister(instr->object()); | 2425 LOperand* object = UseRegister(instr->object()); |
2435 LOperand* index = UseTempRegister(instr->index()); | 2426 LOperand* index = UseTempRegister(instr->index()); |
2436 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); | 2427 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); |
2437 } | 2428 } |
2438 | 2429 |
2439 | 2430 |
2440 } } // namespace v8::internal | 2431 } } // namespace v8::internal |
2441 | 2432 |
2442 #endif // V8_TARGET_ARCH_IA32 | 2433 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |