Bug 72690 - TearFree: Xorg SIGABRT caused by Chromium
Summary: TearFree: Xorg SIGABRT caused by Chromium
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: 7.7 (2012.06)
Hardware: x86-64 (AMD64) Linux (All)
: medium minor
Assignee: Chris Wilson
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-13 19:34 UTC by Pascal de Bruijn
Modified: 2013-12-16 13:16 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
valgrind log of Xorg (17.71 KB, text/plain)
2013-12-13 19:34 UTC, Pascal de Bruijn
no flags Details
Recurse, no shall you. (1.74 KB, patch)
2013-12-15 09:42 UTC, Chris Wilson
no flags Details | Splinter Review

Description Pascal de Bruijn 2013-12-13 19:34:42 UTC
Created attachment 90744 [details]
valgrind log of Xorg

When I have TearFree enabled using the intel driver from current git master (details below) and browse the Internet using Chromium (31) on Xubuntu Saucy, Xorg SIGABRTs. It seems it's most easily reproducable by visting Flickr using Chromium and going to the "all resolutions" page, for any particular image. I usually reproduce using Flickr/Explore/Recent Photos/pick an image/***/View all sizes.

When TearFree is disabled, it can't seem to reproduce the issue.

Asus Eee PC 1215P
Intel Atom N550
Intel NM10/ICH7
Graphics PCI IDs: 8086:a011/8086:0a12
SNA Initialized with Alviso (gen3) backend

Xubuntu Saucy 13.10 (x86-64)
Linux kernel 3.11.0-14 (based on kernel.org 3.11.7)

I use the intel driver built as a package from git master, on my own PPA (I do 
_not_ patch in Mir support):

https://launchpad.net/~pmjdebruijn/+archive/xserver-xorg-video-intel-testing

Currently reproducable with 2.99.906+git20131212.f350a136

With ickle's assistance I valgrinded X, with the resulting log (attached).
Comment 1 Chris Wilson 2013-12-13 22:23:06 UTC
If you have a valgrind log with the patch I suggested, that would be useful as well. Just to see if it had any success at all.
Comment 2 Chris Wilson 2013-12-15 09:42:47 UTC
Created attachment 90795 [details] [review]
Recurse, no shall you.
Comment 3 Chris Wilson 2013-12-15 09:43:22 UTC
Pascal, a variant on the previous approach to try and requeue the vblank events in the middle of the TearFree wait.
Comment 4 Pascal de Bruijn 2013-12-15 17:14:04 UTC
So with the previous patch you supplied me via IRC, I could still reproduce the issue.

Now with "Recurse, no shall you", it seems I can no longer reproduce the issue. But since it's a timing related issue, I'll keep using the patched driver for a couple of days, to see if I accidentally trigger the issue. I'll report back in a couple of days.

I did however have a situation where the screen went black, and switching to vt1 and switching back to Xorg "got me my screen back". Xorg didn't crash as far as I can tell (nothing in dmesg), and all my application were still as I "left" them. That said, I do recall experiencing something like this before applying this patch, so this may be another unrelated issue. Another user describes a similar thing in #71585.
Comment 5 Chris Wilson 2013-12-16 11:38:04 UTC
*fingers crossed*

commit c8e339edd31859820907115c8d618b0fec3ef227
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Sun Dec 15 09:39:54 2013 +0000

    sna: Avoid recursive out-of-order operations in the middle of TearFree
    
    During TearFree, if we have to wait for the shadow flip to complete, we
    run the event handler for the device. This can then cause us to evaluate
    pending completed vblank events, which may in turn then attempt to use
    the shadow bo and recurse into the TearFree handler. Try to prevent this
    and requeue the vblank event.
    
    Reported-by: Pascal de Bruijn <pmjdebruijn@pcode.nl>
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=72690
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Comment 6 Pascal de Bruijn 2013-12-16 13:16:35 UTC
So I just pushed a new git master build to my PPA, which includes your new commits (2.99.906+git20131216.9289e2c5), which I'll continue to test over the coming days.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.