Bug 23106 - mplayer -vo gl:yuv=6 segfaults r300_state.c:r300SetupTextures() (mesa-7.5)
Summary: mplayer -vo gl:yuv=6 segfaults r300_state.c:r300SetupTextures() (mesa-7.5)
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/r300 (show other bugs)
Version: 7.5
Hardware: x86 (IA32) Linux (All)
: medium major
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-08-03 04:54 UTC by Thierry Vignaud
Modified: 2010-09-01 15:55 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
GDB trace of mplayer -vo gl:yuv=6 (15.81 KB, text/plain)
2009-08-03 04:54 UTC, Thierry Vignaud
Details
GDB trace of mplayer -vo gl2:yuv=6 (nearly identical) (16.04 KB, text/plain)
2009-08-03 04:54 UTC, Thierry Vignaud
Details

Description Thierry Vignaud 2009-08-03 04:54:15 UTC
Created attachment 28296 [details]
GDB trace of mplayer -vo gl:yuv=6

Using mesa-7.5 on two r300 cards:
- one xpress200 (aka RS380) (IGP)
- one Radeon 9600 (RV350 AP) (PCIe)
I got mplayer segfaulting in r300_state.c:r300SetupTextures() when rendering though OpenGL.
I tested a lot of files. I tested both gl and gl2 mplayer drivers.
Aka I used the following commands:
mplayer -vo gl:yuv=6 foobar.avi
mplayer -vo gl2:yuv=6 foobar.avi

See attached log.
The interesting bits concerning the used shader are:

OPTION ARB_precision_hint_fastest;TEMP coord, coord2, cdelta, parmx, parmy, a, b, yuv;TEX yuv.r, fragment.texcoord[0], texture[0], 2D;TEX yuv.g, fragment.texcoord[1], texture[1], 2D;TEX yuv.b, fragment.texcoord[2], texture[2], 2D;TEX result.color, yuv, texture[3], 3D;END
[gl] Program statistics:
[gl]   instructions: 5/16384
[gl]   native instructions: 5/128
[gl]   temporaries: 8/256
[gl]   native temporaries: 8/32
[gl]   parameters: 0/64
[gl]   native parameters: 0/16
[gl]   attribs: 0/12
[gl]   native attribs: 0/11
[gl]   ALU instructions: 0/16384
[gl]   TEX instructions: 0/16384
[gl]   TEX indirections: 0/16384
[gl]   native ALU instructions: 0/64
[gl]   native TEX instructions: 0/64
[gl]   native TEX indirections: 0/4
Comment 1 Thierry Vignaud 2009-08-03 04:54:51 UTC
Created attachment 28297 [details]
GDB trace of mplayer -vo gl2:yuv=6 (nearly identical)
Comment 2 Thierry Vignaud 2009-08-03 04:57:24 UTC
To prevent some questions, I tested:
- 32bit mplayer on a 32bit host with a xpress200 (aka RS380) (IGP)
- 32bit mplayer on a 64bit host with a  one Radeon 9600 (RV350 AP) (PCIe)

The logs came from the later but the segfault is identical with a 32bit host.
This is why I selected ia32 and not x86_64 (though the error would probably be the same)
Comment 3 Thierry Vignaud 2009-08-12 06:50:25 UTC
Trying to get in touch with developers...
Comment 4 Thierry Vignaud 2009-10-05 07:41:15 UTC
whereas it still affected mesa 7.7 a couple weeks ago, today's snashot now looks "fixed" (aka no more segfault but black window instead).
Note mesa 7.5.2 still exhibit the exact same segfault.

Summary (tested today on RV350 AP [Radeon 9600]):
- 7.3: OK
- 7.5: BROKEN
- 7.5.2: BROKEN
- 7.6: OK
- 7.7: OK (as of 20091005)

Here's the diff between not working 7.5.2 and working 7.6:

@ -182,17 +182,34 @@
 OPTION ARB_precision_hint_fastest;TEMP coord, coord2, cdelta, parmx, parmy, a, b, yuv;TEX yuv.r, fragment.texcoord[0], texture[0], 2D;TEX yuv.g, fragment.texcoord[1], texture[1], 2D;TEX yuv.b, fragment.texcoord[2], texture[2], 2D;TEX result.color, yuv, texture[3], 3D;END
 [gl] Program statistics:
 [gl]   instructions: 5/16384
-[gl]   native instructions: 5/128
+[gl]   native instructions: 5/96
 [gl]   temporaries: 8/256
 [gl]   native temporaries: 8/32
 [gl]   parameters: 0/64
-[gl]   native parameters: 0/16
-[gl]   attribs: 0/12
-[gl]   native attribs: 0/11
+[gl]   native parameters: 0/32
+[gl]   attribs: 3/12
+[gl]   native attribs: 3/11
 [gl]   ALU instructions: 0/16384
-[gl]   TEX instructions: 0/16384
+[gl]   TEX instructions: 4/16384
 [gl]   TEX indirections: 0/16384
 [gl]   native ALU instructions: 0/64
-[gl]   native TEX instructions: 0/64
+[gl]   native TEX instructions: 4/32
 [gl]   native TEX indirections: 0/4
 [gl] Resize: 720x416

Note that the register total has changed...
Comment 5 Fabio Pedretti 2009-12-10 01:09:54 UTC
This could be a duplicate of bug #25505.
Comment 6 Thierry Vignaud 2010-09-01 15:55:39 UTC
I lost interest in mesa-7.5 branch and since upstream never cared about, let's close...


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.