Home | History | Annotate | Download | only in Support

Lines Matching refs:Bucket

185 /// GetNextPtr - In order to save space, each bucket is a
189 /// Nodes. If NextInBucketPtr is a bucket pointer, this method returns null:
192 // The low bit is set if this is the pointer back to the bucket.
203 assert((Ptr & 1) && "Not a bucket pointer");
207 /// GetBucketFor - Hash the specified node ID and return the hash bucket for
215 /// AllocateBuckets - Allocated initialized bucket memory.
218 // Set the very last bucket to be a non-null "pointer".
259 // Set all but the last bucket to null pointers.
262 // Set the very last bucket to be a non-null "pointer".
290 // Insert the node into the new bucket, after recomputing the hash.
308 void **Bucket = GetBucketFor(IDHash, Buckets, NumBuckets);
309 void *Probe = *Bucket;
322 // Didn't find the node, return null with the bucket as the InsertPos.
323 InsertPos = Bucket;
341 /// The insert position is actually a bucket pointer.
342 void **Bucket = static_cast<void**>(InsertPos);
344 void *Next = *Bucket;
346 // If this is the first insertion into this bucket, its next pointer will be
348 // that it is a pointer to the bucket.
350 Next = reinterpret_cast<void*>(reinterpret_cast<intptr_t>(Bucket)|1);
352 // Set the node's next pointer, and make the bucket point to the node.
354 *Bucket = N;
360 // Because each bucket is a circular list, we don't need to compute N's hash
368 // Remember what N originally pointed to, either a bucket or another node.
371 // Chase around the list until we find the node (or bucket) which points to N.
384 void **Bucket = GetBucketPtr(Ptr);
385 Ptr = *Bucket;
387 // If we found that the bucket points to N, update the bucket to point to
390 *Bucket = NodeNextPtr;
413 FoldingSetIteratorImpl::FoldingSetIteratorImpl(void **Bucket) {
414 // Skip to the first non-null non-self-cycle bucket.
415 while (*Bucket != reinterpret_cast<void*>(-1) &&
416 (!*Bucket || !GetNextPtr(*Bucket)))
417 ++Bucket;
419 NodePtr = static_cast<FoldingSetNode*>(*Bucket);
423 // If there is another link within this bucket, go to it.
429 // Otherwise, this is the last link in this bucket.
430 void **Bucket = GetBucketPtr(Probe);
432 // Skip to the next non-null non-self-cycle bucket.
434 ++Bucket;
435 } while (*Bucket != reinterpret_cast<void*>(-1) &&
436 (!*Bucket || !GetNextPtr(*Bucket)));
438 NodePtr = static_cast<FoldingSetNode*>(*Bucket);
445 FoldingSetBucketIteratorImpl::FoldingSetBucketIteratorImpl(void **Bucket) {
446 Ptr = (!*Bucket || !GetNextPtr(*Bucket)) ? (void*) Bucket : *Bucket;