[meta-ti] Valgrind doesn't give stack trace

Ankur Tyagi ankur.tyagi85 at gmail.com
Wed Aug 12 21:25:54 PDT 2015


Hi,

I am using Valgrind coming from yocto on my AM335x-EVM kit.

But when I try to use valgrind, it doesn't give me stack trace. Following
is what I get :

root at am335x-evm:~# valgrind --tool=memcheck --leak-check=yes
--track-origins=yes --error-limit=no /home/root/test
Checking /home/root/test for memory leaks..
==1732== Memcheck, a memory error detector
==1732== Copyright (C) 2002-2013, and GNU GPL'd, by Julian Seward et al.
==1732== Using Valgrind-3.9.0 and LibVEX; rerun with -h for copyright info
==1732== Command: /home/root/test
==1732==
==1732== Invalid write of size 4
==1732==    at 0x8420: main (test.c:11)
==1732==  Address 0x4823060 is 0 bytes inside a block of size 4 free'd
==1732==    at 0x48109C4: free (in
/usr/lib/valgrind/vgpreload_memcheck-arm-linux.so)
==1732==
==1732==
==1732== HEAP SUMMARY:
==1732==     in use at exit: 4 bytes in 1 blocks
==1732==   total heap usage: 2 allocs, 1 frees, 8 bytes allocated
==1732==
==1732== 4 bytes in 1 blocks are definitely lost in loss record 1 of 1
==1732==    at 0x4811FE8: malloc (in
/usr/lib/valgrind/vgpreload_memcheck-arm-linux.so)
==1732==
==1732== LEAK SUMMARY:
==1732==    definitely lost: 4 bytes in 1 blocks
==1732==    indirectly lost: 0 bytes in 0 blocks
==1732==      possibly lost: 0 bytes in 0 blocks
==1732==    still reachable: 0 bytes in 0 blocks
==1732==         suppressed: 0 bytes in 0 blocks
==1732==
==1732== For counts of detected and suppressed errors, rerun with: -v
==1732== ERROR SUMMARY: 2 errors from 2 contexts (suppressed: 0 from 0)

​How to get stack trace ?

thanks
Ankur​
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/meta-ti/attachments/20150813/ba1b3476/attachment.html>


More information about the meta-ti mailing list