| OLD | NEW |
| 1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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/bits.h" | 7 #include "src/base/bits.h" |
| 8 #include "src/base/platform/platform.h" | 8 #include "src/base/platform/platform.h" |
| 9 #include "src/full-codegen.h" | 9 #include "src/full-codegen.h" |
| 10 #include "src/heap/mark-compact.h" | 10 #include "src/heap/mark-compact.h" |
| (...skipping 2521 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2532 | 2532 |
| 2533 | 2533 |
| 2534 void FreeList::RepairLists(Heap* heap) { | 2534 void FreeList::RepairLists(Heap* heap) { |
| 2535 small_list_.RepairFreeList(heap); | 2535 small_list_.RepairFreeList(heap); |
| 2536 medium_list_.RepairFreeList(heap); | 2536 medium_list_.RepairFreeList(heap); |
| 2537 large_list_.RepairFreeList(heap); | 2537 large_list_.RepairFreeList(heap); |
| 2538 huge_list_.RepairFreeList(heap); | 2538 huge_list_.RepairFreeList(heap); |
| 2539 } | 2539 } |
| 2540 | 2540 |
| 2541 | 2541 |
| 2542 #ifdef DEBUG | 2542 #if DCHECK_IS_ON |
| 2543 intptr_t FreeListCategory::SumFreeList() { | 2543 intptr_t FreeListCategory::SumFreeList() { |
| 2544 intptr_t sum = 0; | 2544 intptr_t sum = 0; |
| 2545 FreeListNode* cur = top(); | 2545 FreeListNode* cur = top(); |
| 2546 while (cur != NULL) { | 2546 while (cur != NULL) { |
| 2547 DCHECK(cur->map() == cur->GetHeap()->raw_unchecked_free_space_map()); | 2547 DCHECK(cur->map() == cur->GetHeap()->raw_unchecked_free_space_map()); |
| 2548 FreeSpace* cur_as_free_space = reinterpret_cast<FreeSpace*>(cur); | 2548 FreeSpace* cur_as_free_space = reinterpret_cast<FreeSpace*>(cur); |
| 2549 sum += cur_as_free_space->nobarrier_size(); | 2549 sum += cur_as_free_space->nobarrier_size(); |
| 2550 cur = cur->next(); | 2550 cur = cur->next(); |
| 2551 } | 2551 } |
| 2552 return sum; | 2552 return sum; |
| (...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3205 object->ShortPrint(); | 3205 object->ShortPrint(); |
| 3206 PrintF("\n"); | 3206 PrintF("\n"); |
| 3207 } | 3207 } |
| 3208 printf(" --------------------------------------\n"); | 3208 printf(" --------------------------------------\n"); |
| 3209 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes()); | 3209 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes()); |
| 3210 } | 3210 } |
| 3211 | 3211 |
| 3212 #endif // DEBUG | 3212 #endif // DEBUG |
| 3213 } | 3213 } |
| 3214 } // namespace v8::internal | 3214 } // namespace v8::internal |
| OLD | NEW |