[Mesa-dev] [PATCH 16/53] r600: add shader key entries for tcs and tes.

Marek Olšák maraeo at gmail.com
Mon Nov 30 03:20:34 PST 2015


On Mon, Nov 30, 2015 at 7:20 AM, Dave Airlie <airlied at gmail.com> wrote:
> From: Dave Airlie <airlied at redhat.com>
>
> with tessellation vs can now run on ls, and tes can
> run on vs or es, tcs runs on hs.
>
> Signed-off-by: Dave Airlie <airlied at redhat.com>
> ---
>  src/gallium/drivers/r600/r600_hw_context.c   |  4 ++++
>  src/gallium/drivers/r600/r600_pipe.h         |  4 ++++
>  src/gallium/drivers/r600/r600_shader.c       | 13 +++++++++++--
>  src/gallium/drivers/r600/r600_shader.h       | 20 ++++++++++++++++++++
>  src/gallium/drivers/r600/r600_state_common.c | 11 ++++++++++-
>  5 files changed, 49 insertions(+), 3 deletions(-)
>
> diff --git a/src/gallium/drivers/r600/r600_hw_context.c b/src/gallium/drivers/r600/r600_hw_context.c
> index 13b6918..b7845b5 100644
> --- a/src/gallium/drivers/r600/r600_hw_context.c
> +++ b/src/gallium/drivers/r600/r600_hw_context.c
> @@ -321,6 +321,10 @@ void r600_begin_new_cs(struct r600_context *ctx)
>                 r600_mark_atom_dirty(ctx, &ctx->hw_shader_stages[R600_HW_STAGE_GS].atom);
>                 r600_mark_atom_dirty(ctx, &ctx->gs_rings.atom);
>         }
> +       if (ctx->tes_shader) {
> +               r600_mark_atom_dirty(ctx, &ctx->hw_shader_stages[EG_HW_STAGE_HS].atom);
> +               r600_mark_atom_dirty(ctx, &ctx->hw_shader_stages[EG_HW_STAGE_LS].atom);
> +       }

If tes_shader is temporarily NULL, this will cause that HS+LS won't be
set. I think this should be done unconditionally.

Marek


More information about the mesa-dev mailing list