Memory Analyzer in QtCreator, How to speed it up?



  • Hi guys,

    I've been using valgrind and callgrind for a while outside QtCreator and recently tried to use the include tools in QtCreator for valgrind (Memory Analyzer) but no matter the setting, the analyze process is EXTREMELY slow even with simple code can take up to 20 minutes on an I7 with 8gb of ram where a regular callgrind/kcachegrind combo on dolphin(is kinda complex compared to my simple code tests) for example takes 1 or 2 mins tops.

    My guess is QtCreator is forcefully invoking valgrind in the most ultra verbose super deep set of passes and offer no options to scale it back , i mean is cool for final releases or tracking deep memory allocation issues but when you just wanna an simple fast callgrind pass to check your loop or fast verify any ovbious leak locally in your code, this behaviour drives you insane

    So, is there any trick to speed this tools up or i should stay on konsole+valgrind until a future release?

    Tyvm for your time.

    Btw: my OS is ArchLinux all updates, x86_64, Qt-5.5 and QtCreater 3.5.0

    non native speaker here, so sorry for my english


  • Lifetime Qt Champion

    Hi,

    Did you already toyed with the Valgrind settings in Qt Creator's Preferences ?



  • @SGaist
    Hi, tyvm for you time.

    Actually i kinda fixed it, after debugging qtcreator while using valgrind i relized a signal was taking a year to return to main QCoreApplication exec() loop, hence valgrind was waiting for the process to stop. I feel stupid now(Tm) and im sure im doing something pretty idiotic with that signal to start with and my valgrind console parameters were to shallow to trigger it.

    I simply fixed the exit logic and valgrind now works as expected

    Sorry for the booboo


  • Lifetime Qt Champion

    No problem, that's an information that might be useful to someone else :)

    What was taking so long ?

    Since you have it working now, please update the thread title prepending [solved] so that other users may know a solution has been found :)


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.