[ndnSIM] Any experience on profiling or dealing with memory leakage issues

Xinyu Ma bitmxy at gmail.com
Thu Apr 12 10:14:50 PDT 2018


Hello, Carl.

Yes, I have some ideas.
I just overloaded the operator new and delete to record every memory
allocation and releasing.
I assumed the memory allocation and releasing will keep a balance after a
start-up time. So I just record all memory blocks allocated in a time
interval [a,a + t1] but not released in [a, a + t1 + t2], where t2 is long
enough that no cache entries or PIT entries created in [a, a+t1] will
remain. The recored blocks are thought to be "leaked", though there may be
references point to it.
But it's a bit hard to find who allocated a specified memory block. I used
to do it manually and it took me a lot of time. Recently I found I could
use backtrace function to get the call stack and use scripts to convert
address to line number. I'm writing it now. If you have interests in this
trick, I can publish it to GitHub when it's finished before long.

Xinyu Ma.

2018-04-12 21:21 GMT+09:00 Carl Zu <carlzu8 at gmail.com>:

> Dear all,
>
> Does anybody have an experience of using a profiler with ndnSIM? I am
> having a memory leakage issue, which leads to having different errors per
> run. But apparently, the problem stems from a memory leakage issue.
>
> Any guidance appreciated.
>
> Thanks and regards,
> C
>
> _______________________________________________
> ndnSIM mailing list
> ndnSIM at lists.cs.ucla.edu
> http://www.lists.cs.ucla.edu/mailman/listinfo/ndnsim
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.lists.cs.ucla.edu/pipermail/ndnsim/attachments/20180413/cc76211a/attachment.html>


More information about the ndnSIM mailing list