diff options
author | Jason Ekstrand <[email protected]> | 2016-01-14 12:08:57 -0800 |
---|---|---|
committer | Jason Ekstrand <[email protected]> | 2016-01-15 16:44:02 -0800 |
commit | 0a6811207fbe18d49c7ab95f93ed01f75ffcdda0 (patch) | |
tree | 40327045e76abc3885a1c89b011424bec16136b2 | |
parent | 03f66dfb4b399f078fc1bc99be1f0937ce981def (diff) |
i965/vec4: Use UW type for multiply into accumulator on GEN8+
BDW adds the following restriction: "When multiplying DW x DW, the dst
cannot be accumulator."
Cc: "11.1,11.0" <[email protected]>
Reviewed-by: Matt Turner <[email protected]>
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp index 0ae723f07e9..4ee2ed47d40 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp @@ -1069,7 +1069,11 @@ vec4_visitor::nir_emit_alu(nir_alu_instr *instr) case nir_op_umul_high: { struct brw_reg acc = retype(brw_acc_reg(8), dst.type); - emit(MUL(acc, op[0], op[1])); + if (devinfo->gen >=8) + emit(MUL(acc, op[0], retype(op[1], BRW_REGISTER_TYPE_UW))); + else + emit(MUL(acc, op[0], op[1])); + emit(MACH(dst, op[0], op[1])); break; } |