i965/fs: Split VGRFs after lowering pull constants
authorJason Ekstrand <jason.ekstrand@intel.com>
Wed, 19 Aug 2015 21:29:53 +0000 (14:29 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 27 Aug 2015 19:09:36 +0000 (12:09 -0700)
The split_virtual_grfs code doesn't properly rewrite reladdr so we need to
make sure that any uniform indirects are lowered away first.

This fixes the glsl-fs-uniform-indexed-by-swizzled-vec4.shader_test in piglit

Cc: "10.6" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_fs.cpp

index a575181a74a44adbd0c0e8ae3cd2ef11a1020900..81009a091284b993a8fcd02b1171ee65cdd9aafc 100644 (file)
@@ -4780,11 +4780,11 @@ fs_visitor::optimize()
     */
    bld = fs_builder(this, 64);
 
-   split_virtual_grfs();
-
    assign_constant_locations();
    demote_pull_constants();
 
+   split_virtual_grfs();
+
 #define OPT(pass, args...) ({                                           \
       pass_num++;                                                       \
       bool this_progress = pass(args);                                  \