Lines Matching refs:Chunk
3287 " Minimum overhead per allocated chunk: 4 or 8 bytes\n" +
3288 " Each malloced chunk has a hidden word of overhead holding size\n" +
3294 " When a chunk is freed, 12 (for 4byte ptrs) or 20 (for 8 byte\n" +
3314 " represent chunk sizes. `Possibly signed' is due to the fact\n" +
3575 " attempt to check every non-mmapped allocated and free chunk in the\n" +
3590 " The unsigned integer type used for comparing any two chunk sizes.\n" +
3610 " of chunk sizes.\n" +
3676 " TRIM_FASTBINS controls whether free() of a very small chunk can\n" +
4109 " Returns a pointer to a newly allocated chunk of at least n bytes, or null\n" +
4113 " If n is zero, malloc returns a minumum-sized chunk. (The minimum\n" +
4129 " Releases the chunk of memory pointed to by p, that had been previously\n" +
4157 " Returns a pointer to a chunk of size n that contains the same data\n" +
4158 " as does chunk p up to the minimum of (n, p's size) bytes, or null\n" +
4173 " zero (re)allocates a minimum-sized chunk.\n" +
4179 " The old unix realloc convention of allowing the last-free'd chunk\n" +
4190 " Returns a pointer to a newly allocated chunk of n bytes, aligned\n" +
4297 " is null, it returns a chunk representing an array with zero elements\n" +
4353 " null, it returns a chunk representing an array with zero elements\n" +
4459 " an allocated chunk, which may be more than you requested (although\n" +
4587 " freeing a chunk with size less than or equal to MXFAST. Trimming is\n" +
5110 " ----------------------- Chunk representations -----------------------\n" +
5122 " INTERNAL_SIZE_T prev_size; /* Size of previous chunk (if free). */\n" +
5141 " in the front of each chunk and at the end. This makes\n" +
5146 " An allocated chunk looks like this:\n" +
5149 " chunk-> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+\n" +
5150 " | Size of previous chunk, if allocated | |\n" +
5152 " | Size of chunk, in bytes |P|\n" +
5159 " | Size of chunk |\n" +
5163 " Where \"chunk\" is the front of the chunk for the purpose of most of\n" +
5165 " user. \"Nextchunk\" is the beginning of the next contiguous chunk.\n" +
5173 " chunk-> +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+\n" +
5174 " | Size of previous chunk |\n" +
5176 " `head:' | Size of chunk, in bytes |P|\n" +
5178 " | Forward pointer to next chunk in list |\n" +
5180 " | Back pointer to previous chunk in list |\n" +
5186 " `foot:' | Size of chunk, in bytes |\n" +
5190 " chunk size (which is always a multiple of two words), is an in-use\n" +
5191 " bit for the *previous* chunk. If that bit is *clear*, then the\n" +
5192 " word before the current chunk size contains the previous chunk\n" +
5193 " size, and can be used to find the front of the previous chunk.\n" +
5194 " The very first chunk allocated always has this bit set,\n" +
5196 " prev_inuse is set for any given chunk, then you CANNOT determine\n" +
5197 " the size of the previous chunk, and might even get a memory\n" +
5200 " Note that the `foot' of the current chunk is actually represented\n" +
5201 " as the prev_size of the NEXT chunk. This makes it easier to\n" +
5207 " 1. The special chunk `top' doesn't bother using the\n" +
5208 " trailing size field since there is no next contiguous chunk\n" +
5228 "/* The smallest possible chunk */\n" +
5231 "/* The smallest size we can malloc is an aligned minimal chunk */\n" +
5268 " --------------- Physical chunk operations ---------------\n" +
5272 "/* size field is or'ed with PREV_INUSE when previous adjacent chunk in use */\n" +
5275 "/* extract inuse bit of previous chunk */\n" +
5279 "/* size field is or'ed with IS_MMAPPED if the chunk was obtained with mmap() */\n" +
5282 "/* check for mmap()'ed chunk */\n" +
5305 "/* Treat space at ptr + offset as a chunk */\n" +
5312 "/* set/clear chunk as being inuse without otherwise disturbing */\n" +
5337 "/* Set size at footer (only when chunk is not in use) */\n" +
5366 " that no consolidated chunk physically borders another one, so each\n" +
5367 " chunk in a list is known to be preceeded and followed by either\n" +
5371 " approximately least recently used chunk. Ordering isn't needed\n" +
5381 " to give each chunk an equal opportunity to be consolidated with\n" +
5404 "/* Take a chunk off a bin list */\n" +
5485 " FIRST_SORTED_BIN_SIZE is the chunk size corresponding to the\n" +
5491 " Doing this means that malloc may choose a chunk that is\n" +
5509 " All remainders from chunk splits, as well as all returned chunks,\n" +
5523 " The top-most available chunk (i.e., the one bordering the end of\n" +
5525 " any bin, is used only if no other chunk is available, and is\n" +
5532 " initial_top treat the bin as a legal but unusable chunk during the\n" +
5592 " FASTBIN_CONSOLIDATION_THRESHOLD is the size of a chunk in free()\n" +
5612 " freed chunks at all. It is set true when entering a chunk into any\n" +
5624 " some fastbin chunks. It is set true on entering a chunk into any\n" +
5671 " /* The maximum chunk size to be eligible for fastbin */\n" +
5677 " /* Base of the topmost chunk -- not otherwise kept in a bin */\n" +
5863 " /* chunk is page-aligned */\n" +
5891 " /* Chunk must claim to be free ... */\n" +
5939 " if an inuse chunk borders them and debug is on, it's worth doing them.\n" +
5975 " /* chunk is less than MINSIZE more than request */\n" +
5995 " always true of any allocated chunk; i.e., that each allocated\n" +
5996 " chunk borders either a previously allocated and still in-use\n" +
5997 " chunk, or the base of its memory arena. This is ensured\n" +
5999 " chunk. This does not necessarily hold however for chunks\n" +
6015 " display chunk addresses, sizes, bins, and other instrumentation.\n" +
6060 " /* each chunk claims to be inuse */\n" +
6063 " /* chunk belongs in this bin */\n" +
6090 " /* each chunk claims to be free */\n" +
6095 " /* chunk belongs in bin */\n" +
6105 " /* chunk is followed by a legal chain of inuse chunks */\n" +
6114 " /* top chunk is OK */\n" +
6164 " mchunkptr p; /* the allocated/returned chunk */\n" +
6204 " is no following chunk whose prev_size field could be used.\n" +
6217 " in the prev_size field of the chunk. This allows us to adjust\n" +
6415 " /* Guarantee alignment of first new chunk made from this space */\n" +
6424 " prev_inuse of av->top (and any chunk created from its start)\n" +
6661 " mchunkptr victim; /* inspected/selected chunk */\n" +
6751 " it is exact fit, or, if this a small request, the chunk is remainder from\n" +
6763 " only chunk in unsorted bin. This helps promote locality for\n" +
6766 " no exact fit for a small chunk.\n" +
6801 " /* place chunk in bin */\n" +
6880 " Search for a chunk by scanning bins, starting with next largest\n" +
6882 " (with ties going to approximately the least recently used) chunk\n" +
6927 " /* We know the first chunk in this bin is big enough to use. */\n" +
6965 " If large enough, split off the chunk bordering the end of memory\n" +
6968 " less well fitting) than any other available chunk since it can\n" +
7012 " mchunkptr p; /* chunk corresponding to mem */\n" +
7015 " mchunkptr nextchunk; /* next contiguous chunk */\n" +
7018 " INTERNAL_SIZE_T prevsize; /* size of previous contiguous chunk */\n" +
7030 " If eligible, place chunk on a fastbin so it can be found\n" +
7081 " Place the chunk in unsorted chunk list. Chunks are\n" +
7100 " If the chunk borders the current high end of memory,\n" +
7137 " If the chunk was allocated via mmap, release via munmap()\n" +
7181 " mchunkptr p; /* current chunk being consolidated */\n" +
7182 " mchunkptr nextp; /* next chunk to consolidate */\n" +
7184 " mchunkptr first_unsorted; /* chunk to link to */\n" +
7206 " Remove each chunk from fast bin and consolidate it, placing it\n" +
7286 " mchunkptr oldp; /* chunk corresponding to oldmem */\n" +
7289 " mchunkptr newp; /* chunk to return */\n" +
7293 " mchunkptr next; /* next contiguous chunk after oldp */\n" +
7346 " /* Try to expand forward into next chunk; split off remainder below */\n" +
7365 " Avoid copy if newp is next chunk after oldp.\n" +
7412 " /* If possible, free extra space in old or extended chunk */\n" +
7512 " mchunkptr p; /* corresponding chunk */\n" +
7514 " mchunkptr newp; /* chunk to return */\n" +
7525 " /* Otherwise, ensure that it is at least a minimum chunk size */\n" +
7539 " Strategy: find a spot within that chunk that meets the alignment\n" +
7555 " Find an aligned spot inside chunk. Since we need to give back\n" +
7556 " leading space in a chunk of at least MINSIZE, if the first\n" +
7742 " mchunkptr p; /* corresponding chunk */\n" +
7745 " mchunkptr array_chunk; /* chunk for malloced ptr array */\n" +
7761 " /* if empty req, must still return chunk representing empty array */\n" +
7785 " Allocate the aggregate chunk.\n" +
7805 " /* If not provided, allocate the pointer array as final part of chunk */\n" +
7833 " /* final element must have exactly exhausted chunk */\n" +