• Home
  • Raw
  • Download

Lines Matching refs:heap

34 u_mmDumpMemInfo(const struct mem_block *heap)  in u_mmDumpMemInfo()  argument
36 debug_printf("Memory heap %p:\n", (void *) heap); in u_mmDumpMemInfo()
37 if (heap == NULL) { in u_mmDumpMemInfo()
44 for (p = heap->next; p != heap; p = p->next) { in u_mmDumpMemInfo()
58 for (p = heap->next_free; p != heap; p = p->next_free) { in u_mmDumpMemInfo()
72 struct mem_block *heap, *block; in u_mmInit() local
77 heap = CALLOC_STRUCT(mem_block); in u_mmInit()
78 if (!heap) in u_mmInit()
83 FREE(heap); in u_mmInit()
87 heap->next = block; in u_mmInit()
88 heap->prev = block; in u_mmInit()
89 heap->next_free = block; in u_mmInit()
90 heap->prev_free = block; in u_mmInit()
92 block->heap = heap; in u_mmInit()
93 block->next = heap; in u_mmInit()
94 block->prev = heap; in u_mmInit()
95 block->next_free = heap; in u_mmInit()
96 block->prev_free = heap; in u_mmInit()
102 return heap; in u_mmInit()
121 newblock->heap = p->heap; in SliceBlock()
145 newblock->heap = p->heap; in SliceBlock()
177 u_mmAllocMem(struct mem_block *heap, int size, int align2, int startSearch) in u_mmAllocMem() argument
191 if (!heap || align2 < 0 || size <= 0) in u_mmAllocMem()
194 for (p = heap->next_free; p != heap; p = p->next_free) { in u_mmAllocMem()
206 if (p == heap) in u_mmAllocMem()
217 u_mmFindBlock(struct mem_block *heap, int start) in u_mmFindBlock() argument
221 for (p = heap->next; p != heap; p = p->next) { in u_mmFindBlock()
271 b->next_free = b->heap->next_free; in u_mmFreeMem()
272 b->prev_free = b->heap; in u_mmFreeMem()
277 if (b->prev != b->heap) in u_mmFreeMem()
285 u_mmDestroy(struct mem_block *heap) in u_mmDestroy() argument
289 if (!heap) in u_mmDestroy()
292 for (p = heap->next; p != heap; ) { in u_mmDestroy()
298 FREE(heap); in u_mmDestroy()