summaryrefslogtreecommitdiffstats
path: root/src/broadcom
diff options
context:
space:
mode:
authorEric Anholt <[email protected]>2018-12-15 22:17:52 -0800
committerJason Ekstrand <[email protected]>2018-12-16 21:03:01 +0000
commit2977c777589e15ff632415ecfd3548f49f56b4d8 (patch)
tree0962d4c7f86ec95add72c71c80954d9e51ee83d1 /src/broadcom
parent91a0251dbcc4d190ef3936f1d009897b60880f4e (diff)
v3d: Use the original bit size when scalarizing uniform loads.
Prevents a regression in jekstrand's 1-bit series. Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/broadcom')
-rw-r--r--src/broadcom/compiler/v3d_nir_lower_io.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/broadcom/compiler/v3d_nir_lower_io.c b/src/broadcom/compiler/v3d_nir_lower_io.c
index 10bc25811a8..1c1665f5831 100644
--- a/src/broadcom/compiler/v3d_nir_lower_io.c
+++ b/src/broadcom/compiler/v3d_nir_lower_io.c
@@ -63,7 +63,8 @@ v3d_nir_lower_uniform(struct v3d_compile *c, nir_builder *b,
nir_intrinsic_instr *intr_comp =
nir_intrinsic_instr_create(c->s, intr->intrinsic);
intr_comp->num_components = 1;
- nir_ssa_dest_init(&intr_comp->instr, &intr_comp->dest, 1, 32, NULL);
+ nir_ssa_dest_init(&intr_comp->instr, &intr_comp->dest, 1,
+ intr->dest.ssa.bit_size, NULL);
/* Convert the uniform offset to bytes. If it happens
* to be a constant, constant-folding will clean up