spirv: Use nir_imm_floatN_t for constants for GLSL450 builtins
authorNeil Roberts <nroberts@igalia.com>
Wed, 21 Mar 2018 19:34:38 +0000 (20:34 +0100)
committerNeil Roberts <nroberts@igalia.com>
Tue, 17 Apr 2018 18:58:03 +0000 (20:58 +0200)
commit696f4abcbc07b96724307823b9e807cd981da3b5
treefc02cacbb3dcc10402527c37c8bddbbc02f60e8c
parente7b2c125c3f3df43b032e398d900e2ac7f91398a
spirv: Use nir_imm_floatN_t for constants for GLSL450 builtins

There is an existing macro that is used to choose between either a
float or a double immediate constant based on the bit size of the
first operand to the builtin. This is now changed to use the new
nir_imm_floatN_t helper function to reduce the number of places that
make this decision.

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
src/compiler/spirv/vtn_glsl450.c