| 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 2305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2316 return AssignPointerMap(DefineAsRegister(result)); | 2316 return AssignPointerMap(DefineAsRegister(result)); |
| 2317 } | 2317 } |
| 2318 | 2318 |
| 2319 | 2319 |
| 2320 LInstruction* LChunkBuilder::DoStringLength(HStringLength* instr) { | 2320 LInstruction* LChunkBuilder::DoStringLength(HStringLength* instr) { |
| 2321 LOperand* string = UseRegisterAtStart(instr->value()); | 2321 LOperand* string = UseRegisterAtStart(instr->value()); |
| 2322 return DefineAsRegister(new(zone()) LStringLength(string)); | 2322 return DefineAsRegister(new(zone()) LStringLength(string)); |
| 2323 } | 2323 } |
| 2324 | 2324 |
| 2325 | 2325 |
| 2326 LInstruction* LChunkBuilder::DoAllocateObject(HAllocateObject* instr) { | |
| 2327 info()->MarkAsDeferredCalling(); | |
| 2328 LAllocateObject* result = | |
| 2329 new(zone()) LAllocateObject(TempRegister(), TempRegister()); | |
| 2330 return AssignPointerMap(DefineAsRegister(result)); | |
| 2331 } | |
| 2332 | |
| 2333 | |
| 2334 LInstruction* LChunkBuilder::DoAllocate(HAllocate* instr) { | 2326 LInstruction* LChunkBuilder::DoAllocate(HAllocate* instr) { |
| 2335 info()->MarkAsDeferredCalling(); | 2327 info()->MarkAsDeferredCalling(); |
| 2336 LOperand* size = instr->size()->IsConstant() | 2328 LOperand* size = instr->size()->IsConstant() |
| 2337 ? UseConstant(instr->size()) | 2329 ? UseConstant(instr->size()) |
| 2338 : UseTempRegister(instr->size()); | 2330 : UseTempRegister(instr->size()); |
| 2339 LOperand* temp1 = TempRegister(); | 2331 LOperand* temp1 = TempRegister(); |
| 2340 LOperand* temp2 = TempRegister(); | 2332 LOperand* temp2 = TempRegister(); |
| 2341 LAllocate* result = new(zone()) LAllocate(size, temp1, temp2); | 2333 LAllocate* result = new(zone()) LAllocate(size, temp1, temp2); |
| 2342 return AssignPointerMap(DefineAsRegister(result)); | 2334 return AssignPointerMap(DefineAsRegister(result)); |
| 2343 } | 2335 } |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2546 | 2538 |
| 2547 | 2539 |
| 2548 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2540 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
| 2549 LOperand* object = UseRegister(instr->object()); | 2541 LOperand* object = UseRegister(instr->object()); |
| 2550 LOperand* index = UseRegister(instr->index()); | 2542 LOperand* index = UseRegister(instr->index()); |
| 2551 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); | 2543 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); |
| 2552 } | 2544 } |
| 2553 | 2545 |
| 2554 | 2546 |
| 2555 } } // namespace v8::internal | 2547 } } // namespace v8::internal |
| OLD | NEW |