Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Setup the framework allowing to add backtraces to the malloc meta-data
authorMartin Quinson <martin.quinson@loria.fr>
Wed, 8 Feb 2012 10:47:29 +0000 (11:47 +0100)
committerMartin Quinson <martin.quinson@loria.fr>
Wed, 8 Feb 2012 10:47:29 +0000 (11:47 +0100)
- implement a malloc-clean backtrace() function
- make some room to store the backtraces. Only for big blocks for now,
  the memory consumption seem to be very high when doing so for
  fragments. Possible solutions include:
  - increasing the minimal fragment size to reduce the amount of
    possible fragment per block. It will waste some blocks for very
    small fragments, but it will save metadata that is paid for EVERY
    block, including full blocks, through the union in the metadata
  - Reduce the size of the saved backtraces. For now, we save up to 10
    calls, 5 to 3 levels may be enough if space is scarce.
- use that framework to save the backtraces in one malloc execution
  path. Other malloc execution paths, as well as realloc paths should
  now be changed to store the backtrace too.
- Implement a mmalloc_backtrace_display() function that displays the
  backtrace at which the block where malloc()ed. This is a bit crude
  for now, as we reuse the internals of exceptions that where not
  really done for that, but it works.


No differences found