Skip to content
Snippets Groups Projects
  1. Jul 14, 2021
  2. Jul 13, 2021
    • Timur Kristóf's avatar
      radv, aco, ac/nir: Tweak position export scheduling for NGG culling. · 8341af51
      Timur Kristóf authored
      
      The result is about +5-ish fps in Doom Eternal.
      
      It turns out that the location of position exports matters more
      than we thought, and it's actually better to keep them at the bottom
      for culling shaders rather than schedule it up to the top.
      
      Signed-off-by: default avatarTimur Kristóf <timur.kristof@gmail.com>
      Reviewed-by: default avatarDaniel Schürmann <daniel@schuermann.dev>
      Reviewed-by: default avatarSamuel Pitoiset <samuel.pitoiset@gmail.com>
      Part-of: <!10525>
      8341af51
    • Timur Kristóf's avatar
      ac/nir: Reuse uniforms from top part of culling shaders. · 0bb543bb
      Timur Kristóf authored
      
      Uniforms have the same value in all invocations, therefore they
      can safely be reused by invocations even after repacking.
      This saves several instructions from culling shaders, mainly
      UBO loads and such.
      
      We exclude uniform floats, because those would harm the VGPR
      usage of the shaders too much.
      
      Fossil DB results on Sienna Cichlid (with NGG culling on):
      
      Totals from 55379 (43.05% of 128647) affected shaders:
      VGPRs: 1926472 -> 1925360 (-0.06%); split: -0.07%, +0.01%
      SpillSGPRs: 139 -> 330 (+137.41%)
      CodeSize: 159472988 -> 157462856 (-1.26%); split: -1.27%, +0.00%
      MaxWaves: 1571492 -> 1571412 (-0.01%)
      Instrs: 30665685 -> 30302076 (-1.19%); split: -1.21%, +0.02%
      Latency: 127385148 -> 126723891 (-0.52%); split: -0.55%, +0.03%
      InvThroughput: 21096298 -> 20773069 (-1.53%); split: -1.53%, +0.00%
      VClause: 514792 -> 511231 (-0.69%); split: -0.83%, +0.13%
      SClause: 713959 -> 679556 (-4.82%); split: -4.84%, +0.02%
      Copies: 2975106 -> 2828185 (-4.94%); split: -5.39%, +0.45%
      Branches: 1201921 -> 1152766a (-4.09%)
      PreSGPRs: 1753786 -> 1892848 (+7.93%); split: -0.00%, +7.93%
      PreVGPRs: 1590522 -> 1583574 (-0.44%); split: -0.44%, +0.00%
      
      Signed-off-by: default avatarTimur Kristóf <timur.kristof@gmail.com>
      Reviewed-by: default avatarDaniel Schürmann <daniel@schuermann.dev>
      Part-of: <mesa/mesa!10525>
      0bb543bb
Loading