[Mesa-stable] [Mesa-dev] [PATCH] nvc0: fix the driver cb size when draw parameters are used
Ilia Mirkin
imirkin at alum.mit.edu
Mon Jul 11 19:54:01 UTC 2016
Reviewed-by: Ilia Mirkin <imirkin at alum.mit.edu>
A follow-up patch to replace all those 2048's with some #define would
be great :)
On Mon, Jul 11, 2016 at 3:26 PM, Samuel Pitoiset
<samuel.pitoiset at gmail.com> wrote:
> The size of the driver constant buffer for each stage should be 2048
> and not 512 because it has been increased recently for buffers/images.
> While we are at it, do the same change for indirect draws.
>
> This fixes all ARB_shader_draw_parameters tests on GM107.
>
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> Cc: 12.0 <mesa-stable at lists.freedesktop.org>
> ---
> src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> index 4e40ff5..94274bc 100644
> --- a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> @@ -835,7 +835,7 @@ nvc0_draw_indirect(struct nvc0_context *nvc0, const struct pipe_draw_info *info)
>
> /* Queue things up to let the macros write params to the driver constbuf */
> BEGIN_NVC0(push, NVC0_3D(CB_SIZE), 3);
> - PUSH_DATA (push, 512);
> + PUSH_DATA (push, 2048);
> PUSH_DATAh(push, screen->uniform_bo->offset + NVC0_CB_AUX_INFO(0));
> PUSH_DATA (push, screen->uniform_bo->offset + NVC0_CB_AUX_INFO(0));
> BEGIN_NVC0(push, NVC0_3D(CB_POS), 1);
> @@ -979,7 +979,7 @@ nvc0_draw_vbo(struct pipe_context *pipe, const struct pipe_draw_info *info)
> if (nvc0->vertprog->vp.need_draw_parameters) {
> PUSH_SPACE(push, 9);
> BEGIN_NVC0(push, NVC0_3D(CB_SIZE), 3);
> - PUSH_DATA (push, 512);
> + PUSH_DATA (push, 2048);
> PUSH_DATAh(push, screen->uniform_bo->offset + NVC0_CB_AUX_INFO(0));
> PUSH_DATA (push, screen->uniform_bo->offset + NVC0_CB_AUX_INFO(0));
> if (!info->indirect) {
> --
> 2.8.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-stable
mailing list