| 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 1541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1552 | 1552 |
| 1553 | 1553 |
| 1554 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { | 1554 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { |
| 1555 LOperand* object = UseRegister(instr->value()); | 1555 LOperand* object = UseRegister(instr->value()); |
| 1556 LValueOf* result = new LValueOf(object, TempRegister()); | 1556 LValueOf* result = new LValueOf(object, TempRegister()); |
| 1557 return AssignEnvironment(DefineSameAsFirst(result)); | 1557 return AssignEnvironment(DefineSameAsFirst(result)); |
| 1558 } | 1558 } |
| 1559 | 1559 |
| 1560 | 1560 |
| 1561 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { | 1561 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { |
| 1562 return AssignEnvironment(new LBoundsCheck(UseRegisterAtStart(instr->index()), | 1562 return AssignEnvironment(new LBoundsCheck( |
| 1563 UseAtStart(instr->length()))); | 1563 UseRegisterOrConstantAtStart(instr->index()), |
| 1564 UseAtStart(instr->length()))); |
| 1564 } | 1565 } |
| 1565 | 1566 |
| 1566 | 1567 |
| 1567 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { | 1568 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { |
| 1568 // The control instruction marking the end of a block that completed | 1569 // The control instruction marking the end of a block that completed |
| 1569 // abruptly (e.g., threw an exception). There is nothing specific to do. | 1570 // abruptly (e.g., threw an exception). There is nothing specific to do. |
| 1570 return NULL; | 1571 return NULL; |
| 1571 } | 1572 } |
| 1572 | 1573 |
| 1573 | 1574 |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1874 LOperand* input = UseRegisterAtStart(instr->value()); | 1875 LOperand* input = UseRegisterAtStart(instr->value()); |
| 1875 return DefineAsRegister(new LLoadExternalArrayPointer(input)); | 1876 return DefineAsRegister(new LLoadExternalArrayPointer(input)); |
| 1876 } | 1877 } |
| 1877 | 1878 |
| 1878 | 1879 |
| 1879 LInstruction* LChunkBuilder::DoLoadKeyedFastElement( | 1880 LInstruction* LChunkBuilder::DoLoadKeyedFastElement( |
| 1880 HLoadKeyedFastElement* instr) { | 1881 HLoadKeyedFastElement* instr) { |
| 1881 ASSERT(instr->representation().IsTagged()); | 1882 ASSERT(instr->representation().IsTagged()); |
| 1882 ASSERT(instr->key()->representation().IsInteger32()); | 1883 ASSERT(instr->key()->representation().IsInteger32()); |
| 1883 LOperand* obj = UseRegisterAtStart(instr->object()); | 1884 LOperand* obj = UseRegisterAtStart(instr->object()); |
| 1884 LOperand* key = UseRegisterAtStart(instr->key()); | 1885 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); |
| 1885 LLoadKeyedFastElement* result = new LLoadKeyedFastElement(obj, key); | 1886 LLoadKeyedFastElement* result = new LLoadKeyedFastElement(obj, key); |
| 1886 return AssignEnvironment(DefineSameAsFirst(result)); | 1887 return AssignEnvironment(DefineAsRegister(result)); |
| 1887 } | 1888 } |
| 1888 | 1889 |
| 1889 | 1890 |
| 1890 LInstruction* LChunkBuilder::DoLoadKeyedFastDoubleElement( | 1891 LInstruction* LChunkBuilder::DoLoadKeyedFastDoubleElement( |
| 1891 HLoadKeyedFastDoubleElement* instr) { | 1892 HLoadKeyedFastDoubleElement* instr) { |
| 1892 ASSERT(instr->representation().IsDouble()); | 1893 ASSERT(instr->representation().IsDouble()); |
| 1893 ASSERT(instr->key()->representation().IsInteger32()); | 1894 ASSERT(instr->key()->representation().IsInteger32()); |
| 1894 LOperand* elements = UseRegisterAtStart(instr->elements()); | 1895 LOperand* elements = UseRegisterAtStart(instr->elements()); |
| 1895 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); | 1896 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); |
| 1896 LLoadKeyedFastDoubleElement* result = | 1897 LLoadKeyedFastDoubleElement* result = |
| (...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2256 LOperand* key = UseOrConstantAtStart(instr->key()); | 2257 LOperand* key = UseOrConstantAtStart(instr->key()); |
| 2257 LOperand* object = UseOrConstantAtStart(instr->object()); | 2258 LOperand* object = UseOrConstantAtStart(instr->object()); |
| 2258 LIn* result = new LIn(context, key, object); | 2259 LIn* result = new LIn(context, key, object); |
| 2259 return MarkAsCall(DefineFixed(result, eax), instr); | 2260 return MarkAsCall(DefineFixed(result, eax), instr); |
| 2260 } | 2261 } |
| 2261 | 2262 |
| 2262 | 2263 |
| 2263 } } // namespace v8::internal | 2264 } } // namespace v8::internal |
| 2264 | 2265 |
| 2265 #endif // V8_TARGET_ARCH_IA32 | 2266 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |