Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Further simplify the mmallocs, and improve its introspection abilities
authorMartin Quinson <martin.quinson@loria.fr>
Fri, 3 Feb 2012 14:17:14 +0000 (15:17 +0100)
committerMartin Quinson <martin.quinson@loria.fr>
Fri, 3 Feb 2012 14:17:14 +0000 (15:17 +0100)
commit04eb21634ce9041eaf00274eec16e20dbf5f70d0
treeaef031ac4990ac513600b7ea8d89cd3f9fbe182e
parent76936ddebd0a514a3259454d475b254ce40947b3
Further simplify the mmallocs, and improve its introspection abilities

- Ensure that the mmallocation code will never return NULL (but die
  verbosely), and simplify the using code accordingly.
- Stop using THROWF in there, because these functions probably need
  malloc to work, and that what broke when we want to issue a message.
  Use printf/abort instead.
- Introduce a SMALLEST_POSSIBLE_MALLOC. It already existed (and were
  defined to sizeof(struct list) to ensure that free fragments can be
  enlisted, but I need this to declare the block metadata
- Add a frag_size information within the bloc info structure. It may
  not perfectly be kept uptodate yet (in particular, by realloc)
src/xbt/mmalloc/mmalloc.c
src/xbt/mmalloc/mmorecore.c
src/xbt/mmalloc/mmprivate.h
src/xbt/mmalloc/mrealloc.c