intel/fs: Fix MOV_INDIRECT and BROADCAST of Q types on Gen11+

The immediate case is pretty uncommon to see but it can happen, in
theory.  BROADCAST is typically used to uniformize values and those are
usually 32-bit.  However, it does come up in some subgroup ops.

Fixes: 49c21802cb "intel/compiler: Split has_64bit_types into float/int"
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6211>
This commit is contained in:
Jason Ekstrand
2020-07-17 16:22:11 -05:00
parent 70cbddc4a7
commit cccb497d3c
2 changed files with 23 additions and 5 deletions
+9 -1
View File
@@ -468,7 +468,15 @@ fs_generator::generate_mov_indirect(fs_inst *inst,
reg.nr = imm_byte_offset / REG_SIZE;
reg.subnr = imm_byte_offset % REG_SIZE;
brw_MOV(p, dst, reg);
if (type_sz(reg.type) > 4 && !devinfo->has_64bit_float) {
brw_MOV(p, subscript(dst, BRW_REGISTER_TYPE_D, 0),
subscript(reg, BRW_REGISTER_TYPE_D, 0));
brw_set_default_swsb(p, tgl_swsb_null());
brw_MOV(p, subscript(dst, BRW_REGISTER_TYPE_D, 1),
subscript(reg, BRW_REGISTER_TYPE_D, 1));
} else {
brw_MOV(p, dst, reg);
}
} else {
/* Prior to Broadwell, there are only 8 address registers. */
assert(inst->exec_size <= 8 || devinfo->gen >= 8);