Bug 54808

Summary: [ivb GT2] [SNA] eog does not show image
Product: xorg Reporter: Michael Laß <bevan>
Component: Driver/intelAssignee: Chris Wilson <chris>
Status: RESOLVED FIXED QA Contact: Xorg Project Team <xorg-team>
Severity: normal    
Priority: medium    
Version: unspecified   
Hardware: x86-64 (AMD64)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:
Attachments:
Description Flags
Screenshot showing the problem
none
dmesg output when using SNA
none
dmesg output when using UXA
none
Xorg log when using SNA
none
Xorg log when using UXA none

Description Michael Laß 2012-09-12 10:01:26 UTC
Created attachment 67033 [details]
Screenshot showing the problem

When activating SNA on my system eog (a gnome image viewer) is not able to show a very lange image anymore. Instead the shown picture is mostly black. Only on top there is a small bright line (see attached screenshot).

When using UXA the image is shown correctly, so I assume a driver problem here.

I can always reproduce this problem using the following image:
http://marsrovers.jpl.nasa.gov/gallery/press/opportunity/20120705a/PIA15689_Greeley_Pan_wDeck_L257F.jpg
CAUTION: This image is very large (23096x7981, 129MB) - viewing it requires some RAM...

I'm using a fedora system with the following versions:
kernel: 3.5.3
xorg-x11-drv-intel: 2.20.7
xorg-server: 1.12.3

The machine is a Lenovo L430 notebook with an IvyBridge i5-3210M CPU.

Please tell me if I can give any other helpful information.
Comment 1 Michael Laß 2012-09-12 10:02:56 UTC
Created attachment 67034 [details]
dmesg output when using SNA
Comment 2 Michael Laß 2012-09-12 10:03:13 UTC
Created attachment 67035 [details]
dmesg output when using UXA
Comment 3 Michael Laß 2012-09-12 10:03:28 UTC
Created attachment 67036 [details]
Xorg log when using SNA
Comment 4 Michael Laß 2012-09-12 10:03:41 UTC
Created attachment 67037 [details]
Xorg log when using UXA
Comment 5 Chris Wilson 2012-09-12 10:33:39 UTC
Works fine here.
Comment 6 Chris Wilson 2012-09-12 10:50:32 UTC
One thing you can try is to compile the driver yourself, and then use --enable-debug=full and attach the (large) log file.
Comment 7 Chris Wilson 2012-09-12 13:06:28 UTC
Built a v3.5.3 and that seems to be key component to trigger the failure.
Comment 8 Chris Wilson 2012-09-12 14:03:09 UTC
This should explain why it became blank:

commit 0d17208a66a7e54d4106f8a4034d3a928e28bb62
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Wed Sep 12 14:04:50 2012 +0100

    sna: Avoid readback inplace if the target is unmappable
    
    We have to use the tiling indirect path, or else fail.
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=54808
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

And this should prevent it from taking that slow path in the first place:

commit e5f137807c318588f546960668345eef34159e26
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Wed Sep 12 14:11:43 2012 +0100

    sna: Avoid fallbacks to shadow pixels if FORCE_GPU is in effect
    
    References: https://bugs.freedesktop.org/show_bug.cgi?id=54808
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Comment 9 Michael Laß 2012-09-12 20:52:46 UTC
Wow, that was fast. I compiled the latest version from GIT (6069e78238ca57e3433d528680fe04766a1e5307) and unfortunately the problem still exists.

Configure flags were the following:
--enable-kms-only --disable-static --enable-dri --enable-xvmc --enable-sna --with-default-accel=uxa

Then I added --enable-debug=full and tried to reproduce the error. But instead of showing me a black window the whole X-server crashed. This happens reproducibly but only when drivers were compiled with the debug option. 

I will attach the (big) Xorg.log which includes the crash.
Comment 10 Michael Laß 2012-09-12 21:02:11 UTC
The log is way to big to attach it here so you can find it here:
http://bi-co.net/xorg-intel/Xorg.log
Comment 11 Chris Wilson 2012-09-13 08:02:25 UTC
Hmm, so you have an antique version of cairo as well. Let me see what happens if I install that...
Comment 12 Chris Wilson 2012-09-13 08:59:41 UTC
commit d87a56ed1789e0c5058b302bb930d7e952ff3e5e
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Thu Sep 13 09:57:30 2012 +0100

    sna: Teach sna_replace__xor() how to tile large uploads
    
    This path is hit using eog+cairo-1.10 and a large image, e.g.
    http://marsrovers.jpl.nasa.gov/gallery/press/opportunity/20120705a/PIA15689_
    
    Reported-by: Michael Laß <bevan@bi-co.net>
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=54808
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

And update cairo so that you don't hit this silly path!

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.