[Mesa-dev] [PATCH 4/7] nvc0: be smarter when invalidating shader caches

Ilia Mirkin imirkin at alum.mit.edu
Tue Oct 25 19:57:06 UTC 2016


And bit 4 is for ... ?

I've only ever seen the blob use the value 0x1011. You're right that
it's a bitfield, but there's all kinds of crazy caches =/

On Tue, Oct 25, 2016 at 3:41 PM, Samuel Pitoiset
<samuel.pitoiset at gmail.com> wrote:
> MEM_BARRIER seems to be similar to FLUSH, thus bit 0 is for
> flushing code while bit 12 is for constant buffers.
>
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
>  src/gallium/drivers/nouveau/nvc0/nvc0_program.c | 2 +-
>  src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c     | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
> index a4a164f..68ce1c0 100644
> --- a/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
> +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_program.c
> @@ -859,7 +859,7 @@ nvc0_program_upload(struct nvc0_context *nvc0, struct nvc0_program *prog)
>  #endif
>
>     BEGIN_NVC0(nvc0->base.pushbuf, NVC0_3D(MEM_BARRIER), 1);
> -   PUSH_DATA (nvc0->base.pushbuf, 0x1011);
> +   PUSH_DATA (nvc0->base.pushbuf, 0x1);
>
>     return true;
>  }
> diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> index 11fd7eb..08dc568 100644
> --- a/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_vbo.c
> @@ -1004,7 +1004,7 @@ nvc0_draw_vbo(struct pipe_context *pipe, const struct pipe_draw_info *info)
>
>     if (nvc0->cb_dirty) {
>        PUSH_SPACE(push, 1);
> -      IMMED_NVC0(push, NVC0_3D(MEM_BARRIER), 0x1011);
> +      IMMED_NVC0(push, NVC0_3D(MEM_BARRIER), 0x1000);
>        nvc0->cb_dirty = false;
>     }
>
> --
> 2.10.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list