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 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
284 } | 284 } |
285 | 285 |
286 | 286 |
287 void LUnaryMathOperation::PrintDataTo(StringStream* stream) { | 287 void LUnaryMathOperation::PrintDataTo(StringStream* stream) { |
288 stream->Add("/%s ", hydrogen()->OpName()); | 288 stream->Add("/%s ", hydrogen()->OpName()); |
289 InputAt(0)->PrintTo(stream); | 289 InputAt(0)->PrintTo(stream); |
290 } | 290 } |
291 | 291 |
292 | 292 |
293 void LLoadContextSlot::PrintDataTo(StringStream* stream) { | 293 void LLoadContextSlot::PrintDataTo(StringStream* stream) { |
294 InputAt(0)->PrintTo(stream); | |
295 stream->Add("[%d]", slot_index()); | 294 stream->Add("[%d]", slot_index()); |
296 } | 295 } |
297 | 296 |
298 | 297 |
299 void LStoreContextSlot::PrintDataTo(StringStream* stream) { | 298 void LStoreContextSlot::PrintDataTo(StringStream* stream) { |
| 299 stream->Add("[%d] <- ", slot_index()); |
300 InputAt(0)->PrintTo(stream); | 300 InputAt(0)->PrintTo(stream); |
301 stream->Add("[%d] <- ", slot_index()); | |
302 InputAt(1)->PrintTo(stream); | |
303 } | 301 } |
304 | 302 |
305 | 303 |
306 void LCallKeyed::PrintDataTo(StringStream* stream) { | 304 void LCallKeyed::PrintDataTo(StringStream* stream) { |
307 stream->Add("[rcx] #%d / ", arity()); | 305 stream->Add("[rcx] #%d / ", arity()); |
308 } | 306 } |
309 | 307 |
310 | 308 |
311 void LCallNamed::PrintDataTo(StringStream* stream) { | 309 void LCallNamed::PrintDataTo(StringStream* stream) { |
312 SmartPointer<char> name_string = name()->ToCString(); | 310 SmartPointer<char> name_string = name()->ToCString(); |
(...skipping 1400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1713 | 1711 |
1714 | 1712 |
1715 LInstruction* LChunkBuilder::DoStoreGlobal(HStoreGlobal* instr) { | 1713 LInstruction* LChunkBuilder::DoStoreGlobal(HStoreGlobal* instr) { |
1716 LStoreGlobal* result = new LStoreGlobal(UseRegister(instr->value()), | 1714 LStoreGlobal* result = new LStoreGlobal(UseRegister(instr->value()), |
1717 TempRegister()); | 1715 TempRegister()); |
1718 return instr->check_hole_value() ? AssignEnvironment(result) : result; | 1716 return instr->check_hole_value() ? AssignEnvironment(result) : result; |
1719 } | 1717 } |
1720 | 1718 |
1721 | 1719 |
1722 LInstruction* LChunkBuilder::DoLoadContextSlot(HLoadContextSlot* instr) { | 1720 LInstruction* LChunkBuilder::DoLoadContextSlot(HLoadContextSlot* instr) { |
1723 LOperand* context = UseRegisterAtStart(instr->value()); | 1721 return DefineAsRegister(new LLoadContextSlot()); |
1724 return DefineAsRegister(new LLoadContextSlot(context)); | |
1725 } | 1722 } |
1726 | 1723 |
1727 | 1724 |
1728 LInstruction* LChunkBuilder::DoStoreContextSlot(HStoreContextSlot* instr) { | 1725 LInstruction* LChunkBuilder::DoStoreContextSlot(HStoreContextSlot* instr) { |
1729 Abort("Unimplemented: DoStoreContextSlot"); // Temporarily disabled (whesse). | |
1730 LOperand* context; | |
1731 LOperand* value; | 1726 LOperand* value; |
| 1727 LOperand* temp_1 = NULL; |
| 1728 LOperand* temp_2 = NULL; |
1732 if (instr->NeedsWriteBarrier()) { | 1729 if (instr->NeedsWriteBarrier()) { |
1733 context = UseTempRegister(instr->context()); | |
1734 value = UseTempRegister(instr->value()); | 1730 value = UseTempRegister(instr->value()); |
| 1731 temp_1 = TempRegister(); |
| 1732 temp_2 = TempRegister(); |
1735 } else { | 1733 } else { |
1736 context = UseRegister(instr->context()); | |
1737 value = UseRegister(instr->value()); | 1734 value = UseRegister(instr->value()); |
1738 } | 1735 } |
1739 return new LStoreContextSlot(context, value); | 1736 return new LStoreContextSlot(value, temp_1, temp_2); |
1740 } | 1737 } |
1741 | 1738 |
1742 | 1739 |
1743 LInstruction* LChunkBuilder::DoLoadNamedField(HLoadNamedField* instr) { | 1740 LInstruction* LChunkBuilder::DoLoadNamedField(HLoadNamedField* instr) { |
1744 ASSERT(instr->representation().IsTagged()); | 1741 ASSERT(instr->representation().IsTagged()); |
1745 LOperand* obj = UseRegisterAtStart(instr->object()); | 1742 LOperand* obj = UseRegisterAtStart(instr->object()); |
1746 return DefineAsRegister(new LLoadNamedField(obj)); | 1743 return DefineAsRegister(new LLoadNamedField(obj)); |
1747 } | 1744 } |
1748 | 1745 |
1749 | 1746 |
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2035 | 2032 |
2036 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { | 2033 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { |
2037 HEnvironment* outer = current_block_->last_environment()->outer(); | 2034 HEnvironment* outer = current_block_->last_environment()->outer(); |
2038 current_block_->UpdateEnvironment(outer); | 2035 current_block_->UpdateEnvironment(outer); |
2039 return NULL; | 2036 return NULL; |
2040 } | 2037 } |
2041 | 2038 |
2042 } } // namespace v8::internal | 2039 } } // namespace v8::internal |
2043 | 2040 |
2044 #endif // V8_TARGET_ARCH_X64 | 2041 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |