| 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 881 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 892 } | 892 } |
| 893 | 893 |
| 894 void operator delete(void* p) | 894 void operator delete(void* p) |
| 895 { | 895 { |
| 896 ASSERT_NOT_REACHED(); | 896 ASSERT_NOT_REACHED(); |
| 897 } | 897 } |
| 898 | 898 |
| 899 protected: | 899 protected: |
| 900 GarbageCollected() | 900 GarbageCollected() |
| 901 { | 901 { |
| 902 ASSERT(ThreadStateFor<ThreadingTrait<T>::Affinity>::state()->contains(re
interpret_cast<Address>(this))); | |
| 903 } | 902 } |
| 904 }; | 903 }; |
| 905 | 904 |
| 906 // Base class for objects allocated in the Blink garbage-collected | 905 // Base class for objects allocated in the Blink garbage-collected |
| 907 // heap. | 906 // heap. |
| 908 // | 907 // |
| 909 // Defines a 'new' operator that allocates the memory in the | 908 // Defines a 'new' operator that allocates the memory in the |
| 910 // heap. 'delete' should not be called on objects that inherit from | 909 // heap. 'delete' should not be called on objects that inherit from |
| 911 // GarbageCollected. | 910 // GarbageCollected. |
| 912 // | 911 // |
| (...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1714 // to export. This forces it to export all the methods from ThreadHeap. | 1713 // to export. This forces it to export all the methods from ThreadHeap. |
| 1715 template<> void ThreadHeap<FinalizedHeapObjectHeader>::addPageToHeap(const GCInf
o*); | 1714 template<> void ThreadHeap<FinalizedHeapObjectHeader>::addPageToHeap(const GCInf
o*); |
| 1716 template<> void ThreadHeap<HeapObjectHeader>::addPageToHeap(const GCInfo*); | 1715 template<> void ThreadHeap<HeapObjectHeader>::addPageToHeap(const GCInfo*); |
| 1717 extern template class HEAP_EXPORT ThreadHeap<FinalizedHeapObjectHeader>; | 1716 extern template class HEAP_EXPORT ThreadHeap<FinalizedHeapObjectHeader>; |
| 1718 extern template class HEAP_EXPORT ThreadHeap<HeapObjectHeader>; | 1717 extern template class HEAP_EXPORT ThreadHeap<HeapObjectHeader>; |
| 1719 #endif | 1718 #endif |
| 1720 | 1719 |
| 1721 } | 1720 } |
| 1722 | 1721 |
| 1723 #endif // Heap_h | 1722 #endif // Heap_h |
| OLD | NEW |