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>
This commit is contained in:

committed by
Connor Abbott

parent
83eebdb507
commit
a4fd8ba7e3
@@ -28,6 +28,7 @@
|
||||
#include <stdint.h>
|
||||
|
||||
#include "amd_family.h"
|
||||
#include "ac_binary.h"
|
||||
#include "compiler/nir/nir.h"
|
||||
|
||||
enum ac_image_dim {
|
||||
@@ -63,4 +64,9 @@ enum ac_image_dim
|
||||
ac_get_image_dim(enum chip_class chip_class, enum glsl_sampler_dim sdim,
|
||||
bool is_array);
|
||||
|
||||
unsigned
|
||||
ac_get_fs_input_vgpr_cnt(const struct ac_shader_config *config,
|
||||
signed char *face_vgpr_index,
|
||||
signed char *ancillary_vgpr_index);
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user