vc4: Mark VPM read setup as impacting VPM reads, not writes.
authorEric Anholt <eric@anholt.net>
Tue, 9 Dec 2014 22:20:54 +0000 (14:20 -0800)
committerEric Anholt <eric@anholt.net>
Wed, 10 Dec 2014 02:32:36 +0000 (18:32 -0800)
Fixes assertion failures if we adjust scheduling priorities to emphasize
VPM reads more.

src/gallium/drivers/vc4/vc4_qpu_schedule.c

index 6bba66ad8528f53de59d9e494981099a4e7606d8..4bb9b3a53170be42f84eccc871c6c4c6c812b06a 100644 (file)
@@ -260,10 +260,16 @@ process_waddr_deps(struct schedule_state *state, struct schedule_node *n,
                         break;
 
                 case QPU_W_VPM:
-                case QPU_W_VPMVCD_SETUP:
                         add_write_dep(state, &state->last_vpm, n);
                         break;
 
+                case QPU_W_VPMVCD_SETUP:
+                        if (is_a)
+                                add_write_dep(state, &state->last_vpm_read, n);
+                        else
+                                add_write_dep(state, &state->last_vpm, n);
+                        break;
+
                 case QPU_W_SFU_RECIP:
                 case QPU_W_SFU_RECIPSQRT:
                 case QPU_W_SFU_EXP: