From: Rafael Antognolli Date: Tue, 13 Mar 2018 23:58:21 +0000 (-0700) Subject: intel/compiler: Check for unsupported register sizes. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=f89e735719a63d674f12a892341ce86e10d82d82;p=mesa.git intel/compiler: Check for unsupported register sizes. Make sure we don't emit 64 bit types if the hardware doesn't support them. Signed-off-by: Rafael Antognolli Suggested-by: Kenneth Graunke Reviewed-by: Matt Turner --- diff --git a/src/intel/compiler/brw_reg_type.c b/src/intel/compiler/brw_reg_type.c index 704d6c9e1d9..60240ba1513 100644 --- a/src/intel/compiler/brw_reg_type.c +++ b/src/intel/compiler/brw_reg_type.c @@ -204,6 +204,9 @@ brw_reg_type_to_hw_type(const struct gen_device_info *devinfo, table = gen4_hw_type; } + assert(devinfo->has_64bit_types || brw_reg_type_to_size(type) < 8 || + type == BRW_REGISTER_TYPE_NF); + if (file == BRW_IMMEDIATE_VALUE) { assert(table[type].imm_type != (enum hw_imm_type)INVALID); return table[type].imm_type;