Signed-off-by: Samuel Iglesias Gonsálvez <[email protected]>
---
 src/mesa/drivers/dri/i965/brw_fs.cpp | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp 
b/src/mesa/drivers/dri/i965/brw_fs.cpp
index 93ab84b5845..8f57069398a 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -1404,6 +1404,11 @@ fs_visitor::assign_curb_setup()
                constant_nr = 0;
             }
 
+            /* If constant_nr < 0, then it is not present in the push constant
+             * buffer.
+             */
+            assert(constant_nr >= 0);
+
            struct brw_reg brw_reg = brw_vec1_grf(payload.num_regs +
                                                  constant_nr / 8,
                                                  constant_nr % 8);
-- 
2.11.0

_______________________________________________
mesa-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to