Bug 104665

Summary: r600: computer shaders break Bioshock on barts (bisected)
Product: Mesa Reporter: Gert Wollny <gw.fossdev>
Component: Drivers/Gallium/r600Assignee: mesa-dev
Status: RESOLVED MOVED QA Contact: mesa-dev
Severity: normal    
Priority: medium CC: mirh
Version: git   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:

Description Gert Wollny 2018-01-16 21:44:36 UTC
With the commit enabling compute shaders for BARTS 

  91dd4e44c244d1abd18314995e129a47790d5604
    r600/cs: add compute support to caps

Bioshock inifinite starts to lock up at startup (after the intro videos). 

dmsg: 

    radeon 0000:01:00.0: ring 0 stalled for more than 10272msec
    radeon 0000:01:00.0: GPU lockup (current fence id 0x0000000000063ff9 
             last fence id 0x000000000006400c on ring 0)
    radeon 0000:01:00.0: failed to get a new IB (-35)
    [drm:radeon_cs_ioctl [radeon]] *ERROR* Failed to get ib !
    radeon 0000:01:00.0: failed to get a new IB (-35)
    [drm:radeon_cs_ioctl [radeon]] *ERROR* Failed to get ib !
    radeon 0000:01:00.0: Saved 599 dwords of commands on ring 0.

The program doesn't require compute shaders, but when they are available they are used, hence what ever causes the GPU lockup only gets hit when the caps are reported.
Comment 1 Gert Wollny 2018-01-18 09:49:02 UTC
A trace can be found at: 

https://www.dropbox.com/s/ctkq3b7l9wp05oy/bioshock.i386.trace.xz

Creating it had some warnings: 

    apitrace: warning: _gl_param_size: unknown GLenum 0x90DF
    [ more of the same ]
    apitrace: warning: _gl_param_size: unknown GLenum 0x90DF
    apitrace: warning: glMapBufferRange: MAP_COHERENT_BIT|MAP_WRITE_BIT unsupported <https://git.io/vV9kM>
    apitrace: warning: glMapBufferRange: MAP_COHERENT_BIT|MAP_WRITE_BIT unsupported <https://git.io/vV9kM>

And actually replaying the trace failed for me with: 

    error: context mismatch: expected OpenGL 1.0, but got OpenGL 4.1 core
Comment 2 Dave Airlie 2018-03-29 02:48:12 UTC
Do you have version overrides, and does it still happen as I got the game, and it doesn't seem to be killing my redwood.
Comment 3 Dave Airlie 2018-03-29 03:31:12 UTC
okay reproduced it with cayman needed a 32-bit build,

it dies in a compute shader invocation alright.
Comment 4 Gert Wollny 2018-04-02 08:55:37 UTC
Since the game needs OpenGL 4.1 I have 

  export MESA_GL_VERSION_OVERRIDE=4.1
Comment 5 Gert Wollny 2018-06-03 08:17:38 UTC
Can't reproduce it any more as of git-8841c2cda51d, but I don't know which commit actually fixed the bug.
Comment 6 GitLab Migration User 2019-09-18 19:24:52 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/623.

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.