i965/gen8: Always use BRW_REGISTER_TYPE_UW for MUL on GEN8+
The imulExtended tests of the shader bitfield tests of the OpenGL ES 3.1 CTS, fail on gen8+, when BRW_REGISTER_TYPE_W is used for SHADER_OPECODE_MULH. Also, remove unused helper function: static inline bool type_is_signed(unsigned type) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=92595 Signed-off-by: Marta Lofstedt <marta.lofstedt@linux.intel.com> Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:

committed by
Marta Lofstedt

parent
0d4cd045c8
commit
97685ff10e
@@ -3439,8 +3439,7 @@ fs_visitor::lower_integer_multiplication()
|
||||
*/
|
||||
assert(mul->src[1].type == BRW_REGISTER_TYPE_D ||
|
||||
mul->src[1].type == BRW_REGISTER_TYPE_UD);
|
||||
mul->src[1].type = (type_is_signed(mul->src[1].type) ?
|
||||
BRW_REGISTER_TYPE_W : BRW_REGISTER_TYPE_UW);
|
||||
mul->src[1].type = BRW_REGISTER_TYPE_UW;
|
||||
mul->src[1].stride *= 2;
|
||||
|
||||
} else if (devinfo->gen == 7 && !devinfo->is_haswell &&
|
||||
|
@@ -287,33 +287,6 @@ type_sz(unsigned type)
|
||||
}
|
||||
}
|
||||
|
||||
static inline bool
|
||||
type_is_signed(unsigned type)
|
||||
{
|
||||
switch(type) {
|
||||
case BRW_REGISTER_TYPE_D:
|
||||
case BRW_REGISTER_TYPE_W:
|
||||
case BRW_REGISTER_TYPE_F:
|
||||
case BRW_REGISTER_TYPE_B:
|
||||
case BRW_REGISTER_TYPE_V:
|
||||
case BRW_REGISTER_TYPE_VF:
|
||||
case BRW_REGISTER_TYPE_DF:
|
||||
case BRW_REGISTER_TYPE_HF:
|
||||
case BRW_REGISTER_TYPE_Q:
|
||||
return true;
|
||||
|
||||
case BRW_REGISTER_TYPE_UD:
|
||||
case BRW_REGISTER_TYPE_UW:
|
||||
case BRW_REGISTER_TYPE_UB:
|
||||
case BRW_REGISTER_TYPE_UV:
|
||||
case BRW_REGISTER_TYPE_UQ:
|
||||
return false;
|
||||
|
||||
default:
|
||||
unreachable("not reached");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Construct a brw_reg.
|
||||
* \param file one of the BRW_x_REGISTER_FILE values
|
||||
|
Reference in New Issue
Block a user