diff --git a/src/intel/compiler/brw/brw_opt.cpp b/src/intel/compiler/brw/brw_opt.cpp index 22721be7e85..9ce3a6a8cf0 100644 --- a/src/intel/compiler/brw/brw_opt.cpp +++ b/src/intel/compiler/brw/brw_opt.cpp @@ -262,7 +262,7 @@ brw_opt_zero_samples(brw_shader &s) foreach_block_and_inst(block, brw_inst, inst, s.cfg) { brw_tex_inst *tex = inst->as_tex(); - if (tex == NULL) + if (tex == NULL || tex->required_params == 0) continue; int last_req_param = util_last_bit(tex->required_params) - 1;