summaryrefslogtreecommitdiffstats
path: root/src/intel/compiler/meson.build
diff options
context:
space:
mode:
authorFrancisco Jerez <[email protected]>2017-06-15 15:23:57 -0700
committerFrancisco Jerez <[email protected]>2017-12-07 15:56:06 -0800
commitaf2c320190f3c73180f1610c8df955a7fa2a4d09 (patch)
treee98b17a77cf122c8cec1523be7b0b60daa1f4fc6 /src/intel/compiler/meson.build
parentc34b53f13326c89e09447d759ee188fe9c4964d8 (diff)
intel/fs: Implement GRF bank conflict mitigation pass.
Unnecessary GRF bank conflicts increase the issue time of ternary instructions (the overwhelmingly most common of which is MAD) by roughly 50%, leading to reduced ALU throughput. This pass attempts to minimize the number of bank conflicts by rearranging the layout of the GRF space post-register allocation. It's in general not possible to eliminate all of them without introducing extra copies, which are typically more expensive than the bank conflict itself. In a shader-db run on SKL this helps roughly 46k shaders: total conflicts in shared programs: 1008981 -> 600461 (-40.49%) conflicts in affected programs: 816222 -> 407702 (-50.05%) helped: 46234 HURT: 72 The running time of shader-db itself on SKL seems to be increased by roughly 2.52%±1.13% with n=20 due to the additional work done by the compiler back-end. On earlier generations the pass is somewhat less effective in relative terms because the hardware incurs a bank conflict anytime the last two sources of the instruction are duplicate (e.g. while trying to square a value using MAD), which is impossible to avoid without introducing copies. E.g. for a shader-db run on SNB: total conflicts in shared programs: 944636 -> 623185 (-34.03%) conflicts in affected programs: 853258 -> 531807 (-37.67%) helped: 31052 HURT: 19 And on BDW: total conflicts in shared programs: 1418393 -> 987539 (-30.38%) conflicts in affected programs: 1179787 -> 748933 (-36.52%) helped: 47592 HURT: 70 On SKL GT4e this improves performance of GpuTest Volplosion by 3.64% ±0.33% with n=16. NOTE: This patch intentionally disregards some i965 coding conventions for the sake of reviewability. This is addressed by the next squash patch which introduces an amount of (for the most part boring) boilerplate that might distract reviewers from the non-trivial algorithmic details of the pass. The following patch is squashed in: SQUASH: intel/fs/bank_conflicts: Roll back to the nineties. Acked-by: Matt Turner <[email protected]>
Diffstat (limited to 'src/intel/compiler/meson.build')
-rw-r--r--src/intel/compiler/meson.build1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/intel/compiler/meson.build b/src/intel/compiler/meson.build
index fe0a1f6e8ac..91127bf35a9 100644
--- a/src/intel/compiler/meson.build
+++ b/src/intel/compiler/meson.build
@@ -43,6 +43,7 @@ libintel_compiler_files = files(
'brw_eu.h',
'brw_eu_util.c',
'brw_eu_validate.c',
+ 'brw_fs_bank_conflicts.cpp',
'brw_fs_builder.h',
'brw_fs_cmod_propagation.cpp',
'brw_fs_combine_constants.cpp',