[Mesa-dev] [PATCH v2 27/29] FIXUP: nir/builder: Generate 1-bit Booleans in nir_build_imm_bool
Jason Ekstrand
jason at jlekstrand.net
Thu Dec 6 19:45:18 UTC 2018
---
src/compiler/nir/nir_builder.h | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/compiler/nir/nir_builder.h b/src/compiler/nir/nir_builder.h
index 08c5f1e8b6c..826e549019a 100644
--- a/src/compiler/nir/nir_builder.h
+++ b/src/compiler/nir/nir_builder.h
@@ -212,9 +212,9 @@ nir_imm_bool(nir_builder *build, bool x)
nir_const_value v;
memset(&v, 0, sizeof(v));
- v.u32[0] = x ? NIR_TRUE : NIR_FALSE;
+ v.b[0] = x;
- return nir_build_imm(build, 1, 32, v);
+ return nir_build_imm(build, 1, 1, v);
}
static inline nir_ssa_def *
--
2.19.2
More information about the mesa-dev
mailing list