On 2 December 2013 11:36, Francisco Jerez <curroje...@riseup.net> wrote:
> --- > src/mesa/drivers/dri/i965/brw_reg.h | 21 +++++++++++++++++++++ > 1 file changed, 21 insertions(+) > > diff --git a/src/mesa/drivers/dri/i965/brw_reg.h > b/src/mesa/drivers/dri/i965/brw_reg.h > index 37a2ca9..2591cbf 100644 > --- a/src/mesa/drivers/dri/i965/brw_reg.h > +++ b/src/mesa/drivers/dri/i965/brw_reg.h > @@ -154,6 +154,27 @@ type_sz(unsigned type) > } > } > > +static inline bool > +type_is_signed(unsigned type) > +{ > + switch(type) { > + case BRW_REGISTER_TYPE_D: > + case BRW_REGISTER_TYPE_F: > + case BRW_REGISTER_TYPE_HF: > + case BRW_REGISTER_TYPE_W: > + case BRW_REGISTER_TYPE_B: > + return true; > + > + case BRW_REGISTER_TYPE_UD: > + case BRW_REGISTER_TYPE_UW: > + case BRW_REGISTER_TYPE_UB: > + return false; > + > + default: > + unreachable(); > + } > +} > + > If the call to unreachable() is replaced with an assertion (as we've discussed elsewhere on the list), this patch is: Reviewed-by: Paul Berry <stereotype...@gmail.com>
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev