Acked-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
uint32_t index;
};
-#define SI_NUM_VGT_STAGES_KEY_BITS 2
+#define SI_NUM_VGT_STAGES_KEY_BITS 4
#define SI_NUM_VGT_STAGES_STATES (1 << SI_NUM_VGT_STAGES_KEY_BITS)
/* The VGT_SHADER_STAGES key used to index the table of precomputed values.
#ifdef PIPE_ARCH_LITTLE_ENDIAN
unsigned tess:1;
unsigned gs:1;
+ unsigned ngg:1; /* gfx10+ */
+ unsigned streamout:1; /* only used with NGG */
unsigned _pad:32 - SI_NUM_VGT_STAGES_KEY_BITS;
#else /* PIPE_ARCH_BIG_ENDIAN */
unsigned _pad:32 - SI_NUM_VGT_STAGES_KEY_BITS;
+ unsigned streamout:1;
+ unsigned ngg:1;
unsigned gs:1;
unsigned tess:1;
#endif
if (key.u.gs)
stages |= S_028B54_ES_EN(V_028B54_ES_STAGE_DS) |
S_028B54_GS_EN(1);
+ else if (key.u.ngg)
+ stages |= S_028B54_ES_EN(V_028B54_ES_STAGE_DS);
else
stages |= S_028B54_VS_EN(V_028B54_VS_STAGE_DS);
} else if (key.u.gs) {
stages |= S_028B54_ES_EN(V_028B54_ES_STAGE_REAL) |
S_028B54_GS_EN(1);
+ } else if (key.u.ngg) {
+ stages |= S_028B54_ES_EN(V_028B54_ES_STAGE_REAL);
}
- if (key.u.gs)
+ if (key.u.ngg) {
+ stages |= S_028B54_PRIMGEN_EN(1);
+ if (key.u.streamout)
+ stages |= S_028B54_NGG_WAVE_ID_EN(1);
+ } else if (key.u.gs)
stages |= S_028B54_VS_EN(V_028B54_VS_STAGE_COPY_SHADER);
if (screen->info.chip_class >= GFX9)