| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #include "src/base/atomicops.h" | 7 #include "src/base/atomicops.h" |
| 8 #include "src/base/bits.h" | 8 #include "src/base/bits.h" |
| 9 #include "src/code-stubs.h" | 9 #include "src/code-stubs.h" |
| 10 #include "src/compilation-cache.h" | 10 #include "src/compilation-cache.h" |
| (...skipping 2765 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2776 Address src_addr = src->address(); | 2776 Address src_addr = src->address(); |
| 2777 DCHECK(heap()->AllowedToBeMigrated(src, dest)); | 2777 DCHECK(heap()->AllowedToBeMigrated(src, dest)); |
| 2778 DCHECK(dest != LO_SPACE && size <= Page::kMaxRegularHeapObjectSize); | 2778 DCHECK(dest != LO_SPACE && size <= Page::kMaxRegularHeapObjectSize); |
| 2779 if (dest == OLD_POINTER_SPACE) { | 2779 if (dest == OLD_POINTER_SPACE) { |
| 2780 Address src_slot = src_addr; | 2780 Address src_slot = src_addr; |
| 2781 Address dst_slot = dst_addr; | 2781 Address dst_slot = dst_addr; |
| 2782 DCHECK(IsAligned(size, kPointerSize)); | 2782 DCHECK(IsAligned(size, kPointerSize)); |
| 2783 | 2783 |
| 2784 bool may_contain_raw_values = src->MayContainRawValues(); | 2784 bool may_contain_raw_values = src->MayContainRawValues(); |
| 2785 #if V8_DOUBLE_FIELDS_UNBOXING | 2785 #if V8_DOUBLE_FIELDS_UNBOXING |
| 2786 InobjectPropertiesHelper helper(src->map()); | 2786 LayoutDescriptorHelper helper(src->map()); |
| 2787 bool has_only_tagged_fields = helper.all_fields_tagged(); | 2787 bool has_only_tagged_fields = helper.all_fields_tagged(); |
| 2788 #endif | 2788 #endif |
| 2789 for (int remaining = size / kPointerSize; remaining > 0; remaining--) { | 2789 for (int remaining = size / kPointerSize; remaining > 0; remaining--) { |
| 2790 Object* value = Memory::Object_at(src_slot); | 2790 Object* value = Memory::Object_at(src_slot); |
| 2791 | 2791 |
| 2792 Memory::Object_at(dst_slot) = value; | 2792 Memory::Object_at(dst_slot) = value; |
| 2793 | 2793 |
| 2794 #if V8_DOUBLE_FIELDS_UNBOXING | 2794 #if V8_DOUBLE_FIELDS_UNBOXING |
| 2795 if (!may_contain_raw_values && | 2795 if (!may_contain_raw_values && |
| 2796 (has_only_tagged_fields || | 2796 (has_only_tagged_fields || |
| (...skipping 1643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4440 SlotsBuffer* buffer = *buffer_address; | 4440 SlotsBuffer* buffer = *buffer_address; |
| 4441 while (buffer != NULL) { | 4441 while (buffer != NULL) { |
| 4442 SlotsBuffer* next_buffer = buffer->next(); | 4442 SlotsBuffer* next_buffer = buffer->next(); |
| 4443 DeallocateBuffer(buffer); | 4443 DeallocateBuffer(buffer); |
| 4444 buffer = next_buffer; | 4444 buffer = next_buffer; |
| 4445 } | 4445 } |
| 4446 *buffer_address = NULL; | 4446 *buffer_address = NULL; |
| 4447 } | 4447 } |
| 4448 } | 4448 } |
| 4449 } // namespace v8::internal | 4449 } // namespace v8::internal |
| OLD | NEW |