Unsolved valgrind in qtcreator crashed
-
I tried to use valgrind tools to analyze my application. But it can't work. So I created a plain QWidgets project and it still can't work. The Qt version is 5.12.2, QtCreator 4.9 and I run it in vmware Linux. The log is as followed.
==5882== Callgrind, a call-graph generating cache profiler ==5882== Copyright (C) 2002-2017, and GNU GPL'd, by Josef Weidendorfer et al. ==5882== Using Valgrind-3.13.0 and LibVEX; rerun with -h for copyright info ==5882== Command: /home/guyan/QtProjects/build-memcheck-Desktop_Qt_5_12_2_GCC_64bit-Debug/memcheck ==5882== ==5882== For interactive control, run 'callgrind_control -h'. ==5882== ==5882== Process terminating with default action of signal 11 (SIGSEGV) ==5882== General Protection Fault ==5882== at 0x276C7162: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x276D4505: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x276D49B6: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x26F609F2: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x27472E50: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x2733B811: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x273368DA: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so) ==5882== by 0x25C4F476: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0) ==5882== by 0x25C22E1D: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0) ==5882== by 0x25C1E543: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0) ==5882== by 0x25C1EF2C: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0) ==5882== by 0x257C5841: QXcbGlxWindow::createVisual() (qxcbglxwindow.cpp:66) ==5882== ==5882== Events : Ir ==5882== Collected : 0 ==5882== ==5882== I refs: 0
It seems that the faults are caused by vmware player. So is there any way to solve it?
-
Hi
Did you install the wmware tools also ?
also this seems a bit odd
libGLX_mesa.so.0.0.0Does openGl generally work in your virtual machine ?
-
This post is deleted! -
@mrjj Yes, I have installed the vmware tools. And I tried a simple programme with OpenGL Library. It do works.
About libGLX_mesa.so.0.0.0, I really don't know what it is. So what can I do? -
@GuYan
Really not sure what else could be wrong then.
valgrind really dont use openGL so its a bit odd to start with.
Does valgrind work if you start it from commandline ?btw: what linux distro do you use ?
-
@mrjj The problem is the same when I run it from commandline. I wonder if the openGL is used by the Qt application.
And I use the Ubuntu 18.04LTS. -
@GuYan
well if you didnt use any openGL Qt features in your app, it should not.Give it a day. Maybe others have run into same issue.
-
@mrjj OK, thanks. If it still can't work. I may install the Linux directly.
-
@GuYan
ok. good plan.
even it should also work virtually. -
i encounter exatly the same problem under ubuntu 18.04lts under vmware trying to use valgrind on my qwidgets app
Command: /home/jk/QtProjetcs/FOSVoith/build-trunkQT-Desktop_Qt_5_12_3_GCC_64bit2-Profile/trunkQT
==7915==
==7915== For interactive control, run 'callgrind_control -h'.
==7915==
==7915== Process terminating with default action of signal 11 (SIGSEGV)
==7915== General Protection Fault
==7915== at 0x2EE64162: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2EE71505: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2EE719B6: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2E6FD9F2: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2EC0FE50: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2EAD8811: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2EAD38DA: ??? (in /usr/lib/x86_64-linux-gnu/dri/vmwgfx_dri.so)
==7915== by 0x2D3E8184: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0)
==7915== by 0x2D3BFE33: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0)
==7915== by 0x2D3BB543: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0)
==7915== by 0x2D3BBF2C: ??? (in /usr/lib/x86_64-linux-gnu/libGLX_mesa.so.0.0.0)
==7915== by 0x2CF7D841: QXcbGlxWindow::createVisual() (qxcbglxwindow.cpp:66)
==7915==
==7915== Events : Ir
==7915== Collected : 380114336
==7915==
==7915== I refs: 380,114,336did smd find a solution?
-
It works after doing this: export LIBGL_ALWAYS_SOFTWARE=1
Huge thanks to ppl in slack/qt for the solution -
@Zekses Thank you. Really helpful! ❤️ It saved me for my software verification student project!