<div dir="ltr"><div>Thanks! 1 and 2 are<br><br></div>Reviewed-by: Jason Ekstrand <<a href="mailto:jason@jlekstrand.net">jason@jlekstrand.net</a>><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Mar 21, 2018 at 12:34 PM, Neil Roberts <span dir="ltr"><<a href="mailto:nroberts@igalia.com" target="_blank">nroberts@igalia.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">There is an existing macro that is used to choose between either a<br>
float or a double immediate constant based on the bit size of the<br>
first operand to the builtin. This is now changed to use the new<br>
nir_imm_floatN_t helper function to reduce the number of places that<br>
make this decision.<br>
---<br>
src/compiler/spirv/vtn_<wbr>glsl450.c | 2 +-<br>
1 file changed, 1 insertion(+), 1 deletion(-)<br>
<br>
diff --git a/src/compiler/spirv/vtn_<wbr>glsl450.c b/src/compiler/spirv/vtn_<wbr>glsl450.c<br>
index 7d32914d516..50783fbfb4d 100644<br>
--- a/src/compiler/spirv/vtn_<wbr>glsl450.c<br>
+++ b/src/compiler/spirv/vtn_<wbr>glsl450.c<br>
@@ -513,7 +513,7 @@ vtn_nir_alu_op_for_spirv_glsl_<wbr>opcode(struct vtn_builder *b,<br>
}<br>
}<br>
<br>
-#define NIR_IMM_FP(n, v) (src[0]->bit_size == 64 ? nir_imm_double(n, v) : nir_imm_float(n, v))<br>
+#define NIR_IMM_FP(n, v) (nir_imm_floatN_t(n, v, src[0]->bit_size))<br>
<br>
static void<br>
handle_glsl450_alu(struct vtn_builder *b, enum GLSLstd450 entrypoint,<br>
<span class="HOEnZb"><font color="#888888">-- <br>
2.14.3<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div>