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 5762 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
5773 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation()); | 5773 ASSERT(!instr->hydrogen()->IsOldDataSpaceAllocation()); |
5774 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); | 5774 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); |
5775 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE); | 5775 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_POINTER_SPACE); |
5776 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) { | 5776 } else if (instr->hydrogen()->IsOldDataSpaceAllocation()) { |
5777 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); | 5777 ASSERT(!instr->hydrogen()->IsNewSpaceAllocation()); |
5778 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE); | 5778 flags = static_cast<AllocationFlags>(flags | PRETENURE_OLD_DATA_SPACE); |
5779 } | 5779 } |
5780 | 5780 |
5781 if (instr->size()->IsConstantOperand()) { | 5781 if (instr->size()->IsConstantOperand()) { |
5782 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); | 5782 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); |
5783 __ Allocate(size, result, temp, no_reg, deferred->entry(), flags); | 5783 if (size <= Page::kMaxRegularHeapObjectSize) { |
| 5784 __ Allocate(size, result, temp, no_reg, deferred->entry(), flags); |
| 5785 } else { |
| 5786 __ jmp(deferred->entry()); |
| 5787 } |
5784 } else { | 5788 } else { |
5785 Register size = ToRegister(instr->size()); | 5789 Register size = ToRegister(instr->size()); |
5786 __ Allocate(size, result, temp, no_reg, deferred->entry(), flags); | 5790 __ Allocate(size, result, temp, no_reg, deferred->entry(), flags); |
5787 } | 5791 } |
5788 | 5792 |
5789 __ bind(deferred->exit()); | 5793 __ bind(deferred->exit()); |
5790 | 5794 |
5791 if (instr->hydrogen()->MustPrefillWithFiller()) { | 5795 if (instr->hydrogen()->MustPrefillWithFiller()) { |
5792 if (instr->size()->IsConstantOperand()) { | 5796 if (instr->size()->IsConstantOperand()) { |
5793 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); | 5797 int32_t size = ToInteger32(LConstantOperand::cast(instr->size())); |
(...skipping 472 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6266 FixedArray::kHeaderSize - kPointerSize)); | 6270 FixedArray::kHeaderSize - kPointerSize)); |
6267 __ bind(&done); | 6271 __ bind(&done); |
6268 } | 6272 } |
6269 | 6273 |
6270 | 6274 |
6271 #undef __ | 6275 #undef __ |
6272 | 6276 |
6273 } } // namespace v8::internal | 6277 } } // namespace v8::internal |
6274 | 6278 |
6275 #endif // V8_TARGET_ARCH_IA32 | 6279 #endif // V8_TARGET_ARCH_IA32 |
OLD | NEW |