intel/fs: Properly stride NULL replacement regs in DCE

This fixes some validation errors generated by certain D->W conversions
but is likely not a full solution.  Calculating an actual register
stride is a far more complex problem in general and should probably be
handled by the brw_fs_generator.

Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
Jason Ekstrand
2019-07-13 12:06:00 -05:00
parent 28a808a11b
commit 68a4c796d5
@@ -96,7 +96,8 @@ fs_visitor::dead_code_eliminate()
if (!result_live &&
(can_omit_write(inst) || can_eliminate(inst, flag_live))) {
inst->dst = fs_reg(retype(brw_null_reg(), inst->dst.type));
inst->dst = fs_reg(spread(retype(brw_null_reg(), inst->dst.type),
inst->dst.stride));
progress = true;
}
}