Having problem with valgrind memcheck tool
-
Hey,
I use Valgrind memcheck to check memory issue in QT Creator when I run this tool a message appear on title bar it says:
"Memory Analyzer tool finished,40 issue where found."
Look at the following screen-shot :
https://ufile.io/1n1is
but there isn't any issue inside the box.
I don't know what does it mean and also does it dangerous for my app or not?I appreciate any help.
Thanks! -
Hey,
I use Valgrind memcheck to check memory issue in QT Creator when I run this tool a message appear on title bar it says:
"Memory Analyzer tool finished,40 issue where found."
Look at the following screen-shot :
https://ufile.io/1n1is
but there isn't any issue inside the box.
I don't know what does it mean and also does it dangerous for my app or not?I appreciate any help.
Thanks! -
hi @Alien
can you please tell us:
- which platform,
- QtCreator version and
- valgrind version
you are using?
-
Dear @aha_1980,
Platform : ubuntu 4.13.0-37-generic 16.0.4 LTS
QTCreator: 4.3.1 Based on QT 5.9.1
Valgrind Version : valgrind-3.11.0Dear @Alien,
from a quick look in the bug tracker, it seems QTCREATORBUG-19004 could be related.Edit: nope, that's with a newer valgrind version.
-
Dear @Alien,
from a quick look in the bug tracker, it seems QTCREATORBUG-19004 could be related.Edit: nope, that's with a newer valgrind version.
-
@aha_1980 said in Having problem with valgrind memcheck tool:
that's with a newer valgrind version.
So what should I do?
What does it mean?
Is it dangerous for my app I mean my app going to crash or not?
Could you please explain more? -
Dear @aha_1980,
I check the program with below command :
valgrind --leak-check=yes ./QML_TEST
and the summery is:
==15244== LEAK SUMMARY:
==15244== definitely lost: 1,108 bytes in 14 blocks
==15244== indirectly lost: 18,296 bytes in 133 blocks
==15244== possibly lost: 3,856 bytes in 33 blocks
==15244== still reachable: 1,393,828 bytes in 18,042 blocks
==15244== of which reachable via heuristic:
==15244== length64 : 5,336 bytes in 89 blocks
==15244== newarray : 2,160 bytes in 55 blocks
==15244== suppressed: 0 bytes in 0 blocks
==15244== Reachable blocks (those to which a pointer was found) are not shown.
==15244== To see them, rerun with: --leak-check=full --show-leak-kinds=all
==15244==
==15244== For counts of detected and suppressed errors, rerun with: -v
==15244== ERROR SUMMARY: 41 errors from 41 contexts (suppressed: 0 from 0) -
Dear @aha_1980,
I check the program with below command :
valgrind --leak-check=yes ./QML_TEST
and the summery is:
==15244== LEAK SUMMARY:
==15244== definitely lost: 1,108 bytes in 14 blocks
==15244== indirectly lost: 18,296 bytes in 133 blocks
==15244== possibly lost: 3,856 bytes in 33 blocks
==15244== still reachable: 1,393,828 bytes in 18,042 blocks
==15244== of which reachable via heuristic:
==15244== length64 : 5,336 bytes in 89 blocks
==15244== newarray : 2,160 bytes in 55 blocks
==15244== suppressed: 0 bytes in 0 blocks
==15244== Reachable blocks (those to which a pointer was found) are not shown.
==15244== To see them, rerun with: --leak-check=full --show-leak-kinds=all
==15244==
==15244== For counts of detected and suppressed errors, rerun with: -v
==15244== ERROR SUMMARY: 41 errors from 41 contexts (suppressed: 0 from 0)Dear @Alien ,
so it seems memcheck does detect some problems, you will have to check deeper if these are *real * problems or false positives.
and it seems Creator has problems parsing the memcheck output, probably in relation to the bug i mentioned before.
I'm no expert in that regard, so I won't help you much further.
-
Dear @Alien ,
so it seems memcheck does detect some problems, you will have to check deeper if these are *real * problems or false positives.
and it seems Creator has problems parsing the memcheck output, probably in relation to the bug i mentioned before.
I'm no expert in that regard, so I won't help you much further.
@aha_1980 thank you for your reply by the way when I add some wrong code in order to find does valgrind in qt creator work properly or not I found that valgrind in QT Creator can detect them nicely in the memcheck box but It also show the statement of N issue where found.
I don't know whats wrong with it
-
@aha_1980 thank you for your reply by the way when I add some wrong code in order to find does valgrind in qt creator work properly or not I found that valgrind in QT Creator can detect them nicely in the memcheck box but It also show the statement of N issue where found.
I don't know whats wrong with it
@Alien I did notice mine also saying Memory Analyzer Too finished. 98 issues were found. And there is nothing showing in the Memory Issues window.
But if you click on the filter (the funnel/t shape button), and select show "External Errors" - which is the only one defaulted to off, you'll see you have errors but they are in external libraries (ie
I have errors in arm-linux-gnueabihf/ld-2.28.so). You can find these by opening the error and drilling down into it.