[Mesa-dev] [PATCH 27/31] FIXUP: nir/builder: Generate 1-bit booleans in nir_build_imm_bool
Jason Ekstrand
jason at jlekstrand.net
Mon Oct 22 22:13:58 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 eaba5cfe448..2f2fc49c448 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.1
More information about the mesa-dev
mailing list