| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 1421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1432 | 1432 |
| 1433 | 1433 |
| 1434 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { | 1434 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { |
| 1435 // The control instruction marking the end of a block that completed | 1435 // The control instruction marking the end of a block that completed |
| 1436 // abruptly (e.g., threw an exception). There is nothing specific to do. | 1436 // abruptly (e.g., threw an exception). There is nothing specific to do. |
| 1437 return NULL; | 1437 return NULL; |
| 1438 } | 1438 } |
| 1439 | 1439 |
| 1440 | 1440 |
| 1441 LInstruction* LChunkBuilder::DoThrow(HThrow* instr) { | 1441 LInstruction* LChunkBuilder::DoThrow(HThrow* instr) { |
| 1442 Abort("Unimplemented: %s", "DoThrow"); | 1442 LOperand* value = UseFixed(instr->value(), rax); |
| 1443 return NULL; | 1443 return MarkAsCall(new LThrow(value), instr); |
| 1444 } | 1444 } |
| 1445 | 1445 |
| 1446 | 1446 |
| 1447 LInstruction* LChunkBuilder::DoChange(HChange* instr) { | 1447 LInstruction* LChunkBuilder::DoChange(HChange* instr) { |
| 1448 Representation from = instr->from(); | 1448 Representation from = instr->from(); |
| 1449 Representation to = instr->to(); | 1449 Representation to = instr->to(); |
| 1450 if (from.IsTagged()) { | 1450 if (from.IsTagged()) { |
| 1451 if (to.IsDouble()) { | 1451 if (to.IsDouble()) { |
| 1452 LOperand* value = UseRegister(instr->value()); | 1452 LOperand* value = UseRegister(instr->value()); |
| 1453 LNumberUntagD* res = new LNumberUntagD(value); | 1453 LNumberUntagD* res = new LNumberUntagD(value); |
| (...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1633 | 1633 |
| 1634 | 1634 |
| 1635 LInstruction* LChunkBuilder::DoLoadKeyedGeneric(HLoadKeyedGeneric* instr) { | 1635 LInstruction* LChunkBuilder::DoLoadKeyedGeneric(HLoadKeyedGeneric* instr) { |
| 1636 Abort("Unimplemented: %s", "DoLoadKeyedGeneric"); | 1636 Abort("Unimplemented: %s", "DoLoadKeyedGeneric"); |
| 1637 return NULL; | 1637 return NULL; |
| 1638 } | 1638 } |
| 1639 | 1639 |
| 1640 | 1640 |
| 1641 LInstruction* LChunkBuilder::DoStoreKeyedFastElement( | 1641 LInstruction* LChunkBuilder::DoStoreKeyedFastElement( |
| 1642 HStoreKeyedFastElement* instr) { | 1642 HStoreKeyedFastElement* instr) { |
| 1643 Abort("Unimplemented: %s", "DoStoreKeyedFastElement"); | 1643 bool needs_write_barrier = instr->NeedsWriteBarrier(); |
| 1644 return NULL; | 1644 ASSERT(instr->value()->representation().IsTagged()); |
| 1645 ASSERT(instr->object()->representation().IsTagged()); |
| 1646 ASSERT(instr->key()->representation().IsInteger32()); |
| 1647 |
| 1648 LOperand* obj = UseTempRegister(instr->object()); |
| 1649 LOperand* val = needs_write_barrier |
| 1650 ? UseTempRegister(instr->value()) |
| 1651 : UseRegisterAtStart(instr->value()); |
| 1652 LOperand* key = needs_write_barrier |
| 1653 ? UseTempRegister(instr->key()) |
| 1654 : UseRegisterOrConstantAtStart(instr->key()); |
| 1655 |
| 1656 return AssignEnvironment(new LStoreKeyedFastElement(obj, key, val)); |
| 1645 } | 1657 } |
| 1646 | 1658 |
| 1647 | 1659 |
| 1648 LInstruction* LChunkBuilder::DoStoreKeyedGeneric(HStoreKeyedGeneric* instr) { | 1660 LInstruction* LChunkBuilder::DoStoreKeyedGeneric(HStoreKeyedGeneric* instr) { |
| 1649 Abort("Unimplemented: %s", "DoStoreKeyedGeneric"); | 1661 Abort("Unimplemented: %s", "DoStoreKeyedGeneric"); |
| 1650 return NULL; | 1662 return NULL; |
| 1651 } | 1663 } |
| 1652 | 1664 |
| 1653 | 1665 |
| 1654 LInstruction* LChunkBuilder::DoStoreNamedField(HStoreNamedField* instr) { | 1666 LInstruction* LChunkBuilder::DoStoreNamedField(HStoreNamedField* instr) { |
| (...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1815 | 1827 |
| 1816 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { | 1828 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { |
| 1817 HEnvironment* outer = current_block_->last_environment()->outer(); | 1829 HEnvironment* outer = current_block_->last_environment()->outer(); |
| 1818 current_block_->UpdateEnvironment(outer); | 1830 current_block_->UpdateEnvironment(outer); |
| 1819 return NULL; | 1831 return NULL; |
| 1820 } | 1832 } |
| 1821 | 1833 |
| 1822 } } // namespace v8::internal | 1834 } } // namespace v8::internal |
| 1823 | 1835 |
| 1824 #endif // V8_TARGET_ARCH_X64 | 1836 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |