Bug 32829

Summary: [RADEON:KMS:R300G] vertex shaders render incorrectly in some wine programs
Product: Mesa Reporter: Rubén Fernández <rubenf3000>
Component: Drivers/Gallium/r300Assignee: Default DRI bug account <dri-devel>
Status: RESOLVED WONTFIX QA Contact:
Severity: normal    
Priority: medium    
Version: git   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: Screenshot showing misrendering
Log of the misrendering with MESA_GLSL=dump and RADEON_DEBUG=vp
Correct rendering with GLSL disabled in wine
Log of the correct rendering with MESA_GLSL=dump and RADEON_DEBUG=vp
radeon_debugger_result.h
output from Tom's branch with RADEON_DEBUG=vp and MESA_GLS=dump
Log of the misrendering with RADEON_DEBUG=noopt,vp

Description Rubén Fernández 2011-01-04 13:01:55 UTC
The game "Doctor Who: The Adventure games" produces polygon artifacts when
using GLSL; turning off GLSL in wine makes the game render correctly; using
GLSL with software rendering / llvmpipe renders correctly as well.


Graphics Card: ATI Technologies Inc RV505 [Radeon X1550 64-bit]
CPU: Intel Core Duo 1.8 Ghz, 2.5 GB RAM
Linux kernel 2.6.36, libdrm 2.4.23
Latest Mesa git
Comment 1 Rubén Fernández 2011-01-04 13:02:53 UTC
Created attachment 41642 [details]
Screenshot showing misrendering

Some vertices are incorrectly translated
Comment 2 Rubén Fernández 2011-01-04 13:03:55 UTC
Created attachment 41643 [details]
Log of the misrendering with MESA_GLSL=dump and RADEON_DEBUG=vp
Comment 3 Rubén Fernández 2011-01-04 13:04:28 UTC
Created attachment 41644 [details]
Correct rendering with GLSL disabled in wine
Comment 4 Rubén Fernández 2011-01-04 13:05:06 UTC
Created attachment 41645 [details]
Log of the correct rendering with MESA_GLSL=dump and RADEON_DEBUG=vp
Comment 5 Tom Stellard 2011-01-06 23:44:27 UTC
Hi, Can you try with the debugger branch from git://anongit.freedesktop.org/~tstellar/mesa and post the output of RADEON_DEBUG=vp ? This branch will probably mis-render a bunch of stuff, but it produces more helpful output.  Also, If this branch causes a segfault, can you post a stack trace?
Comment 6 Rubén Fernández 2011-01-07 10:37:53 UTC
(In reply to comment #5)
> Hi, Can you try with the debugger branch from
> git://anongit.freedesktop.org/~tstellar/mesa and post the output of
> RADEON_DEBUG=vp ? This branch will probably mis-render a bunch of stuff, but it
> produces more helpful output.  Also, If this branch causes a segfault, can you
> post a stack trace?

I've tried, but it's missing the file "radeon_debugger_result.h"; please add it and I'll test with it as soon as I can.
Comment 7 Tom Stellard 2011-01-07 14:49:54 UTC
Created attachment 41761 [details]
radeon_debugger_result.h

Sorry, Add this file to src/mesa/drivers/dri/r300/compiler
Comment 8 Rubén Fernández 2011-01-07 16:18:30 UTC
(In reply to comment #7)
> Created an attachment (id=41761) [details]
> radeon_debugger_result.h
> 
> Sorry, Add this file to src/mesa/drivers/dri/r300/compiler

Done; it doesn't segfault, but aborts due to "cannot allocate memory" before even getting to the point where it renders the characters wrongly; it seems to compile the shaders anyway, so I'll give you the log.
Comment 9 Rubén Fernández 2011-01-07 16:19:29 UTC
Created attachment 41764 [details]
output from Tom's branch with RADEON_DEBUG=vp and MESA_GLS=dump
Comment 10 Tom Stellard 2011-01-07 21:36:51 UTC
Does running mesa master branch with RADEON_DEBUG=noopt fix the issue?  If so, can you post the output of RADEON_DEBUG=noopt,vp ?
Comment 11 Rubén Fernández 2011-01-08 05:52:10 UTC
(In reply to comment #10)
> Does running mesa master branch with RADEON_DEBUG=noopt fix the issue?  If so,
> can you post the output of RADEON_DEBUG=noopt,vp ?

It doesn't - the results are the same. Posting the output anyway, in case it helps.
Comment 12 Rubén Fernández 2011-01-08 05:53:16 UTC
Created attachment 41769 [details]
Log of the misrendering with RADEON_DEBUG=noopt,vp
Comment 13 Rubén Fernández 2011-04-04 22:28:05 UTC
Since I no longer have access to an r300 card, I can't test for this bug anymore; unless somebody else has such a card, and this same game, I guess it's better to mark it as "solved".

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.