nir/builder: Return an integer from nir_get_texture_size
authorJason Ekstrand <jason@jlekstrand.net>
Thu, 20 Feb 2020 23:19:50 +0000 (17:19 -0600)
committerMarge Bot <eric+marge@anholt.net>
Fri, 21 Feb 2020 18:48:03 +0000 (18:48 +0000)
commit1598370aca6459ba54915a26683a75bb66f88161
treeb3c13156f942d372bdbb1d55f5ee8a0e7c49b8c2
parent265e234e234f75cd5c209f76900009f81e2d6aec
nir/builder: Return an integer from nir_get_texture_size

It's convenient in a bunch of cases for nir_get_texture_size to return a
float but it's very unexpected.  This fixes a bug in the R600 NIR code.

Fixes: f718ac62688b "r600/sfn: Add a basic nir shader backend"
Reviewed-by: Eric Anholt <eric@anholt.net>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3897>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3897>
src/compiler/nir/nir_builtin_builder.c
src/compiler/nir/nir_lower_tex.c
src/gallium/drivers/r600/sfn/sfn_instruction_tex.cpp