On 12/04/16 11:52, venkat konamki wrote: > I have compiled the above program using below commands > > arm-linux-gnueabi-gcc -o test-arm -g test.c > arm-linux-gnueabi-gcc -o test-arm-static -g test.c > > when i am running in my ARM architecture with valgrind
So that looks like you are cross compiling? But you are actually running valgrind on the target machine, not on the host where you do the compil? > 1) valgrind --tool=memcheck --leak-check=yes --show-reachable=yes ./test-arm > > valgrind: m_ume.c: can't open interpreter Well that means whatever ELF interpreter your program is declaring can't be opened by valgrind. Run "file ./test-arm" and see what interpreter it says it is using. > 2) /writable/valgrind/bin/valgrind --tool=memcheck --leak-check=yes > --show-reachable=yes ./test-arm-static > > ==8118== Memcheck, a memory error detector ==8118== Copyright (C) > 2002-2013, and GNU GPL'd, by Julian Seward et al. ==8118== Using > Valgrind-3.10.1 and LibVEX; rerun with -h for copyright info ==8118== > Command: ./test-arm-static ==8118== Enter number of elements: 1 Enter > elements of array: 1 Sum=1==8118== ==8118== HEAP SUMMARY: ==8118== in > use at exit: 0 bytes in 0 blocks ==8118== total heap usage: 0 allocs, 0 > frees, 0 bytes allocated ==8118== ==8118== All heap blocks were freed -- > no leaks are possible ==8118== ==8118== For counts of detected and > suppressed errors, rerun with: -v ==8118== ERROR SUMMARY: 0 errors from > 0 contexts (suppressed: 0 from 0) > > In both the cases i didn't get LEAK SUMMERY , but in my linux machine i > am able to get the valgrind report. can you suggest me the how to > resolve this on ? You won't be able to get a leak report for a statically linked program because valgrind won't be able to intercept calls to malloc and free. Tom -- Tom Hughes (t...@compton.nu) http://compton.nu/ ------------------------------------------------------------------------------ Find and fix application performance issues faster with Applications Manager Applications Manager provides deep performance insights into multiple tiers of your business applications. It resolves application problems quickly and reduces your MTTR. Get your free trial! https://ad.doubleclick.net/ddm/clk/302982198;130105516;z _______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users