radeonsi: remove unused VS_STATE_LS_OUT_PATCH_SIZE
authorMarek Olšák <marek.olsak@amd.com>
Mon, 20 Feb 2023 05:13:35 +0000 (00:13 -0500)
committerMarge Bot <emma+marge@anholt.net>
Fri, 24 Feb 2023 21:27:24 +0000 (21:27 +0000)
This became unused when we switched to nir_lower_hs_inputs_to_mem.

Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/21525>

src/gallium/drivers/radeonsi/si_shader.h
src/gallium/drivers/radeonsi/si_shader_internal.h
src/gallium/drivers/radeonsi/si_state_draw.cpp

index 9f06805..9178657 100644 (file)
@@ -259,8 +259,6 @@ enum
  * in the shader via vs_state_bits in LS/HS.
  */
 /* bit gap */
-#define VS_STATE_LS_OUT_PATCH_SIZE__SHIFT    11
-#define VS_STATE_LS_OUT_PATCH_SIZE__MASK     0x1fff
 #define VS_STATE_LS_OUT_VERTEX_SIZE__SHIFT   24
 #define VS_STATE_LS_OUT_VERTEX_SIZE__MASK    0xff
 
index 0f85c19..c7aab66 100644 (file)
@@ -63,8 +63,6 @@ struct si_shader_args {
     *            Expand to FP32 like this: ((0x70 | value) << 23);
     *            With 0x70 = 112, we get 2^(112 + value - 127) = 2^(value - 15)
     *            = 1/2^(15 - value) in FP32
-    *   [11:23] = stride between patches in DW = num_inputs * num_vertices * 4
-    *             max = 32*32*4 + 32*4
     *   [24:31] = stride between vertices in DW = num_inputs * 4
     *             max = 32*4
     */
index 5f72b7f..8204d9e 100644 (file)
@@ -782,7 +782,6 @@ static void si_emit_derived_tess_state(struct si_context *sctx)
    /* Compute userdata SGPRs. */
    assert(((input_vertex_size / 4) & ~0xff) == 0);
    assert(((output_vertex_size / 4) & ~0xff) == 0);
-   assert(((input_patch_size / 4) & ~0x1fff) == 0);
    assert(((output_patch_size / 4) & ~0x1fff) == 0);
    assert(((output_patch0_offset / 4) & ~0xffff) == 0);
    assert(((perpatch_output_offset / 4) & ~0xffff) == 0);
@@ -813,7 +812,6 @@ static void si_emit_derived_tess_state(struct si_context *sctx)
    }
 
    /* Set SI_SGPR_VS_STATE_BITS. */
-   SET_FIELD(sctx->current_vs_state, VS_STATE_LS_OUT_PATCH_SIZE, input_patch_size / 4);
    SET_FIELD(sctx->current_vs_state, VS_STATE_LS_OUT_VERTEX_SIZE, input_vertex_size / 4);
 
    /* We should be able to support in-shader LDS use with LLVM >= 9
@@ -1197,9 +1195,7 @@ static void si_emit_vs_state(struct si_context *sctx, unsigned index_size)
       vs_state |= ENCODE_FIELD(VS_STATE_INDEXED, 1);
 
    /* Copy all state bits from vs_state to gs_state except the LS bits. */
-   gs_state |= vs_state &
-               CLEAR_FIELD(VS_STATE_LS_OUT_PATCH_SIZE) &
-               CLEAR_FIELD(VS_STATE_LS_OUT_VERTEX_SIZE);
+   gs_state |= vs_state & CLEAR_FIELD(VS_STATE_LS_OUT_VERTEX_SIZE);
 
    if (vs_state != sctx->last_vs_state ||
        ((HAS_GS || NGG) && gs_state != sctx->last_gs_state)) {