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