[Mesa-dev] [PATCH 03/17] i965/fs: Report the right value in fs_inst::regs_read() for PIXEL_X/Y

Jason Ekstrand jason at jlekstrand.net
Thu Jun 18 17:50:09 PDT 2015


---
 src/mesa/drivers/dri/i965/brw_fs.cpp | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/src/mesa/drivers/dri/i965/brw_fs.cpp b/src/mesa/drivers/dri/i965/brw_fs.cpp
index ce56657..4f98d63 100644
--- a/src/mesa/drivers/dri/i965/brw_fs.cpp
+++ b/src/mesa/drivers/dri/i965/brw_fs.cpp
@@ -769,6 +769,12 @@ fs_inst::regs_read(int arg) const
          return 1;
       break;
 
+   case FS_OPCODE_PIXEL_X:
+   case FS_OPCODE_PIXEL_Y:
+      if (arg == 0)
+         return 2;
+      break;
+
    default:
       if (is_tex() && arg == 0 && src[0].file == GRF)
          return mlen;
-- 
2.4.3



More information about the mesa-dev mailing list