<html>
  <head>
    <meta content="text/html; charset=windows-1252"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <blockquote cite="mid:5581205A.6080108@gmail.com" type="cite">
      <blockquote cite="mid:558019DB.10902@1and1.ro" type="cite"> If you
        think of some other solution or have some advices for this,
        please comment.<br>
      </blockquote>
      This has to be done as add on to the memory manager via a module,
      something similar to what rpc command pkg.stats does, using some
      callbacks, to be sure it is not slowing down the core when this
      feature is not wanted/enabled.<br>
      <br>
      Perhaps an array with the shm and pkg counters, updated on
      callbacks for *malloc/*realloc/*free, still <b>relying on module
        name stored in the memory chunk structure at malloc time,</b> in
      order to decrease it properly at free time.<br>
    </blockquote>
    Are you referring to the #define _SRC_LOC_ <b>_SRC_MODULE_</b> ": "
    _SRC_FILENAME_ used at the moment when kamailio is compiled with
    MEMDBG=1? Besides this, I could find nothing related to a module
    name in any memory chunk structure.<br>
    <br>
    <blockquote cite="mid:5581205A.6080108@gmail.com" type="cite"> When
      coding the feature, it would be good to add it in between #ifdef
      ... #endif to be able to do performance measurments and disable it
      completely if has big impact. It has relevance for profiling and
      would be useful to have, just to be sure is not slowing down a
      lot.<br>
    </blockquote>
    I shall keep that in mind.<br>
    <br>
    <br>
    Thanks for your prompt response.<br>
    <br>
    Stefan<br>
  </body>
</html>