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 714 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
725 private: | 725 private: |
726 // Returns a bucket number for inserting a FreeListEntry of a | 726 // Returns a bucket number for inserting a FreeListEntry of a |
727 // given size. All FreeListEntries in the given bucket, n, have | 727 // given size. All FreeListEntries in the given bucket, n, have |
728 // size >= 2^n. | 728 // size >= 2^n. |
729 static int bucketIndexForSize(size_t); | 729 static int bucketIndexForSize(size_t); |
730 | 730 |
731 int m_biggestFreeListIndex; | 731 int m_biggestFreeListIndex; |
732 | 732 |
733 // All FreeListEntries in the nth list have size >= 2^n. | 733 // All FreeListEntries in the nth list have size >= 2^n. |
734 FreeListEntry* m_freeLists[blinkPageSizeLog2]; | 734 FreeListEntry* m_freeLists[blinkPageSizeLog2]; |
735 FreeListEntry* m_lastFreeListEntries[blinkPageSizeLog2]; | |
736 | 735 |
737 friend class ThreadHeap<Header>; | 736 friend class ThreadHeap<Header>; |
738 }; | 737 }; |
739 | 738 |
740 // Thread heaps represent a part of the per-thread Blink heap. | 739 // Thread heaps represent a part of the per-thread Blink heap. |
741 // | 740 // |
742 // Each Blink thread has a number of thread heaps: one general heap | 741 // Each Blink thread has a number of thread heaps: one general heap |
743 // that contains any type of object and a number of heaps specialized | 742 // that contains any type of object and a number of heaps specialized |
744 // for specific object types (such as Node). | 743 // for specific object types (such as Node). |
745 // | 744 // |
(...skipping 1570 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2316 template<typename T, size_t inlineCapacity> | 2315 template<typename T, size_t inlineCapacity> |
2317 struct GCInfoTrait<HeapVector<T, inlineCapacity> > : public GCInfoTrait<Vector<T
, inlineCapacity, HeapAllocator> > { }; | 2316 struct GCInfoTrait<HeapVector<T, inlineCapacity> > : public GCInfoTrait<Vector<T
, inlineCapacity, HeapAllocator> > { }; |
2318 template<typename T, size_t inlineCapacity> | 2317 template<typename T, size_t inlineCapacity> |
2319 struct GCInfoTrait<HeapDeque<T, inlineCapacity> > : public GCInfoTrait<Deque<T,
inlineCapacity, HeapAllocator> > { }; | 2318 struct GCInfoTrait<HeapDeque<T, inlineCapacity> > : public GCInfoTrait<Deque<T,
inlineCapacity, HeapAllocator> > { }; |
2320 template<typename T, typename U, typename V> | 2319 template<typename T, typename U, typename V> |
2321 struct GCInfoTrait<HeapHashCountedSet<T, U, V> > : public GCInfoTrait<HashCounte
dSet<T, U, V, HeapAllocator> > { }; | 2320 struct GCInfoTrait<HeapHashCountedSet<T, U, V> > : public GCInfoTrait<HashCounte
dSet<T, U, V, HeapAllocator> > { }; |
2322 | 2321 |
2323 } // namespace blink | 2322 } // namespace blink |
2324 | 2323 |
2325 #endif // Heap_h | 2324 #endif // Heap_h |
OLD | NEW |