amd/common: Introduce ac_get_fs_input_vgpr_cnt.
authorTimur Kristóf <timur.kristof@gmail.com>
Wed, 25 Sep 2019 14:40:07 +0000 (16:40 +0200)
committerConnor Abbott <cwabbott0@gmail.com>
Thu, 26 Sep 2019 13:36:49 +0000 (13:36 +0000)
commita4fd8ba7e39f7571a2a08e3c602b4d08566f3a09
tree0627933725101a699845fe99c554d325d3cbc14e
parent83eebdb5078872fbf0ff67cac6b08823d6a1293c
amd/common: Introduce ac_get_fs_input_vgpr_cnt.

Add a function called ac_get_fs_input_vgpr_cnt which will return
the number of input VGPRs used by an AMD shader. Previously,
radv and radeonsi had the same code duplicated, but this commit also
allows them to share this code.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/amd/common/ac_shader_util.c
src/amd/common/ac_shader_util.h
src/amd/vulkan/radv_shader.c
src/gallium/drivers/radeonsi/si_shader.c