intel/elk: Use REG_CLASS_COUNT

Fixes: d44462c08d ("intel/elk: Fork Gfx8- compiler by copying existing code")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30314>
(cherry picked from commit a3714b55f4)
This commit is contained in:
Matt Turner 2024-07-22 19:36:59 -04:00 committed by Eric Engestrom
parent e4bceffb5f
commit eff81bc9e5
3 changed files with 4 additions and 4 deletions

View file

@ -1444,7 +1444,7 @@
"description": "intel/elk: Use REG_CLASS_COUNT",
"nominated": true,
"nomination_type": 1,
"resolution": 0,
"resolution": 1,
"main_sha": null,
"because_sha": "d44462c08d8858a4ab2dc37b311cc69501adb0dc",
"notes": null

View file

@ -47,6 +47,8 @@ struct shader_info;
struct nir_shader_compiler_options;
typedef struct nir_shader nir_shader;
#define REG_CLASS_COUNT 20
struct elk_compiler {
const struct intel_device_info *devinfo;
@ -74,7 +76,7 @@ struct elk_compiler {
* Array of the ra classes for the unaligned contiguous register
* block sizes used, indexed by register size.
*/
struct ra_class *classes[16];
struct ra_class *classes[REG_CLASS_COUNT];
/**
* ra class for the aligned barycentrics we use for PLN, which doesn't

View file

@ -34,8 +34,6 @@
using namespace elk;
#define REG_CLASS_COUNT 20
static void
assign_reg(const struct intel_device_info *devinfo,
unsigned *reg_hw_locations, elk_fs_reg *reg)