Discussion:
[Bug 108600] New: Regression: Segfault on video playback with XScale
b***@freedesktop.org
2018-10-30 13:54:31 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Bug ID: 108600
Summary: Regression: Segfault on video playback with XScale
Product: xorg
Version: git
Hardware: Other
OS: All
Status: NEW
Severity: normal
Priority: medium
Component: Driver/AMDgpu
Assignee: xorg-driver-***@lists.x.org
Reporter: ***@gmail.com
QA Contact: xorg-***@lists.x.org

Created attachment 142275
--> https://bugs.freedesktop.org/attachment.cgi?id=142275&action=edit
Xrandr output
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-10-30 13:57:08 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #1 from Matthew Scheirer <***@gmail.com> ---
Created attachment 142276
--> https://bugs.freedesktop.org/attachment.cgi?id=142276&action=edit
Xorg Segfault Error
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-10-30 13:59:04 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #2 from Matthew Scheirer <***@gmail.com> ---
Ugh, wiped the summary box while submitting this, so heres the summary:

Found a regression in 18.1 from 18.0. I use xscale for multi monitor DPI
handling and video playback under 18.1 with scaling enabled crashes the server
regularly. Doesn't happen in 18.0, does still happen on trunk. Doesn't happen
without scaling enabled.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-10-30 14:02:17 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #3 from Matthew Scheirer <***@gmail.com> ---
Versions: Arch, Xorg-server 1.20.3, kernel 4.18.16. Like I said, no segfaults
on 18.0, 18.1+ segfaults in every video player I can find (HW accelerated or
not - happens in Firefox, VLC, MPV). Doesn't seem to crash without playing
video - I've had a desktop last several hours actively avoiding any video
playback.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-10-30 15:22:50 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Michel DÀnzer <***@daenzer.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
Attachment #142276|text/x-log |text/plain
mime type| |
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-10-30 17:45:48 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #4 from Michel DÀnzer <***@daenzer.net> ---
Please make sure debugging symbols are available for
/usr/lib/xorg/modules/drivers/amdgpu_drv.so and /usr/lib/Xorg, reproduce the
crash again and attach the full corresponding Xorg log file.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-01 23:31:34 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #5 from Matthew Scheirer <***@gmail.com> ---
Created attachment 142332
--> https://bugs.freedesktop.org/attachment.cgi?id=142332&action=edit
Xorg + drv with debug symbols

Heres a full log with debug symbols as requested. Doesn't seem to want to give
the name of whatever its calling into AMDGPU for though.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-02 10:59:05 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #6 from Michel DÀnzer <***@daenzer.net> ---
Thanks, but yeah I'm afraid that's still not very useful. Can you try, in order
of preference:

1. Get a backtrace with gdb. See
https://www.x.org/wiki/Development/Documentation/ServerDebugging/ for some
detailed information about that.

2. Make sure xserver is compiled with --enable-libunwind, and attach another
log file from that.

3. Provide the output of

addr2line -e /usr/lib/xorg/modules/drivers/amdgpu_drv.so
0x7f727ae89000+0xc8e1
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-02 20:11:13 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #7 from Matthew Scheirer <***@gmail.com> ---
Created attachment 142349
--> https://bugs.freedesktop.org/attachment.cgi?id=142349&action=edit
gdb of segfault

#1 Attached the GDB. Got a SIGPIPE that seems unrelated and didn't crash the
server but I kept it in case it was relevant. The segfault starts at line 108.
Would the <optimized out> stuff be useful if I rebuilt without optimizations?

#2 The meson build of X doesn't support libunwind and the PKGBUILD in the AUR
for X git is completely broken (and seems non-trivial to fix). I could try
updating the older 1.19 autotools based script if necessary.

#3 addr2line doesn't give any useful output n the debug trunk drv, just ??:0.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-05 18:05:40 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #8 from Michel DÀnzer <***@daenzer.net> ---
Does
https://gitlab.freedesktop.org/daenzer/xf86-video-amdgpu/commit/5d9dee908543c141641fe8b6178874f772179937
help by any chance?
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-06 11:16:19 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Michel DÀnzer <***@daenzer.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |***@gmail.com

--- Comment #9 from Michel DÀnzer <***@daenzer.net> ---
*** Bug 108459 has been marked as a duplicate of this bug. ***
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-06 22:50:58 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Matthew Scheirer <***@gmail.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED

--- Comment #10 from Matthew Scheirer <***@gmail.com> ---
(In reply to Michel DÀnzer from comment #8)
Post by b***@freedesktop.org
Does
https://gitlab.freedesktop.org/daenzer/xf86-video-amdgpu/commit/
5d9dee908543c141641fe8b6178874f772179937 help by any chance?
Built it last night and after a good four hours so far I haven't been able to
reproduce any crashes. Before I could pretty reliably kill the server rapidly
opening and closing applications while moving them between screens.

Going to mark as resolved and fixed. If it crashes again I'll produce some more
gdb logs and reopen. Thank you so much for the quick response!
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-06 23:02:23 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Matthew Scheirer <***@gmail.com> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|RESOLVED |REOPENED
Resolution|FIXED |---
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-06 23:05:24 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #11 from Matthew Scheirer <***@gmail.com> ---
Karma is really a fierce one. It did crash, same indexes into amdgpu. Took a
really long while this time it seems! I'll generate new, unoptimized gdb logs
against the latest gits of the server and ddx. Reopened.
[ 9275.266] (EE) 3: /usr/lib/xorg/modules/drivers/amdgpu_drv.so (0x7fa221cb8000+0xc4fb) [0x7fa221cc44fb]
[ 9275.266] (EE) 4: /usr/lib/xorg/modules/drivers/amdgpu_drv.so (0x7fa221cb8000+0xc8f0) [0x7fa221cc48f0]
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-07 08:51:55 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Michel DÀnzer <***@daenzer.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|REOPENED |NEW

--- Comment #12 from Michel DÀnzer <***@daenzer.net> ---
Thanks for testing, will need to look at the gdb backtrace with that patch
applied.

FYI, bug reports should only be resolved once a fix lands on the main Git
master branch.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-07 20:11:58 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #13 from Matthew Scheirer <***@gmail.com> ---
Created attachment 142401
--> https://bugs.freedesktop.org/attachment.cgi?id=142401&action=edit
second gdb log from crash

New gdb logs from revised ddx.

Optimized outs are there because I didn't realize makepkg options override
optimizations from envvars. Next run I'll set -Og in the build step.

I got another sigpipe first again, included for posterity, but this crash is
happening in amdgpu_drm_handle_event still.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-09 10:41:35 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #14 from Michel DÀnzer <***@daenzer.net> ---
Can you try this branch:

https://gitlab.freedesktop.org/daenzer/xf86-video-amdgpu/commits/amdgpu_drm_queue_alloc-is_flip

If it still happens with that, in addition to a new gdb backtrace, can you try
running Xorg in valgrind and attaching valgrind's output? Let me know if you
run into trouble with that.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-12 22:31:01 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

--- Comment #15 from Matthew Scheirer <***@gmail.com> ---
Been using the second patchset for 3 days now - 2 in a release build - and
worked from home over the weekend so I put in a good ~20 hours of uptime. Seems
to have worked, no segfaults.

If you still want a valgrind run / any more logs / info I can still run some
traces if you want any more data on this.

Otherwise I'll leave the bug open and you can close it when you merge the
branch. Thank you so much for all the hard work.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freedesktop.org
2018-11-16 15:54:37 UTC
Permalink
https://bugs.freedesktop.org/show_bug.cgi?id=108600

Michel DÀnzer <***@daenzer.net> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution|--- |FIXED

--- Comment #16 from Michel DÀnzer <***@daenzer.net> ---
Thanks for the report and testing, fixed in Git master:

commit 51ba6dddee40c3688d4c7b12eabeab516ed153b7
Author: Michel DÀnzer <***@amd.com>
Date: Fri Nov 9 11:00:04 2018 +0100

Move deferred vblank events to separate drm_vblank_deferred list
--
You are receiving this mail because:
You are the assignee for the bug.
Loading...