Bug 107667 - [regression, bisected] 2.5% performance drop in Middle Earth: Shadow of Mordor
Summary: [regression, bisected] 2.5% performance drop in Middle Earth: Shadow of Mordor
Alias: None
Product: Mesa
Classification: Unclassified
Component: Other (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: mesa-dev
QA Contact: mesa-dev
Depends on:
Reported: 2018-08-23 21:35 UTC by Gregor Münch
Modified: 2019-05-07 02:50 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Note You need to log in before you can comment on or make changes to this bug.
Description Gregor Münch 2018-08-23 21:35:43 UTC
I see a small drop of performance with current git in Shadow of Mordor using R600_DEBUG=nir,sisched (faster option over stock).

Shadow of Mordor internal benchmark:
before: 74.7fps
after:  72.9fps
current git: 73.2fps
current git with patch reverted: 74.9fps

Above numbers are from the second run, where the shader cache is warm. The numbers of the first run with cold cache are a lot more random even though for some reason the fps is higher (usually between 75.2 and 76.3 fps). Thats even more strange as the game with cold cache has short hangs when explosions appear. 

There is also a random freeze during the benchmark run hard hanging my machine. I dont know if the bisected patch is the cause of that but it is happening a lot now with current git. In my testing I didnt encounter the problem before the patch. Still could be just noise. I still dont know how to reproduce. If anyone wants to see dmesg:

glxinfo -B:

  Vendor: X.Org (0x1002)
    Device: AMD Radeon HD 7900 Series (TAHITI, DRM 3.27.0, 4.18.0-2-amd-staging-drm-next-git, LLVM 8.0.0) (0x6798)
    Version: 18.2.0
    Accelerated: yes
    Video memory: 3072MB
    Unified memory: no
    Preferred profile: core (0x1)
    Max core profile version: 4.5
    Max compat profile version: 4.4
    Max GLES1 profile version: 1.1
    Max GLES[23] profile version: 3.1

git bisect bad:

dbd52585fa9fe79aabea3560cb3aaefffe544af9 is the first bad commit
commit dbd52585fa9fe79aabea3560cb3aaefffe544af9
Author: Eric Anholt <eric@anholt.net>
Date:   Wed Jun 20 13:26:52 2018 -0700

    st/nir: Disable varying packing when doing transform feedback.
    The varying packing would result in st_nir_assign_var_locations() picking
    new driver_locations, despite the pipe_stream_output already being set up
    for the old driver location.  This left the gallium driver with no way to
    work back to what varying was referenced by pipe_stream_output.
    Fixes these tests on V3D:
    Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>

:040000 040000 67b42f008c50da7b17a15816ba76aca99e395133 2ac10eeaa23aaacc3986d91b27eef4e58375a6a8 M	src
Comment 1 Timothy Arceri 2019-05-07 02:50:39 UTC
This is a correct bugfix. It's likely any gain in performance was due to not doing the correct thing.

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.