diff options
author | Iago Toral Quiroga <[email protected]> | 2016-02-12 08:47:21 +0100 |
---|---|---|
committer | Samuel Iglesias Gonsálvez <[email protected]> | 2017-01-03 11:26:50 +0100 |
commit | a8318b120e53518ae4d933acd876b8dbd3871e0c (patch) | |
tree | e352424515ab804d027eb6f6cebee07565413b8a | |
parent | bb0e67d55dbd353e9c57b0709fa3e534f1aba05f (diff) |
i965/vec4: fix get_nir_dest() to use DF type for 64-bit destinations
v2: Make dst_reg_for_nir_reg() handle this for nir_register since we
want to have the correct type set before we call offset().
Reviewed-by: Matt Turner <[email protected]>
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_vec4_nir.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp index f69c14d9721..67b6b32cfde 100644 --- a/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp +++ b/src/mesa/drivers/dri/i965/brw_vec4_nir.cpp @@ -259,6 +259,8 @@ dst_reg_for_nir_reg(vec4_visitor *v, nir_register *nir_reg, dst_reg reg; reg = v->nir_locals[nir_reg->index]; + if (nir_reg->bit_size == 64) + reg.type = BRW_REGISTER_TYPE_DF; reg = offset(reg, 8, base_offset); if (indirect) { reg.reladdr = @@ -275,6 +277,8 @@ vec4_visitor::get_nir_dest(const nir_dest &dest) if (dest.is_ssa) { dst_reg dst = dst_reg(VGRF, alloc.allocate(DIV_ROUND_UP(dest.ssa.bit_size, 32))); + if (dest.ssa.bit_size == 64) + dst.type = BRW_REGISTER_TYPE_DF; nir_ssa_values[dest.ssa.index] = dst; return dst; } else { |