OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 2749 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2760 splitOff->m_firstPage = 0; | 2760 splitOff->m_firstPage = 0; |
2761 // Merge free lists. | 2761 // Merge free lists. |
2762 for (size_t i = 0; i < blinkPageSizeLog2; i++) { | 2762 for (size_t i = 0; i < blinkPageSizeLog2; i++) { |
2763 if (!m_freeList.m_freeLists[i]) { | 2763 if (!m_freeList.m_freeLists[i]) { |
2764 m_freeList.m_freeLists[i] = splitOff->m_freeList.m_freeLists[i]; | 2764 m_freeList.m_freeLists[i] = splitOff->m_freeList.m_freeLists[i]; |
2765 } else if (splitOff->m_freeList.m_freeLists[i]) { | 2765 } else if (splitOff->m_freeList.m_freeLists[i]) { |
2766 m_freeList.m_lastFreeListEntries[i]->append(splitOff->m_freeList
.m_freeLists[i]); | 2766 m_freeList.m_lastFreeListEntries[i]->append(splitOff->m_freeList
.m_freeLists[i]); |
2767 m_freeList.m_lastFreeListEntries[i] = splitOff->m_freeList.m_las
tFreeListEntries[i]; | 2767 m_freeList.m_lastFreeListEntries[i] = splitOff->m_freeList.m_las
tFreeListEntries[i]; |
2768 } | 2768 } |
2769 } | 2769 } |
| 2770 if (m_freeList.m_biggestFreeListIndex < splitOff->m_freeList.m_biggestFr
eeListIndex) |
| 2771 m_freeList.m_biggestFreeListIndex = splitOff->m_freeList.m_biggestFr
eeListIndex; |
2770 } | 2772 } |
2771 } | 2773 } |
2772 | 2774 |
2773 void Heap::getHeapSpaceSize(uint64_t* objectSpaceSize, uint64_t* allocatedSpaceS
ize) | 2775 void Heap::getHeapSpaceSize(uint64_t* objectSpaceSize, uint64_t* allocatedSpaceS
ize) |
2774 { | 2776 { |
2775 *objectSpaceSize = 0; | 2777 *objectSpaceSize = 0; |
2776 *allocatedSpaceSize = 0; | 2778 *allocatedSpaceSize = 0; |
2777 ASSERT(ThreadState::isAnyThreadInGC()); | 2779 ASSERT(ThreadState::isAnyThreadInGC()); |
2778 ThreadState::AttachedThreadStateSet& threads = ThreadState::attachedThreads(
); | 2780 ThreadState::AttachedThreadStateSet& threads = ThreadState::attachedThreads(
); |
2779 typedef ThreadState::AttachedThreadStateSet::iterator ThreadStateIterator; | 2781 typedef ThreadState::AttachedThreadStateSet::iterator ThreadStateIterator; |
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2961 CallbackStack* Heap::s_weakCallbackStack; | 2963 CallbackStack* Heap::s_weakCallbackStack; |
2962 CallbackStack* Heap::s_ephemeronStack; | 2964 CallbackStack* Heap::s_ephemeronStack; |
2963 HeapDoesNotContainCache* Heap::s_heapDoesNotContainCache; | 2965 HeapDoesNotContainCache* Heap::s_heapDoesNotContainCache; |
2964 bool Heap::s_shutdownCalled = false; | 2966 bool Heap::s_shutdownCalled = false; |
2965 bool Heap::s_lastGCWasConservative = false; | 2967 bool Heap::s_lastGCWasConservative = false; |
2966 FreePagePool* Heap::s_freePagePool; | 2968 FreePagePool* Heap::s_freePagePool; |
2967 OrphanedPagePool* Heap::s_orphanedPagePool; | 2969 OrphanedPagePool* Heap::s_orphanedPagePool; |
2968 Heap::RegionTree* Heap::s_regionTree = 0; | 2970 Heap::RegionTree* Heap::s_regionTree = 0; |
2969 | 2971 |
2970 } // namespace blink | 2972 } // namespace blink |
OLD | NEW |