summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/Makefile.sources
diff options
context:
space:
mode:
authorKenneth Graunke <[email protected]>2015-04-07 15:15:09 -0700
committerKenneth Graunke <[email protected]>2015-04-11 12:35:33 -0700
commit89c1feb78d010bc457f5d02be84c955eebf3549f (patch)
tree558425e1ff2c21b99d66ba218f143b6c2759540b /src/mesa/drivers/dri/i965/Makefile.sources
parentb3e286c4575bf6af343c1a03471fd876cdfb5c43 (diff)
i965: Create NIR during LinkShader() and ProgramStringNotify().
Previously, we translated into NIR and did all the optimizations and lowering as part of running fs_visitor. This meant that we did all of that work twice for fragment shaders - once for SIMD8, and again for SIMD16. We also had to redo it every time we hit a state based recompile. We now generate NIR once at link time. ARB programs don't have linking, so we instead generate it at ProgramStringNotify time. Mesa's fixed function vertex program handling doesn't bother to inform the driver about new programs at all (which is rather mean), so we generate NIR at the last minute, if it hasn't happened already. shader-db runs ~9.4% faster on my i7-5600U, with a release build. v2: Check NirOptions != NULL in ProgramStringNotify(). Don't bother using _mesa_program_enum_to_shader_stage as we already know it. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/mesa/drivers/dri/i965/Makefile.sources')
-rw-r--r--src/mesa/drivers/dri/i965/Makefile.sources1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/Makefile.sources b/src/mesa/drivers/dri/i965/Makefile.sources
index 498d5a7c013..6d4659f0920 100644
--- a/src/mesa/drivers/dri/i965/Makefile.sources
+++ b/src/mesa/drivers/dri/i965/Makefile.sources
@@ -77,6 +77,7 @@ i965_FILES = \
brw_misc_state.c \
brw_multisample_state.h \
brw_nir.h \
+ brw_nir.c \
brw_nir_analyze_boolean_resolves.c \
brw_object_purgeable.c \
brw_packed_float.c \