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 1748 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1759 return AssignEnvironment(Define(result, temp)); | 1759 return AssignEnvironment(Define(result, temp)); |
1760 } | 1760 } |
1761 | 1761 |
1762 | 1762 |
1763 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { | 1763 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { |
1764 LOperand* value = UseRegisterAtStart(instr->value()); | 1764 LOperand* value = UseRegisterAtStart(instr->value()); |
1765 return AssignEnvironment(new(zone()) LCheckSmi(value)); | 1765 return AssignEnvironment(new(zone()) LCheckSmi(value)); |
1766 } | 1766 } |
1767 | 1767 |
1768 | 1768 |
| 1769 LInstruction* LChunkBuilder::DoCheckSmiOrInt32(HCheckSmiOrInt32* instr) { |
| 1770 if (instr->representation().IsTagged() && !instr->type().IsSmi()) { |
| 1771 LOperand* value = UseRegisterAtStart(instr->value()); |
| 1772 return AssignEnvironment(new(zone()) LCheckSmi(value)); |
| 1773 } else { |
| 1774 return NULL; |
| 1775 } |
| 1776 } |
| 1777 |
| 1778 |
1769 LInstruction* LChunkBuilder::DoCheckFunction(HCheckFunction* instr) { | 1779 LInstruction* LChunkBuilder::DoCheckFunction(HCheckFunction* instr) { |
1770 LOperand* value = UseRegisterAtStart(instr->value()); | 1780 LOperand* value = UseRegisterAtStart(instr->value()); |
1771 return AssignEnvironment(new(zone()) LCheckFunction(value)); | 1781 return AssignEnvironment(new(zone()) LCheckFunction(value)); |
1772 } | 1782 } |
1773 | 1783 |
1774 | 1784 |
1775 LInstruction* LChunkBuilder::DoCheckMaps(HCheckMaps* instr) { | 1785 LInstruction* LChunkBuilder::DoCheckMaps(HCheckMaps* instr) { |
1776 LOperand* value = UseRegisterAtStart(instr->value()); | 1786 LOperand* value = UseRegisterAtStart(instr->value()); |
1777 LCheckMaps* result = new(zone()) LCheckMaps(value); | 1787 LCheckMaps* result = new(zone()) LCheckMaps(value); |
1778 return AssignEnvironment(result); | 1788 return AssignEnvironment(result); |
(...skipping 606 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2385 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2395 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2386 LOperand* object = UseRegister(instr->object()); | 2396 LOperand* object = UseRegister(instr->object()); |
2387 LOperand* index = UseTempRegister(instr->index()); | 2397 LOperand* index = UseTempRegister(instr->index()); |
2388 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); | 2398 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); |
2389 } | 2399 } |
2390 | 2400 |
2391 | 2401 |
2392 } } // namespace v8::internal | 2402 } } // namespace v8::internal |
2393 | 2403 |
2394 #endif // V8_TARGET_ARCH_X64 | 2404 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |