From 71692a5d0b11072d7aa0e615c5d426b77825058a Mon Sep 17 00:00:00 2001 From: Alyssa Rosenzweig Date: Sun, 7 Apr 2024 16:51:36 -0400 Subject: [PATCH] asahi: resize key Signed-off-by: Alyssa Rosenzweig Part-of: --- src/asahi/lib/agx_linker.h | 2 +- src/asahi/lib/agx_nir_prolog_epilog.c | 2 +- src/gallium/drivers/asahi/agx_state.h | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/asahi/lib/agx_linker.h b/src/asahi/lib/agx_linker.h index 3c737df506d..f2bba1d6373 100644 --- a/src/asahi/lib/agx_linker.h +++ b/src/asahi/lib/agx_linker.h @@ -54,7 +54,7 @@ struct agx_vs_prolog_key { struct agx_velem_key attribs[AGX_MAX_VBUFS]; /* Bit mask of attribute components to load */ - BITSET_DECLARE(component_mask, VERT_ATTRIB_MAX * 4); + BITSET_DECLARE(component_mask, AGX_MAX_ATTRIBS * 4); /* Whether running as a hardware vertex shader (versus compute) */ bool hw; diff --git a/src/asahi/lib/agx_nir_prolog_epilog.c b/src/asahi/lib/agx_nir_prolog_epilog.c index 2b1d84b0ad2..86a62cb5183 100644 --- a/src/asahi/lib/agx_nir_prolog_epilog.c +++ b/src/asahi/lib/agx_nir_prolog_epilog.c @@ -148,7 +148,7 @@ agx_nir_vs_prolog(nir_builder *b, const void *key_) unsigned i = 0; nir_def *vec = NULL; unsigned vec_idx = ~0; - BITSET_FOREACH_SET(i, key->component_mask, VERT_ATTRIB_MAX * 4) { + BITSET_FOREACH_SET(i, key->component_mask, AGX_MAX_ATTRIBS * 4) { unsigned a = i / 4; unsigned c = i % 4; diff --git a/src/gallium/drivers/asahi/agx_state.h b/src/gallium/drivers/asahi/agx_state.h index 2214602c2f7..af726d4c22f 100644 --- a/src/gallium/drivers/asahi/agx_state.h +++ b/src/gallium/drivers/asahi/agx_state.h @@ -235,7 +235,7 @@ struct agx_compiled_shader { /* For a vertex shader, the mask of vertex attributes read. Used to key the * prolog so the prolog doesn't write components not actually read. */ - BITSET_DECLARE(attrib_components_read, VERT_ATTRIB_MAX * 4); + BITSET_DECLARE(attrib_components_read, AGX_MAX_ATTRIBS * 4); struct agx_fs_epilog_link_info epilog_key;