我一直在关注这个教程以供参考:http://valgrind.org/docs/manual/ms-manual.html
当我使用valgrind --tool=massif --time-unit=B ./run.o命令分析我的应用程序时,它会完成,但不会生成任何输出文件。下面是使用上面提到的命令运行它时的日志。
https://www.dropbox.com/s/yae78rm9wmdbph1/ValGring_massif_Log?dl=0
请告诉我为什么它不能生成massif.out.xxxxx文件?
发布于 2015-06-15 15:50:20
如果你查看你的日志文件,你会发现Valgrind已经崩溃了,它解释了为什么,以及你应该做什么来修复它。
valgrind: m_mallocfree.c:304 (get_bszB_as_is): Assertion 'bszB_lo == bszB_hi' failed.
valgrind: Heap block lo/hi size mismatch: lo = 91849568, hi = 1425748016.
This is probably caused by your program erroneously writing past the
end of a heap block and corrupting heap metadata. If you fix any
invalid writes reported by Memcheck, this assertion failure will
probably go away. Please try that before reporting this as a bug.使用Valgrind的memcheck修复您的程序,然后重试。
https://stackoverflow.com/questions/30838182
复制相似问题