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/heap/spaces.h" | 5 #include "src/heap/spaces.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/full-codegen.h" | 9 #include "src/full-codegen/full-codegen.h" |
10 #include "src/heap/mark-compact.h" | 10 #include "src/heap/mark-compact.h" |
(...skipping 2509 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2520 large_list_.RepairFreeList(heap); | 2520 large_list_.RepairFreeList(heap); |
2521 huge_list_.RepairFreeList(heap); | 2521 huge_list_.RepairFreeList(heap); |
2522 } | 2522 } |
2523 | 2523 |
2524 | 2524 |
2525 #ifdef DEBUG | 2525 #ifdef DEBUG |
2526 intptr_t FreeListCategory::SumFreeList() { | 2526 intptr_t FreeListCategory::SumFreeList() { |
2527 intptr_t sum = 0; | 2527 intptr_t sum = 0; |
2528 FreeSpace* cur = top(); | 2528 FreeSpace* cur = top(); |
2529 while (cur != NULL) { | 2529 while (cur != NULL) { |
2530 DCHECK(cur->map() == cur->GetHeap()->raw_unchecked_free_space_map()); | 2530 DCHECK(cur->map() == cur->GetHeap()->root(Heap::kFreeSpaceMapRootIndex)); |
2531 sum += cur->nobarrier_size(); | 2531 sum += cur->nobarrier_size(); |
2532 cur = cur->next(); | 2532 cur = cur->next(); |
2533 } | 2533 } |
2534 return sum; | 2534 return sum; |
2535 } | 2535 } |
2536 | 2536 |
2537 | 2537 |
2538 static const int kVeryLongFreeList = 500; | 2538 static const int kVeryLongFreeList = 500; |
2539 | 2539 |
2540 | 2540 |
(...skipping 643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3184 object->ShortPrint(); | 3184 object->ShortPrint(); |
3185 PrintF("\n"); | 3185 PrintF("\n"); |
3186 } | 3186 } |
3187 printf(" --------------------------------------\n"); | 3187 printf(" --------------------------------------\n"); |
3188 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes()); | 3188 printf(" Marked: %x, LiveCount: %x\n", mark_size, LiveBytes()); |
3189 } | 3189 } |
3190 | 3190 |
3191 #endif // DEBUG | 3191 #endif // DEBUG |
3192 } // namespace internal | 3192 } // namespace internal |
3193 } // namespace v8 | 3193 } // namespace v8 |
OLD | NEW |