| 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 1550 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1561 | 1561 |
| 1562 | 1562 |
| 1563 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { | 1563 LInstruction* LChunkBuilder::DoValueOf(HValueOf* instr) { |
| 1564 LOperand* object = UseRegister(instr->value()); | 1564 LOperand* object = UseRegister(instr->value()); |
| 1565 LValueOf* result = new LValueOf(object, TempRegister()); | 1565 LValueOf* result = new LValueOf(object, TempRegister()); |
| 1566 return AssignEnvironment(DefineSameAsFirst(result)); | 1566 return AssignEnvironment(DefineSameAsFirst(result)); |
| 1567 } | 1567 } |
| 1568 | 1568 |
| 1569 | 1569 |
| 1570 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { | 1570 LInstruction* LChunkBuilder::DoBoundsCheck(HBoundsCheck* instr) { |
| 1571 return AssignEnvironment(new LBoundsCheck(UseRegisterAtStart(instr->index()), | 1571 return AssignEnvironment(new LBoundsCheck( |
| 1572 UseAtStart(instr->length()))); | 1572 UseRegisterOrConstantAtStart(instr->index()), |
| 1573 UseAtStart(instr->length()))); |
| 1573 } | 1574 } |
| 1574 | 1575 |
| 1575 | 1576 |
| 1576 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { | 1577 LInstruction* LChunkBuilder::DoAbnormalExit(HAbnormalExit* instr) { |
| 1577 // The control instruction marking the end of a block that completed | 1578 // The control instruction marking the end of a block that completed |
| 1578 // abruptly (e.g., threw an exception). There is nothing specific to do. | 1579 // abruptly (e.g., threw an exception). There is nothing specific to do. |
| 1579 return NULL; | 1580 return NULL; |
| 1580 } | 1581 } |
| 1581 | 1582 |
| 1582 | 1583 |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1883 LOperand* input = UseRegisterAtStart(instr->value()); | 1884 LOperand* input = UseRegisterAtStart(instr->value()); |
| 1884 return DefineAsRegister(new LLoadExternalArrayPointer(input)); | 1885 return DefineAsRegister(new LLoadExternalArrayPointer(input)); |
| 1885 } | 1886 } |
| 1886 | 1887 |
| 1887 | 1888 |
| 1888 LInstruction* LChunkBuilder::DoLoadKeyedFastElement( | 1889 LInstruction* LChunkBuilder::DoLoadKeyedFastElement( |
| 1889 HLoadKeyedFastElement* instr) { | 1890 HLoadKeyedFastElement* instr) { |
| 1890 ASSERT(instr->representation().IsTagged()); | 1891 ASSERT(instr->representation().IsTagged()); |
| 1891 ASSERT(instr->key()->representation().IsInteger32()); | 1892 ASSERT(instr->key()->representation().IsInteger32()); |
| 1892 LOperand* obj = UseRegisterAtStart(instr->object()); | 1893 LOperand* obj = UseRegisterAtStart(instr->object()); |
| 1893 LOperand* key = UseRegisterAtStart(instr->key()); | 1894 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); |
| 1894 LLoadKeyedFastElement* result = new LLoadKeyedFastElement(obj, key); | 1895 LLoadKeyedFastElement* result = new LLoadKeyedFastElement(obj, key); |
| 1895 return AssignEnvironment(DefineSameAsFirst(result)); | 1896 return AssignEnvironment(DefineAsRegister(result)); |
| 1896 } | 1897 } |
| 1897 | 1898 |
| 1898 | 1899 |
| 1899 LInstruction* LChunkBuilder::DoLoadKeyedFastDoubleElement( | 1900 LInstruction* LChunkBuilder::DoLoadKeyedFastDoubleElement( |
| 1900 HLoadKeyedFastDoubleElement* instr) { | 1901 HLoadKeyedFastDoubleElement* instr) { |
| 1901 ASSERT(instr->representation().IsDouble()); | 1902 ASSERT(instr->representation().IsDouble()); |
| 1902 ASSERT(instr->key()->representation().IsInteger32()); | 1903 ASSERT(instr->key()->representation().IsInteger32()); |
| 1903 LOperand* elements = UseRegisterAtStart(instr->elements()); | 1904 LOperand* elements = UseRegisterAtStart(instr->elements()); |
| 1904 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); | 1905 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); |
| 1905 LLoadKeyedFastDoubleElement* result = | 1906 LLoadKeyedFastDoubleElement* result = |
| (...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2265 LOperand* key = UseOrConstantAtStart(instr->key()); | 2266 LOperand* key = UseOrConstantAtStart(instr->key()); |
| 2266 LOperand* object = UseOrConstantAtStart(instr->object()); | 2267 LOperand* object = UseOrConstantAtStart(instr->object()); |
| 2267 LIn* result = new LIn(context, key, object); | 2268 LIn* result = new LIn(context, key, object); |
| 2268 return MarkAsCall(DefineFixed(result, eax), instr); | 2269 return MarkAsCall(DefineFixed(result, eax), instr); |
| 2269 } | 2270 } |
| 2270 | 2271 |
| 2271 | 2272 |
| 2272 } } // namespace v8::internal | 2273 } } // namespace v8::internal |
| 2273 | 2274 |
| 2274 #endif // V8_TARGET_ARCH_IA32 | 2275 #endif // V8_TARGET_ARCH_IA32 |
| OLD | NEW |