i965/fs: Properly handle LOAD_PAYLOAD in fs_inst::regs_read
authorJason Ekstrand <jason.ekstrand@intel.com>
Tue, 30 Jun 2015 22:51:13 +0000 (15:51 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Tue, 30 Jun 2015 23:11:17 +0000 (16:11 -0700)
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
src/mesa/drivers/dri/i965/brw_fs.cpp

index d91ad0a06506dc641c54decc2efee6003d87ae1c..cae4e4263eaab585631231862be49cf8e920c98b 100644 (file)
@@ -733,6 +733,11 @@ fs_inst::regs_read(int arg) const
          components = 1;
       break;
 
+   case SHADER_OPCODE_LOAD_PAYLOAD:
+      if (arg < this->header_size)
+         return 1;
+      break;
+
    default:
       if (is_tex() && arg == 0 && src[0].file == GRF)
          return mlen;