Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(56)

Side by Side Diff: Source/wtf/Vector.h

Issue 131803005: Add more oilpan collections support (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix OtherType for Windows compielr Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« Source/heap/Heap.h ('K') | « Source/wtf/HashTable.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2005, 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2005, 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 1125 matching lines...) Expand 10 before | Expand all | Expand 10 after
1136 // This is only called if the allocator is a HeapAllocator. It is used when 1136 // This is only called if the allocator is a HeapAllocator. It is used when
1137 // visiting during a tracing GC. 1137 // visiting during a tracing GC.
1138 template<typename T, size_t inlineCapacity, typename Allocator> 1138 template<typename T, size_t inlineCapacity, typename Allocator>
1139 void Vector<T, inlineCapacity, Allocator>::trace(typename Allocator::Visitor * visitor) 1139 void Vector<T, inlineCapacity, Allocator>::trace(typename Allocator::Visitor * visitor)
1140 { 1140 {
1141 ASSERT(Allocator::isGarbageCollected); 1141 ASSERT(Allocator::isGarbageCollected);
1142 const T* bufferBegin = buffer(); 1142 const T* bufferBegin = buffer();
1143 const T* bufferEnd = buffer() + size(); 1143 const T* bufferEnd = buffer() + size();
1144 if (VectorTraits<T>::needsTracing) { 1144 if (VectorTraits<T>::needsTracing) {
1145 for (const T* bufferEntry = bufferBegin; bufferEntry != bufferEnd; b ufferEntry++) 1145 for (const T* bufferEntry = bufferBegin; bufferEntry != bufferEnd; b ufferEntry++)
1146 Allocator::template visitWith<T, VectorTraits<T> >(visitor, *con st_cast<T*>(bufferEntry)); 1146 Allocator::template trace<T, VectorTraits<T> >(visitor, *const_c ast<T*>(bufferEntry));
1147 } 1147 }
1148 if (this->hasOutOfLineBuffer()) 1148 if (this->hasOutOfLineBuffer())
1149 Allocator::markUsingGCInfo(visitor, buffer()); 1149 Allocator::markNoTracing(visitor, buffer());
1150 } 1150 }
1151 1151
1152 } // namespace WTF 1152 } // namespace WTF
1153 1153
1154 using WTF::Vector; 1154 using WTF::Vector;
1155 1155
1156 #endif // WTF_Vector_h 1156 #endif // WTF_Vector_h
OLDNEW
« Source/heap/Heap.h ('K') | « Source/wtf/HashTable.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698