Bug 75253 - Unigine engine regression (GM 45)
Summary: Unigine engine regression (GM 45)
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: git
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Kenneth Graunke
QA Contact: Intel 3D Bugs Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-20 11:53 UTC by Md Imam Hossain
Modified: 2014-02-27 03:01 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Md Imam Hossain 2014-02-20 11:53:46 UTC
Unigine engine based applications failing to run in mesa master. They used to run fine before with environment variable:

export MESA_EXTENSION_OVERRIDE="GL_EXT_framebuffer_multisample"

Tested applications:

Unigine Tropics-1.3
Unigine-Heaven-3.0
OilRush-1.12

console output after crashing of each application:

Tropics: ../../../../../../../src/mesa/drivers/dri/i965/brw_vec4_generator.cpp:1043: void brw::vec4_generator::generate_vec4_instruction(brw::vec4_instruction*, brw_reg, brw_reg*): Assertion `brw->gen >= 6' failed.
Aborted (core dumped)


My guess, it is due to the same bug, https://bugs.freedesktop.org/show_bug.cgi?id=74911

The 74911 bug is resolved now fixing many applications but not unigine based games on GM 45.


System:

Ubuntu 13.10
Linux: 3.12.0-031200-generic
xf86-video-intel 2.99.905
X.Org X Server 1.14.5
Mesa master: Mesa 10.2.0-devel (git-57405605a8c320f9d6ea389afd43ce6f013330a5)
Intel GMA 4500MHD (device id: 2a42)
Comment 1 Kenneth Graunke 2014-02-23 23:53:12 UTC
That's really bad.  We shouldn't ever emit LRPs on Gen4-5...doing so will assert in a debug build, or GPU hang in release builds...

I bisected this down to:

8d37e9915a3b21b496269a39f677a80a6e02cb2c is the first bad commit
commit 8d37e9915a3b21b496269a39f677a80a6e02cb2c
Author: Jordan Justen <jordan.l.justen@intel.com>
Date:   Mon Nov 4 10:23:24 2013 -0800

    glsl: Optimize open-coded lrp into lrp.
    
    total instructions in shared programs: 1498191 -> 1487051 (-0.74%)
    instructions in affected programs:     669388 -> 658248 (-1.66%)
    GAINED:                                1
    LOST:                                  0
    
    Reviewed-by: Matt Turner <mattst88@gmail.com>
    Signed-off-by: Jordan Justen <jordan.l.justen@intel.com>

:040000 040000 23c11446b747e8a3d28c9f75f4d64489d8d5fa34 71ca8cf51fe2af6a95516a27599eb5f5d73c5925 M       src

(it was a bit tricky since I had to sort out the interim vectorizer breakage)

Will fix ASAP.
Comment 2 Kenneth Graunke 2014-02-24 04:03:54 UTC
I sent four patches to the mailing list, which fix that assertion, and get Unigine Tropics running for me on Crestline (the predecessor to GM45).

Series starts here:
http://lists.freedesktop.org/archives/mesa-dev/2014-February/054788.html
(patch 2 is the one that really fixes the bug).
Comment 3 Kenneth Graunke 2014-02-26 10:32:53 UTC
Fixed in master with:

commit 56879a7ac41b8c7513a97cc02921f76a2ec8407c
Author: Kenneth Graunke <kenneth@whitecape.org>
Date:   Sun Feb 23 16:29:46 2014 -0800

    i965/vec4: Handle ir_triop_lrp on Gen4-5 as well.

Needs to be cherry-picked back to 10.1 - I assume Ian will take care of that.
Comment 4 Md Imam Hossain 2014-02-27 03:01:15 UTC
fixed! thank you!


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.