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

Application with QWebEngineView started with QT_WIDGETS_RHI=1 crashes on exit in QQuickWidgetPrivate::initializeWithRhi() callback

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P3: Somewhat important P3: Somewhat important
    • None
    • 6.8.1
    • Qt RHI
    • None
    • Windows 11
    • Windows

      Our application creates QWebEngineView which causes window flickering since Qt 6.5

      Tried to use the advice from QTBUG-136743 and found that this intermittently crashes on application exit on Windows with both debug and release builds.
      If I will start with QT_WIDGETS_RHI=1 but won't instantiate a QWebEngineView it won't crash.

      Crashes on this line. It takes 5-10 attempts to reproduce the crash with a debug build and crashes almost every time with a release build.

      Stack trace
      00000078`05afd770 00007ff8`ec12955f KERNELBASE!UnhandledExceptionFilter+0x1f3
      00000078`05afd860 00007ff8`ec0e67e3 ntdll!strncpy+0x13cf
      00000078`05afd890 00007ff8`ec12650f ntdll!_C_specific_handler+0x93
      00000078`05afd900 00007ff8`ec034527 ntdll!_chkstk+0x9f
      00000078`05afd930 00007ff8`ec125e4e ntdll!RtlWow64GetCurrentCpuArea+0xc17
      00000078`05afe080 00007ff8`a90fd40c ntdll!KiUserExceptionDispatcher+0x2e
      00000078`05afee60 00007ff8`a910a9e1 Qt6QuickWidgetsd!`QQuickWidgetPrivate::initializeWithRhi'::`15'::<lambda_1>::operator()(class QRhi * rhi = 0x0000023d`efd56930)+0x1c [C:\Users\qt\work\qt\qtdeclarative\src\quickwidgets\qquickwidget.cpp @ 1045]
      00000078`05afee90 00007ff8`a90fd9d5 Qt6QuickWidgetsd!std::invoke<`QQuickWidgetPrivate::initializeWithRhi'::`15'::<lambda_1> &,QRhi *>(class QQuickWidgetPrivate::initializeWithRhi::__l15::<lambda_1> * _Obj = 0x0000023d`c9747d08, class QRhi ** _Arg1 = 0x00000078`05afef38)+0x21 [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\type_traits @ 1754]
      00000078`05afeec0 00007ff8`0940bf93 Qt6QuickWidgetsd!std::_Func_impl_no_alloc<`QQuickWidgetPrivate::initializeWithRhi'::`15'::<lambda_1>,void,QRhi *>::_Do_call(class QRhi ** <_Args_0> = 0x00000078`05afef38)+0x25 [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\functional @ 909]
      00000078`05afeef0 00007ff8`093f964c Qt6Guid!std::_Func_class<void,QRhi *>::operator()(class QRhi * <_Args_0> = 0x0000023d`efd56930)+0x53 [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\functional @ 952]
      00000078`05afef30 00007ff8`093f8d44 Qt6Guid!QRhi::runCleanup(void)+0x14c [C:\Users\qt\work\qt\qtbase\src\gui\rhi\qrhi.cpp @ 8917]
      00000078`05afeff0 00007ff8`0912a0b8 Qt6Guid!QRhi::~QRhi(void)+0x24 [C:\Users\qt\work\qt\qtbase\src\gui\rhi\qrhi.cpp @ 8491]
      00000078`05aff040 00007ff8`09125e6d Qt6Guid!QRhi::`scalar deleting destructor'(void)+0x18
      00000078`05aff070 00007ff8`09125d64 Qt6Guid!QBackingStoreRhiSupport::reset(void)+0xdd [C:\Users\qt\work\qt\qtbase\src\gui\painting\qbackingstorerhisupport.cpp @ 41]
      00000078`05aff140 00007ff8`09379338 Qt6Guid!QBackingStoreRhiSupport::~QBackingStoreRhiSupport(void)+0x14 [C:\Users\qt\work\qt\qtbase\src\gui\painting\qbackingstorerhisupport.cpp @ 24]
      00000078`05aff170 00007ff8`0937922b Qt6Guid!QPlatformBackingStorePrivate::SurfaceSupport::~SurfaceSupport(void)+0x28
      00000078`05aff1a0 00007ff8`093798f8 Qt6Guid!std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>::~pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>(void)+0x1b
      00000078`05aff1d0 00007ff8`0937791b Qt6Guid!std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>::`scalar deleting destructor'(void)+0x18
      00000078`05aff200 00007ff8`093771ed Qt6Guid!std::_Default_allocator_traits<std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > >::destroy<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> >(class std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > * __formal = 0x0000023d`84495c18, struct std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> * _Ptr = 0x0000023d`82fef9a0)+0x1b [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\xmemory @ 738]
      00000078`05aff230 00007ff8`0937713c Qt6Guid!std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *>::_Freenode<std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > >(class std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > * _Al = 0x0000023d`84495c18, struct std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> * _Ptr = 0x0000023d`82fef990)+0x2d [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\list @ 318]
      00000078`05aff260 00007ff8`0937ace0 Qt6Guid!std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *>::_Free_non_head<std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > >(class std::allocator<std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> > * _Al = 0x0000023d`84495c18, struct std::_List_node<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,void *> * _Head = 0x0000023d`82fefed0)+0x5c [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\list @ 330]
      00000078`05aff2a0 00007ff8`093791aa Qt6Guid!std::list<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> > >::_Tidy(void)+0x40 [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\list @ 1501]
      00000078`05aff2e0 00007ff8`0937900c Qt6Guid!std::list<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> > >::~list<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport>,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> > >(void)+0x2a [C:\Program Files\Microsoft Visual Studio\2022\Professional\VC\Tools\MSVC\14.39.33519\include\list @ 1047]
      00000078`05aff340 00007ff8`09379254 Qt6Guid!std::_Hash<std::_Umap_traits<enum QSurface::SurfaceType,QPlatformBackingStorePrivate::SurfaceSupport,std::_Uhash_compare<enum QSurface::SurfaceType,std::hash<enum QSurface::SurfaceType>,std::equal_to<enum QSurface::SurfaceType> >,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> >,0> >::~_Hash<std::_Umap_traits<enum QSurface::SurfaceType,QPlatformBackingStorePrivate::SurfaceSupport,std::_Uhash_compare<enum QSurface::SurfaceType,std::hash<enum QSurface::SurfaceType>,std::equal_to<enum QSurface::SurfaceType> >,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> >,0> >(void)+0x2c
      00000078`05aff370 00007ff8`093792bb Qt6Guid!std::unordered_map<enum QSurface::SurfaceType,QPlatformBackingStorePrivate::SurfaceSupport,std::hash<enum QSurface::SurfaceType>,std::equal_to<enum QSurface::SurfaceType>,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> > >::~unordered_map<enum QSurface::SurfaceType,QPlatformBackingStorePrivate::SurfaceSupport,std::hash<enum QSurface::SurfaceType>,std::equal_to<enum QSurface::SurfaceType>,std::allocator<std::pair<enum QSurface::SurfaceType const ,QPlatformBackingStorePrivate::SurfaceSupport> > >(void)+0x14
      00000078`05aff3a0 00007ff8`09379948 Qt6Guid!QPlatformBackingStorePrivate::~QPlatformBackingStorePrivate(void)+0x1b
      00000078`05aff3d0 00007ff8`09374dbe Qt6Guid!QPlatformBackingStorePrivate::`scalar deleting destructor'(void)+0x18
      00000078`05aff400 00007ff8`964d6bcd Qt6Guid!QPlatformBackingStore::~QPlatformBackingStore(void)+0x3e [C:\Users\qt\work\qt\qtbase\src\gui\painting\qplatformbackingstore.cpp @ 298]
      00000078`05aff440 00007ff8`964d9628 qwindowsd!QWindowsBackingStore::~QWindowsBackingStore(void)+0x11d [C:\Users\qt\work\qt\qtbase\src\plugins\platforms\windows\qwindowsbackingstore.cpp @ 34]
      00000078`05aff4f0 00007ff8`0910ab86 qwindowsd!QWindowsBackingStore::`scalar deleting destructor'(void)+0x18
      00000078`05aff520 00007ff8`229838c9 Qt6Guid!QBackingStore::~QBackingStore(void)+0x46 [C:\Users\qt\work\qt\qtbase\src\gui\painting\qbackingstore.cpp @ 96]
      00000078`05aff570 00007ff8`229a4988 Qt6Widgetsd!QBackingStore::`scalar deleting destructor'(void)+0x19
      00000078`05aff5a0 00007ff8`229ad378 Qt6Widgetsd!QWidgetWindow::~QWidgetWindow(void)+0xd8 [C:\Users\qt\work\qt\qtbase\src\widgets\kernel\qwidgetwindow.cpp @ 180]
      00000078`05aff5f0 00007ff8`2294f8c2 Qt6Widgetsd!QWidgetWindow::`scalar deleting destructor'(void)+0x18
      00000078`05aff620 00007ff8`2294b6b8 Qt6Widgetsd!QWidgetPrivate::deleteTLSysExtra(void)+0xd2 [C:\Users\qt\work\qt\qtbase\src\widgets\kernel\qwidget.cpp @ 1711]
      00000078`05aff670 00007ff8`2285df28 Qt6Widgetsd!QWidget::destroy(bool destroyWindow = true, bool destroySubWindows = true)+0x278 [C:\Users\qt\work\qt\qtbase\src\widgets\kernel\qwidget.cpp @ 12572]
      00000078`05aff720 00007ff8`243a8826 Qt6Widgetsd!QApplication::~QApplication(void)+0x178 [C:\Users\qt\work\qt\qtbase\src\widgets\kernel\qapplication.cpp @ 687]
      

      I don't have a simple example to demonstrate the issue yet.

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

            lagocs Laszlo Agocs
            nkrupenko.nvidia Nikita Krupenko
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes