[Mesa-dev] [PATCH 14/24] i965/fs: Add (sub)reg_offset asserts to brw_reg_from_fs_reg.
Francisco Jerez
currojerez at riseup.net
Fri May 27 03:46:19 UTC 2016
These are completely ignored by the conversion to brw_reg, so they
better be zero.
---
src/mesa/drivers/dri/i965/brw_fs_generator.cpp | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
index 914ec9b..c3baa54 100644
--- a/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs_generator.cpp
@@ -56,6 +56,7 @@ brw_file_from_reg(fs_reg *reg)
static struct brw_reg
brw_reg_from_fs_reg(fs_inst *inst, fs_reg *reg, unsigned gen, bool compressed)
{
+ assert(reg->reg_offset == 0);
struct brw_reg brw_reg;
switch (reg->file) {
@@ -103,6 +104,7 @@ brw_reg_from_fs_reg(fs_inst *inst, fs_reg *reg, unsigned gen, bool compressed)
case ARF:
case FIXED_GRF:
case IMM:
+ assert(reg->subreg_offset == 0);
brw_reg = reg->as_brw_reg();
break;
case BAD_FILE:
--
2.7.3
More information about the mesa-dev
mailing list