Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

segmentation fault with wf 2.0 and Filtered "(GLSL)" #6364

Closed
mixxxbot opened this issue Aug 22, 2022 · 17 comments
Closed

segmentation fault with wf 2.0 and Filtered "(GLSL)" #6364

mixxxbot opened this issue Aug 22, 2022 · 17 comments

Comments

@mixxxbot
Copy link
Collaborator

Reported by: daschuer
Date: 2012-04-13T22:29:40Z
Status: Fix Released
Importance: Critical
Launchpad Issue: lp981218
Attachments: glsl_crash.patch


I had a segmentation fault on my Netbook:

  • Atom CPU N270 @ 1.6GHz
  • 2 GiB RAM
  • Ubuntu Lucid
  • QT Version Qt version 4.6.2.
  • Intel 945GME

It happens just after switching to "Filtered (GLSL)" Mode.

Unfortunately I have not saved the console output and I am not able to reproduce the issue.

There was something like
"cannot set background ..
.. Command ... is not supported .. "

Maybe this depends on Bug #⁠981210

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-05-08T21:53:06Z


This should be related to non deploed shader but it should not crash even if files are missing.
I'll add some run-time tests.

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-05-21T11:15:12Z


I have crated a duplicate Bug #⁠1001909 accidentally.
It Includes a backtrack.

Now the crash is reproducible.
it was tested wit lp:mixxx #⁠3171

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-05-22T23:12:51Z


For some reason you driver seems to fail creating a frame buffer with a non power-of-two width.
I consider this bug fix since it shoul dnot crash any more but you won't be able to use GLSL version.
When GLSL version will become more important we'll try to use power-fpf-two size everywhere to try to accomodate every opengl/driver version.

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-05-24T20:27:52Z


The fix is not committed to the lp:mixxx, so the state is still "In Progress".
How can I test it?

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-05-25T11:49:17Z


My bad I was quite sure I pushed it in trunk ...

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-05-30T18:59:36Z


What about now ? Can you give it a shot ? trunk >= 3219

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-05-31T17:50:01Z


Hi Thomas,

I am sorry, segfault is still there, tested with lp:mixxx #⁠3222

log:

Warning [Main]: WaveformRenderBackground::generatePixmap - no background file 
WARNING: Application calling GLX 1.3 function "glXCreatePixmap" when GLX 1.3 is not supported!  This is an application bug!
Warning [Main]: WaveformRenderBackground::generatePixmap - no background file 
Debug [Main]: guess the size of the window decoration 
WARNING: Application calling GLX 1.3 function "glXDestroyPixmap" when GLX 1.3 is not supported!  This is an application bug!
Debug [Main]: GLWaveformRendererSignalShader::loadShaders 
Warning [Main]: QGLShader::compile: "Warning: GL_EXT_gpu_shader4: enabled extension is not supported.
Error: 2005: ')' expected but '???' found.
" 
Debug [Main]: QGLFramebufferObject: Framebuffer incomplete attachment.
Warning [Main]: GLSLWaveformRendererSignal::createFrameBuffer - frame buffer not valid 
Debug [Main]: GLSLWaveformRendererSignal::loadTexture - m_textureId 4 error 1281 
Debug [Main]: GLWaveformRendererSignalShader::loadShaders 
Warning [Main]: QGLShader::compile: "Warning: GL_EXT_gpu_shader4: enabled extension is not supported.
Error: 2005: ')' expected but '???' found.
" 
Debug [Main]: QGLFramebufferObject: Framebuffer incomplete attachment.
Warning [Main]: GLSLWaveformRendererSignal::createFrameBuffer - frame buffer not valid 
Debug [Main]: GLSLWaveformRendererSignal::loadTexture - m_textureId 4 error 1281 
i915_program_error: Unsupported opcode: IF
Warning [Main]: WaveformRenderBackground::generatePixmap - no background file 

Program received signal SIGSEGV, Segmentation fault.
0x00000000 in ?? ()

backtrace:

Thread 1 (Thread 0xb7fd8720 (LWP 1499)):
#0  0x00000000 in ?? ()
mixxxdj/mixxx#4910  0x04825a3b in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4911  0x048baa73 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4912  0x047f5cc3 in _mesa_execute_program () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4913  0x048ba724 in _swrast_exec_fragment_program () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4914  0x0481640f in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4915  0x04817ba0 in _swrast_write_rgba_span () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4916  0x048305d2 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4917  0x04809e5f in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4918  0x0480905d in _swrast_Triangle () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4919 0x0483cdaf in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4920 0x047d5027 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4921 0x047d69c9 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4922 0x047ca6b3 in _tnl_run_pipeline () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4923 0x047219fd in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4924 0x047cb406 in _tnl_draw_prims () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4925 0x047cb869 in _tnl_vbo_draw_prims () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4926 0x047c2f31 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4927 0x047b9c17 in ?? () from /usr/lib/dri/i915_dri.so
mixxxdj/mixxx#4928 0x014b9c37 in ?? () from /usr/share/qt4/lib/libQtOpenGL.so.4
mixxxdj/mixxx#4929 0x014c5ff1 in ?? () from /usr/share/qt4/lib/libQtOpenGL.so.4
mixxxdj/mixxx#4930 0x008f2f68 in QPaintEngineEx::drawPixmap(QPointF const&, QPixmap const&) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4931 0x00908788 in QPainter::drawPixmap(QPointF const&, QPixmap const&) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4932 0x0834b231 in QPainter::drawPixmap (this=0x9305ca0, painter=0xbfffe21c) at /usr/include/qt4/QtGui/qpainter.h:811
mixxxdj/mixxx#4933 WaveformRenderBackground::draw (this=0x9305ca0, painter=0xbfffe21c)
    at src/waveform/renderers/waveformrenderbackground.cpp:34
mixxxdj/mixxx#4934 0x08348be0 in WaveformWidgetRenderer::draw (this=0x8f19a8c, painter=0xbfffe21c, event=0xbfffe7d4)
    at src/waveform/renderers/waveformwidgetrenderer.cpp:170
mixxxdj/mixxx#4935 0x083671ab in GLSLWaveformWidget::paintEvent (this=0x8f19a78, event=0xbfffe7d4)
    at src/waveform/widgets/glslwaveformwidget.cpp:47
mixxxdj/mixxx#4936 0x007ee6b6 in QWidget::event(QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4937 0x0149ddf9 in QGLWidget::event(QEvent*) () from /usr/share/qt4/lib/libQtOpenGL.so.4
mixxxdj/mixxx#4938 0x007904dc in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4939 0x007970f9 in QApplication::notify(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4940 0x0123fa3b in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4941 0x007f79d6 in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4942 0x009cc926 in QWidgetPrivate::repaint_sys(QRegion const&) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4943 0x007e7b3e in QWidgetPrivate::syncBackingStore() () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4944 0x007eee76 in QWidget::event(QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4945 0x0149ddf9 in QGLWidget::event(QEvent*) () from /usr/share/qt4/lib/libQtOpenGL.so.4
mixxxdj/mixxx#4946 0x007904dc in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4947 0x007970f9 in QApplication::notify(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4948 0x0123fa3b in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4949 0x01242473 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) ()
   from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4950 0x012425dd in QCoreApplication::sendPostedEvents(QObject*, int) () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4951 0x0126badf in ?? () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4952 0x031b6245 in g_main_context_dispatch () from /lib/libglib-2.0.so.0
mixxxdj/mixxx#4953 0x031ba068 in ?? () from /lib/libglib-2.0.so.0
mixxxdj/mixxx#4954 0x031ba248 in g_main_context_iteration () from /lib/libglib-2.0.so.0
mixxxdj/mixxx#4955 0x0126b5d5 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) ()
   from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4956 0x00850135 in ?? () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4957 0x0123e059 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4958 0x0123e4aa in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4959 0x0124269f in QCoreApplication::exec() () from /usr/share/qt4/lib/libQtCore.so.4
mixxxdj/mixxx#4960 0x00790577 in QApplication::exec() () from /usr/share/qt4/lib/libQtGui.so.4
mixxxdj/mixxx#4961 0x0819f4c5 in main (argc=141334196, argv=0xbffff464) at src/main.cpp:306

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-06-01T16:05:30Z


Ok I'll add some debug output.
Can you confirm that GL version works ?
Cause they share background renderer ...

I think this should be related to another bug I see time to time where it does not crash but signal frame buffer end to be displayed in GLSL background. Or when I load track in deck 1 the signal FBO of deck to is changed ... I tried to track this down a couple of time with no success :(

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-06-01T16:06:59Z


BTW thanks for testing it, and giving feedback ... it's appreciated.

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-06-01T21:12:00Z


GL and Qt GL are working, except bug Bug #⁠981210.
GL reaches around 60 fps Qt GL only 12.
The "filtered waveforms" are not to distinguish in pure GL an outline skin. I thing we should user slightly more colour differences.

@mixxxbot
Copy link
Collaborator Author

Commented by: vrince
Date: 2012-06-03T00:37:04Z


Regarding colours, please change skins cause making the fallback colour works "well" with all type of colour is tricky.

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-07-26T10:29:37Z


Issue is solved in lp:~daschuer/mixxx/daschuers_trunk.
Now I am working on a clean patch for 1.11

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-07-28T19:14:07Z
Attachments: glsl_crash.patch


Attached you find a patch that solves the problem.
It introduces a bool init() function. If init of the selected waveform widget fails, the "empty" Waveform is selected instead.
Additional I have made the type information functions for filling the waveform selection combo box static, to avoid instantiate all the waveform widgets.
I have also notice that some background bitmaps are two pixel to small. The according warning massage is now more detailed.

@mixxxbot
Copy link
Collaborator Author

Commented by: rryan
Date: 2012-07-31T17:53:18Z


Patch looks good to me -- thanks Daniel!

@mixxxbot
Copy link
Collaborator Author

Commented by: rryan
Date: 2012-07-31T17:54:50Z


As a note, I don't know if the current shader linking will ever succeed on a release version of Mixxx since we refer to the shaders located in the ./src/ directory which will never be present if a user is not building from source. Those should be updated to use qt resource paths at some point and be bundled in res/.

@mixxxbot
Copy link
Collaborator Author

Commented by: daschuer
Date: 2012-09-19T21:05:51Z


Committed to lp:mixxx/1.11 #⁠3399

@mixxxbot
Copy link
Collaborator Author

Issue closed with status Fix Released.

@mixxxbot mixxxbot transferred this issue from another repository Aug 24, 2022
@mixxxbot mixxxbot added this to the 1.11.0 milestone Aug 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant