radeonsi: make the vertex shader key smaller
authorMarek Olšák <marek.olsak@amd.com>
Thu, 25 Sep 2014 14:47:55 +0000 (16:47 +0200)
committerMarek Olšák <marek.olsak@amd.com>
Sat, 4 Oct 2014 13:16:14 +0000 (15:16 +0200)
We only support 16 vertex attribs, not 32.

Reviewed-by: Michel Dänzer <michel.daenzer@amd.com>
src/gallium/drivers/radeonsi/si_shader.h

index d9a89e3fee7702ae467415761e467a7951e177fa..c0e5cf40534b120f7af17f5db0160010f14ca29f 100644 (file)
@@ -31,6 +31,7 @@
 
 #include <llvm-c/Core.h> /* LLVMModuleRef */
 #include "tgsi/tgsi_scan.h"
+#include "si_state.h"
 
 #define SI_SGPR_CONST          0
 #define SI_SGPR_SAMPLER                2
@@ -140,7 +141,7 @@ union si_shader_key {
                unsigned        alpha_to_one:1;
        } ps;
        struct {
-               unsigned        instance_divisors[PIPE_MAX_ATTRIBS];
+               unsigned        instance_divisors[SI_NUM_VERTEX_BUFFERS];
                /* The mask of "get_unique_index" bits, needed for ES,
                 * it describes how the ES->GS ring buffer is laid out. */
                uint64_t        gs_used_inputs;