Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-87770

Occasional crash (segfault) on application start

    XMLWordPrintable

Details

    • Bug
    • Resolution: Duplicate
    • Not Evaluated
    • None
    • 5.15.1
    • WebEngine
    • None
    • macOS

    Description

      We're seeing the following crash intermittently in our application with Qt 5.15.1:

      (lldb) bt
      * thread #25, name = 'Chrome_InProcGpuThread', stop reason = EXC_BAD_ACCESS (code=1, address=0x60)
        * frame #0: 0x00000001025ebeae QtWebEngineCore`QtWebEngineCore::DisplayGLOutputSurface::swapBuffersOnGpuThread(this=0x000000012e42be70, id=28, fence=gl::GLFence @ 0x0000000112824d40) at display_gl_output_surface.cpp:212:35 [opt]
          frame #1: 0x00000001025ec168 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::RunOnce(base::internal::BindStateBase*, unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) [inlined] void base::internal::FunctorTraits<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), void>::Invoke<void (method=<unavailable>, args=<unavailable>)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), QtWebEngineCore::DisplayGLOutputSurface*, unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> > >(void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), QtWebEngineCore::DisplayGLOutputSurface*&&, unsigned int&&, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) at bind_internal.h:498:12 [opt]
          frame #2: 0x00000001025ec13b QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::RunOnce(base::internal::BindStateBase*, unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) [inlined] void base::internal::InvokeHelper<false, void>::MakeItSo<void (functor=<unavailable>, args=<unavailable>)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), QtWebEngineCore::DisplayGLOutputSurface*, unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> > >(void (QtWebEngineCore::DisplayGLOutputSurface::*&&)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), QtWebEngineCore::DisplayGLOutputSurface*&&, unsigned int&&, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) at bind_internal.h:598 [opt]
          frame #3: 0x00000001025ec13b QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::RunOnce(base::internal::BindStateBase*, unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) [inlined] void base::internal::Invoker<base::internal::BindState<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::RunImpl<void (functor=<unavailable>, bound=<unavailable>, unbound_args=<unavailable>)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), std::__1::tuple<base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, 0ul>(void (QtWebEngineCore::DisplayGLOutputSurface::*&&)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), std::__1::tuple<base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >&&, std::__1::integer_sequence<unsigned long, 0ul>, unsigned int&&, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >&&) at bind_internal.h:672 [opt]
          frame #4: 0x00000001025ec133 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (QtWebEngineCore::DisplayGLOutputSurface::*)(unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >), base::internal::UnretainedWrapper<QtWebEngineCore::DisplayGLOutputSurface> >, void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::RunOnce(base=<unavailable>, unbound_args=<unavailable>, unbound_args=<unavailable>) at bind_internal.h:640 [opt]
          frame #5: 0x000000010256161d QtWebEngineCore`gpu::InProcessCommandBuffer::GetTextureQtOnGpuThread(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>) [inlined] base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>::Run(this=<unavailable>, args=28, args=nullptr) && at callback.h:98:12 [opt]
          frame #6: 0x0000000102561603 QtWebEngineCore`gpu::InProcessCommandBuffer::GetTextureQtOnGpuThread(this=<unavailable>, client_id=<unavailable>, callback=gpu::InProcessCommandBuffer::GetTextureCallback @ 0x000070000e3a2ac8)>) at display_overrides.cpp:84 [opt]
          frame #7: 0x00000001025616c4 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, void ()>::RunOnce(base::internal::BindStateBase*) [inlined] void base::internal::FunctorTraits<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), void>::Invoke<void (method=<unavailable>, receiver_ptr=<unavailable>, args=<unavailable>, args=0x00000001128ff8e8)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >(void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>&&, unsigned int&&, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>&&) at bind_internal.h:498:12 [opt]
          frame #8: 0x0000000102561681 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, void ()>::RunOnce(base::internal::BindStateBase*) [inlined] void base::internal::InvokeHelper<true, void>::MakeItSo<void (functor=<unavailable>, weak_ptr=<unavailable>, args=<unavailable>, args=0x00000001128ff8e8)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >(void (gpu::InProcessCommandBuffer::*&&)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>&&, unsigned int&&, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>&&) at bind_internal.h:618 [opt]
          frame #9: 0x0000000102561666 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, void ()>::RunOnce(base::internal::BindStateBase*) [inlined] void base::internal::Invoker<base::internal::BindState<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, void ()>::RunImpl<void (functor=<unavailable>, bound=<unavailable>)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), std::__1::tuple<base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, 0ul, 1ul, 2ul>(void (gpu::InProcessCommandBuffer::*&&)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), std::__1::tuple<base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >&&, std::__1::integer_sequence<unsigned long, 0ul, 1ul, 2ul>) at bind_internal.h:672 [opt]
          frame #10: 0x0000000102561666 QtWebEngineCore`base::internal::Invoker<base::internal::BindState<void (gpu::InProcessCommandBuffer::*)(unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)>), base::WeakPtr<gpu::InProcessCommandBuffer>, unsigned int, base::OnceCallback<void (unsigned int, std::__1::unique_ptr<gl::GLFence, std::__1::default_delete<gl::GLFence> >)> >, void ()>::RunOnce(base=<unavailable>) at bind_internal.h:640 [opt]
          frame #11: 0x0000000106aa1e72 QtWebEngineCore`::RunTaskOnGpuThread() [inlined] Run at callback.h:98:12 [opt]
          frame #12: 0x0000000106aa1e61 QtWebEngineCore`::RunTaskOnGpuThread() at in_process_command_buffer.cc:949 [opt]
          frame #13: 0x0000000106aa6f70 QtWebEngineCore`::RunOnce() [inlined] Invoke<void (gpu::InProcessCommandBuffer::*)(base::OnceCallback<void ()>), base::WeakPtr<gpu::InProcessCommandBuffer>, base::OnceCallback<void ()> > at bind_internal.h:498:12 [opt]
          frame #14: 0x0000000106aa6f31 QtWebEngineCore`::RunOnce() [inlined] MakeItSo<void (gpu::InProcessCommandBuffer::*)(base::OnceCallback<void ()>), base::WeakPtr<gpu::InProcessCommandBuffer>, base::OnceCallback<void ()> > at bind_internal.h:618 [opt]
          frame #15: 0x0000000106aa6f16 QtWebEngineCore`::RunOnce() [inlined] RunImpl<void (gpu::InProcessCommandBuffer::*)(base::OnceCallback<void ()>), std::__1::tuple<base::WeakPtr<gpu::InProcessCommandBuffer>, base::OnceCallback<void ()> >, 0, 1> at bind_internal.h:672 [opt]
          frame #16: 0x0000000106aa6f16 QtWebEngineCore`::RunOnce() at bind_internal.h:640 [opt]
          frame #17: 0x00000001062c888b QtWebEngineCore`::RunNextTask() [inlined] Run at callback.h:98:12 [opt]
          frame #18: 0x00000001062c8878 QtWebEngineCore`::RunNextTask() at scheduler.cc:552 [opt]
          frame #19: 0x0000000104b8b38f QtWebEngineCore`::RunTask() [inlined] Run at callback.h:98:12 [opt]
          frame #20: 0x0000000104b8b37e QtWebEngineCore`::RunTask() at task_annotator.cc:142 [opt]
          frame #21: 0x0000000104ba0916 QtWebEngineCore`::DoWorkImpl() at thread_controller_with_message_pump_impl.cc:365:23 [opt]
          frame #22: 0x0000000104ba0683 QtWebEngineCore`::DoSomeWork() at thread_controller_with_message_pump_impl.cc:219:7 [opt]
          frame #23: 0x0000000104b3adef QtWebEngineCore`::Run() at message_pump_default.cc:39:55 [opt]
          frame #24: 0x0000000104ba12af QtWebEngineCore at thread_controller_with_message_pump_impl.cc:463:12 [opt]
          frame #25: 0x0000000104ba1242 QtWebEngineCore at thread_controller_with_message_pump_impl.cc:0 [opt]
          frame #26: 0x0000000104b64b6f QtWebEngineCore`::Run() at run_loop.cc:156:14 [opt]
          frame #27: 0x0000000104bbe0dd QtWebEngineCore`::ThreadMain() at thread.cc:376:3 [opt]
          frame #28: 0x0000000104c054c7 QtWebEngineCore`::ThreadFunc() at platform_thread_posix.cc:81:13 [opt]
          frame #29: 0x00007fff6b335109 libsystem_pthread.dylib`_pthread_start + 148
          frame #30: 0x00007fff6b330b8b libsystem_pthread.dylib`thread_start + 15
       

      It looks like m_middleBuffer in display_gl_output_surface.cpp might be null / invalid at the point when it's accessed. Perhaps some sort of race condition in access between the rendering thread and the compositor thread?

      I've also attacked a backtrace on all other threads in the process when the crash occurred. Let me know if there's other information I can provide that would be helpful.

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              qt_webengine_team Qt WebEngine Team
              kevinushey Kevin Ushey
              Votes:
              2 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes