summaryrefslogtreecommitdiffstats
path: root/src/compiler/nir
diff options
context:
space:
mode:
authorDaniel Schürmann <[email protected]>2018-04-13 15:05:24 +0200
committerBas Nieuwenhuizen <[email protected]>2018-04-14 00:52:22 +0200
commit54937d820d97f5459c2249b6c358428f18245985 (patch)
treec10a4798dda44a0a7fc86838131159287a2d98f0 /src/compiler/nir
parent4d802df3aac353970aae93699223fb15b24f8408 (diff)
nir: use ballot_bit_size when lowering ballot_bitfield_extract
Reviewed-by: Jason Ekstrand <[email protected]> Reviewed-by: Bas Nieuwenhuizen <[email protected]>
Diffstat (limited to 'src/compiler/nir')
-rw-r--r--src/compiler/nir/nir_lower_subgroups.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/compiler/nir/nir_lower_subgroups.c b/src/compiler/nir/nir_lower_subgroups.c
index 0d3c83b7951..e0e1063fc43 100644
--- a/src/compiler/nir/nir_lower_subgroups.c
+++ b/src/compiler/nir/nir_lower_subgroups.c
@@ -359,7 +359,7 @@ lower_subgroups_intrin(nir_builder *b, nir_intrinsic_instr *intrin,
assert(intrin->src[1].is_ssa);
return nir_i2b(b, nir_iand(b, nir_ushr(b, int_val,
intrin->src[1].ssa),
- nir_imm_int(b, 1)));
+ nir_imm_intN_t(b, 1, options->ballot_bit_size)));
case nir_intrinsic_ballot_bit_count_reduce:
return nir_bit_count(b, int_val);
case nir_intrinsic_ballot_find_lsb: