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 5202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5213 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation()); | 5213 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation()); |
5214 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); | 5214 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); |
5215 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE); | 5215 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE); |
5216 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) { | 5216 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) { |
5217 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); | 5217 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); |
5218 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE); | 5218 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE); |
5219 } | 5219 } |
5220 | 5220 |
5221 if (instr->size()->IsConstantOperand()) { | 5221 if (instr->size()->IsConstantOperand()) { |
5222 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); | 5222 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); |
5223 __ Allocate(size, result, scratch, scratch2, deferred->entry(), flags); | 5223 if (size <= Page::kMaxRegularHeapObjectSize) { |
| 5224 __ Allocate(size, result, scratch, scratch2, deferred->entry(), flags); |
| 5225 } else { |
| 5226 __ jmp(deferred->entry()); |
| 5227 } |
5224 } else { | 5228 } else { |
5225 Register size = ToRegister(instr->size()); | 5229 Register size = ToRegister(instr->size()); |
5226 __ Allocate(size, | 5230 __ Allocate(size, |
5227 result, | 5231 result, |
5228 scratch, | 5232 scratch, |
5229 scratch2, | 5233 scratch2, |
5230 deferred->entry(), | 5234 deferred->entry(), |
5231 flags); | 5235 flags); |
5232 } | 5236 } |
5233 | 5237 |
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5710 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); | 5714 __ sub(scratch, result, Operand::PointerOffsetFromSmiKey(index)); |
5711 __ ldr(result, FieldMemOperand(scratch, | 5715 __ ldr(result, FieldMemOperand(scratch, |
5712 FixedArray::kHeaderSize - kPointerSize)); | 5716 FixedArray::kHeaderSize - kPointerSize)); |
5713 __ bind(&done); | 5717 __ bind(&done); |
5714 } | 5718 } |
5715 | 5719 |
5716 | 5720 |
5717 #undef __ | 5721 #undef __ |
5718 | 5722 |
5719 } } // namespace v8::internal | 5723 } } // namespace v8::internal |
OLD | NEW |