MCPcopy Create free account
hub / github.com/devosoft/avida / InsertRange

Method InsertRange

libs/tcmalloc-1.4/src/central_freelist.cc:201–214  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

199}
200
201void CentralFreeList::InsertRange(void *start, void *end, int N) {
202 SpinLockHolder h(&lock_);
203 if (N == Static::sizemap()->num_objects_to_move(size_class_) &&
204 MakeCacheSpace()) {
205 int slot = used_slots_++;
206 ASSERT(slot >=0);
207 ASSERT(slot < kNumTransferEntries);
208 TCEntry *entry = &tc_slots_[slot];
209 entry->head = start;
210 entry->tail = end;
211 return;
212 }
213 ReleaseListToSpans(start);
214}
215
216int CentralFreeList::RemoveRange(void **start, void **end, int N) {
217 ASSERT(N > 0);

Callers 2

ReleaseToCentralCacheMethod · 0.80
do_free_with_callbackFunction · 0.80

Calls 1

num_objects_to_moveMethod · 0.80

Tested by

no test coverage detected