https://bugs.winehq.org/show_bug.cgi?id=52005
Bug ID: 52005 Summary: wmvcore:wmvcore crashes in Wine on cw-gtx560 Product: Wine Version: unspecified Hardware: x86-64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: wmp&wmvcore Assignee: wine-bugs@winehq.org Reporter: fgouget@codeweavers.com Distribution: ---
wmvcore:wmvcore now crashes in Wine on cw-gtx560:
https://test.winehq.org/data/patterns.html#wmvcore:wmvcore
wmvcore.c:603: Test marked todo: Got hr 0x80004001. nouveau: kernel rejected pushbuf: No such device nouveau: ch4: krec 0 pushes 1 bufs 10 relocs 0 nouveau: ch4: buf 00000000 00000002 00000004 00000004 00000000 nouveau: ch4: buf 00000001 00000006 00000004 00000000 00000004 nouveau: ch4: buf 00000002 0000001e 00000004 00000004 00000000 nouveau: ch4: buf 00000003 00000020 00000002 00000000 00000002 nouveau: ch4: buf 00000004 00000021 00000004 00000004 00000000 nouveau: ch4: buf 00000005 0000001f 00000002 00000000 00000002 nouveau: ch4: buf 00000006 00000023 00000004 00000004 00000000 nouveau: ch4: buf 00000007 00000022 00000002 00000000 00000002 nouveau: ch4: buf 00000008 00000025 00000004 00000004 00000000 nouveau: ch4: buf 00000009 00000024 00000002 00000000 00000002 nouveau: ch4: psh 00000000 0000001f44 00000020a4 nouveau: 0x200140c5 nouveau: 0x00000100 nouveau: 0x20054088 nouveau: 0x00000030 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x00000001 nouveau: 0x00000000 nouveau: 0x200240c3 nouveau: 0x00000000 nouveau: 0x01a5c000 nouveau: 0x2002408e nouveau: 0x00000000 nouveau: 0x01a58000 nouveau: 0x200240d3 nouveau: 0x00000000 nouveau: 0x00000000 nouveau: 0x200240c7 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x200140c0 nouveau: 0x00100010 nouveau: 0x200140c5 nouveau: 0x00000100 nouveau: 0x20054088 nouveau: 0x00000030 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x00000001 nouveau: 0x00000000 nouveau: 0x200240c3 nouveau: 0x00000000 nouveau: 0x01a64000 nouveau: 0x2002408e nouveau: 0x00000000 nouveau: 0x01a60000 nouveau: 0x200240d3 nouveau: 0x00000000 nouveau: 0x00000000 nouveau: 0x200240c7 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x200140c0 nouveau: 0x00100010 nouveau: 0x200140c5 nouveau: 0x00000100 nouveau: 0x20054088 nouveau: 0x00000030 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x00000001 nouveau: 0x00000000 nouveau: 0x200240c3 nouveau: 0x00000000 nouveau: 0x01a6c000 nouveau: 0x2002408e nouveau: 0x00000000 nouveau: 0x01a68000 nouveau: 0x200240d3 nouveau: 0x00000000 nouveau: 0x00000000 nouveau: 0x200240c7 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x200140c0 nouveau: 0x00100010 nouveau: 0x200140c5 nouveau: 0x00000100 nouveau: 0x20054088 nouveau: 0x00000030 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x00000001 nouveau: 0x00000000 nouveau: 0x200240c3 nouveau: 0x00000000 nouveau: 0x01a74000 nouveau: 0x2002408e nouveau: 0x00000000 nouveau: 0x01a70000 nouveau: 0x200240d3 nouveau: 0x00000000 nouveau: 0x00000000 nouveau: 0x200240c7 nouveau: 0x00000100 nouveau: 0x00000040 nouveau: 0x200140c0 nouveau: 0x00100010 wmvcore: ../nouveau/pushbuf.c:723: nouveau_pushbuf_data: Assertion `kref' failed. 01b8:trace:seh:dispatch_exception code=80000101 flags=1 addr=F7F8E559 ip=f7f8e559 tid=01b8 01b8:warn:seh:dispatch_exception EXCEPTION_WINE_ASSERTION exception (code=80000101) raised
The crash is clearly related to the nouveau driver, probably because GStreamer uses hardware decoding. This explains why the crash only happens on cw-gtx560 since that's the TestBot's only NVidia machine.
Note also that the crash did not happen before the commit below:
commit 87e4c289e46701c6f582e95c330eefb6fc5ec68a Author: Zebediah Figura zfigura@codeweavers.com Date: Mon Oct 25 18:52:13 2021 -0500
winegstreamer: Implement IWMProfile::GetStreamCount().
Signed-off-by: Zebediah Figura zfigura@codeweavers.com Signed-off-by: Alexandre Julliard julliard@winehq.org
Unfortunately there is no backtrace but adding traces helps reconstruct a partial call stack:
In test_sync_reader_streaming(): tests/wmvcore.c:605: hr = IWMSyncReader_Close(reader); /* first call */ wm_syncreader.c:64: return wm_reader_close(&reader->reader); wm_reader.c:1508: wg_parser_disconnect(reader->wg_parser);
https://bugs.winehq.org/show_bug.cgi?id=52005
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |regression, source, | |testcase Regression SHA1| |87e4c289e46701c6f582e95c330 | |eefb6fc5ec68a
https://bugs.winehq.org/show_bug.cgi?id=52005
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |z.figura12@gmail.com
--- Comment #1 from Zebediah Figura z.figura12@gmail.com --- The problem with that theory is that the test file we're using is ASF + wmv1 + wmav1, and as far as I can tell there's no hardware decode support for that.
A log with GST_DEBUG=6 might help tell us what component is using Mesa. Surely it has to be *something* in GStreamer...
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #2 from Zebediah Figura z.figura12@gmail.com --- Ping. Is it possible to get a GST_DEBUG=6 log from the test machine?
https://bugs.winehq.org/show_bug.cgi?id=52005
Zebediah Figura z.figura12@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Version|unspecified |6.21
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #3 from François Gouget fgouget@codeweavers.com --- Created attachment 71370 --> https://bugs.winehq.org/attachment.cgi?id=71370 GST_DEBUG=6 wmvcore:wmvcore log
Sorry, I lost track of this bug. Here's the log.
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #4 from Zebediah Figura z.figura12@gmail.com --- Ah, okay. Basically, the test file is WMV1, which doesn't have hardware decode support, but VAAPI *does* support hardware decode of WMV3. GStreamer detects the type as "video/x-wmv" and tries to autoplug vaapidecodebin; the libva plugins enumerate available types, detect that WMV1 is none of them, and pass things on to the next decoder.
Except that with nouveau, kernel synchronization is bad enough that even asking for available formats (and creating test surfaces?) causes a GPU reset.
So obviously nouveau should be fixed, but in the meantime, probably the best thing to do is disable libva acceleration on the relevant machines. Probably the easiest way is to just uninstall gstreamer1.0-vaapi, if that doesn't work I'll have to look up other ways to blacklist vaapidecodebin.
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #5 from François Gouget fgouget@codeweavers.com --- (In reply to Zebediah Figura from comment #4) [...]
Except that with nouveau, kernel synchronization is bad enough that even asking for available formats (and creating test surfaces?) causes a GPU reset.
Do you know if there is already a Vaapi / Nouveau bug tracking this issue? It would be nice to have a pointer to it to be able to track progress on this. And if there is no such bug report it would be nice if you could create one.
So obviously nouveau should be fixed, but in the meantime, probably the best thing to do is disable libva acceleration on the relevant machines.
I have removed the gstreamer1.0-vaapi packages from the cw-gtx560 machine. This should be the only TestBot machine that's impacted. A quick test does show that the crash no longer happens. This should show up on tomorrow's WineTest results.
What are the impacts for Wine users? Is it correct to assume that the presence of the gstreamer1.0-vaapi package(s) would have also broken video playback in other applications like VLC or Firefox+YouTube; thus making it essentially unusable anyway? Or does it mean they have to choose between a working Wine and video acceleration in other applications?
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #6 from Zebediah Figura z.figura12@gmail.com --- (In reply to François Gouget from comment #5)
(In reply to Zebediah Figura from comment #4) [...]
Except that with nouveau, kernel synchronization is bad enough that even asking for available formats (and creating test surfaces?) causes a GPU reset.
Do you know if there is already a Vaapi / Nouveau bug tracking this issue? It would be nice to have a pointer to it to be able to track progress on this. And if there is no such bug report it would be nice if you could create one.
Unfortunately there seems to be no single bug report for "nouveau doesn't support multithreading". When I asked about it in #dri-devel https://gitlab.freedesktop.org/mesa/mesa/-/issues/3518 was suggested, but this is also only one of a slew of similar reports (just an unusually detailed one).
So obviously nouveau should be fixed, but in the meantime, probably the best thing to do is disable libva acceleration on the relevant machines.
I have removed the gstreamer1.0-vaapi packages from the cw-gtx560 machine. This should be the only TestBot machine that's impacted. A quick test does show that the crash no longer happens. This should show up on tomorrow's WineTest results.
What are the impacts for Wine users? Is it correct to assume that the presence of the gstreamer1.0-vaapi package(s) would have also broken video playback in other applications like VLC or Firefox+YouTube; thus making it essentially unusable anyway? Or does it mean they have to choose between a working Wine and video acceleration in other applications?
For platforms other than nouveau I assume it works just fine. For nouveau I have to assume it's broken in general (at least, there's probably nothing that Wine is doing differently than other GStreamer users in this respect).
https://bugs.winehq.org/show_bug.cgi?id=52005
--- Comment #7 from Zebediah Figura z.figura12@gmail.com --- Should this be closed now, then? Or do we want to retarget it to "wmvcore:wmvcore crashes when using vaapidecodebin on nouveau"? Either one seems reasonable to me.
https://bugs.winehq.org/show_bug.cgi?id=52005
François Gouget fgouget@codeweavers.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Resolution|--- |NOTOURBUG
--- Comment #8 from François Gouget fgouget@codeweavers.com --- The cw-gtx560 machine is gone and we don't have a Linux PCI passthrough replacement. This limits our ability to track this bug. Also since it very much looks like a bug in Nouveau it's not really our bug.
So let's close this bug.