[mesa,1/3] tgsi: Fix decl.Atomic and .Shared not propagating when parsing tgsi text

Submitted by Hans de Goede on March 10, 2016, 3:14 p.m.

Details

Message ID 1457622887-19328-2-git-send-email-hdegoede@redhat.com
State New
Headers show
Series "tgsi and nouveau global / local / opencl-input mem support" ( rev: 1 ) in Nouveau

Not browsing as part of any series.

Commit Message

Hans de Goede March 10, 2016, 3:14 p.m.
When support for decl.Atomic and .Shared was added, tgsi_build_declaration
was not updated to propagate these properly.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 src/gallium/auxiliary/tgsi/tgsi_build.c | 6 ++++++
 1 file changed, 6 insertions(+)

Patch hide | download patch | download mbox

diff --git a/src/gallium/auxiliary/tgsi/tgsi_build.c b/src/gallium/auxiliary/tgsi/tgsi_build.c
index cfe9b92..c420ae1 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_build.c
+++ b/src/gallium/auxiliary/tgsi/tgsi_build.c
@@ -127,6 +127,8 @@  tgsi_build_declaration(
    unsigned invariant,
    unsigned local,
    unsigned array,
+   unsigned atomic,
+   unsigned shared,
    struct tgsi_header *header )
 {
    struct tgsi_declaration declaration;
@@ -143,6 +145,8 @@  tgsi_build_declaration(
    declaration.Invariant = invariant;
    declaration.Local = local;
    declaration.Array = array;
+   declaration.Atomic = atomic;
+   declaration.Shared = shared;
    header_bodysize_grow( header );
 
    return declaration;
@@ -401,6 +405,8 @@  tgsi_build_full_declaration(
       full_decl->Declaration.Invariant,
       full_decl->Declaration.Local,
       full_decl->Declaration.Array,
+      full_decl->Declaration.Atomic,
+      full_decl->Declaration.Shared,
       header );
 
    if (maxsize <= size)

Comments

Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>

On Thu, Mar 10, 2016 at 10:14 AM, Hans de Goede <hdegoede@redhat.com> wrote:
> When support for decl.Atomic and .Shared was added, tgsi_build_declaration
> was not updated to propagate these properly.
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>  src/gallium/auxiliary/tgsi/tgsi_build.c | 6 ++++++
>  1 file changed, 6 insertions(+)
>
> diff --git a/src/gallium/auxiliary/tgsi/tgsi_build.c b/src/gallium/auxiliary/tgsi/tgsi_build.c
> index cfe9b92..c420ae1 100644
> --- a/src/gallium/auxiliary/tgsi/tgsi_build.c
> +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c
> @@ -127,6 +127,8 @@ tgsi_build_declaration(
>     unsigned invariant,
>     unsigned local,
>     unsigned array,
> +   unsigned atomic,
> +   unsigned shared,
>     struct tgsi_header *header )
>  {
>     struct tgsi_declaration declaration;
> @@ -143,6 +145,8 @@ tgsi_build_declaration(
>     declaration.Invariant = invariant;
>     declaration.Local = local;
>     declaration.Array = array;
> +   declaration.Atomic = atomic;
> +   declaration.Shared = shared;
>     header_bodysize_grow( header );
>
>     return declaration;
> @@ -401,6 +405,8 @@ tgsi_build_full_declaration(
>        full_decl->Declaration.Invariant,
>        full_decl->Declaration.Local,
>        full_decl->Declaration.Array,
> +      full_decl->Declaration.Atomic,
> +      full_decl->Declaration.Shared,
>        header );
>
>     if (maxsize <= size)
> --
> 2.7.2
>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>


On 03/10/2016 04:14 PM, Hans de Goede wrote:
> When support for decl.Atomic and .Shared was added, tgsi_build_declaration
> was not updated to propagate these properly.
>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
> ---
>   src/gallium/auxiliary/tgsi/tgsi_build.c | 6 ++++++
>   1 file changed, 6 insertions(+)
>
> diff --git a/src/gallium/auxiliary/tgsi/tgsi_build.c b/src/gallium/auxiliary/tgsi/tgsi_build.c
> index cfe9b92..c420ae1 100644
> --- a/src/gallium/auxiliary/tgsi/tgsi_build.c
> +++ b/src/gallium/auxiliary/tgsi/tgsi_build.c
> @@ -127,6 +127,8 @@ tgsi_build_declaration(
>      unsigned invariant,
>      unsigned local,
>      unsigned array,
> +   unsigned atomic,
> +   unsigned shared,
>      struct tgsi_header *header )
>   {
>      struct tgsi_declaration declaration;
> @@ -143,6 +145,8 @@ tgsi_build_declaration(
>      declaration.Invariant = invariant;
>      declaration.Local = local;
>      declaration.Array = array;
> +   declaration.Atomic = atomic;
> +   declaration.Shared = shared;
>      header_bodysize_grow( header );
>
>      return declaration;
> @@ -401,6 +405,8 @@ tgsi_build_full_declaration(
>         full_decl->Declaration.Invariant,
>         full_decl->Declaration.Local,
>         full_decl->Declaration.Array,
> +      full_decl->Declaration.Atomic,
> +      full_decl->Declaration.Shared,
>         header );
>
>      if (maxsize <= size)
>