OSDN Git Service

i965/fs: Do instruction pre-scheduling just before register allocation.
authorEric Anholt <eric@anholt.net>
Thu, 7 Nov 2013 01:43:25 +0000 (17:43 -0800)
committerEric Anholt <eric@anholt.net>
Tue, 12 Nov 2013 23:06:21 +0000 (15:06 -0800)
Long ago, the HW_REG usage in assign_curb/urb_setup() were scheduling
barriers, so we had to run scheduler before them in order for it to be
able to do basically anything.  Now that that's fixed, we can delay the
scheduling until we go to allocate (which will make the next change less
scary).

Cc: "10.0" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Matt Turner <mattst88@gmail.com>
src/mesa/drivers/dri/i965/brw_fs.cpp

index ee7b07d..afa82c9 100644 (file)
@@ -3281,13 +3281,13 @@ fs_visitor::run()
         progress = compute_to_mrf() || progress;
       } while (progress);
 
-      schedule_instructions(false);
-
       lower_uniform_pull_constant_loads();
 
       assign_curb_setup();
       assign_urb_setup();
 
+      schedule_instructions(false);
+
       if (0)
         assign_regs_trivial();
       else {