On Mon, Feb 8, 2016 at 12:16 PM, Rob Clark <robdcl...@gmail.com> wrote:

> On Mon, Feb 8, 2016 at 3:13 PM, Jason Ekstrand <ja...@jlekstrand.net>
> wrote:
> >> +   if (info->index_map[NIR_INTRINSIC_BASE] ||
> >> +       info->index_map[NIR_INTRINSIC_WRMASK]) {
> >> +      fprintf(fp, " /*");
> >> +      if (info->index_map[NIR_INTRINSIC_BASE])
> >> +         fprintf(fp, " base=%d", nir_intrinsic_base(instr));
> >> +      if (info->index_map[NIR_INTRINSIC_WRMASK]) {
> >> +          unsigned wrmask = nir_intrinsic_write_mask(instr);
> >> +          fprintf(fp, " wrmask=");
> >> +          for (unsigned i = 0; i < 4; i++)
> >> +             if ((wrmask >> i) & 1)
> >> +                fprintf(fp, "%c", "xyzw"[i]);
> >> +      }
> >> +      fprintf(fp, " */");
> >> +   }
> >
> >
> > Can we use an enum -> name table to name all of them?  Right now, it
> looks
> > like it only names baes and writemask.
>
> Hmm.. sure.  I think writemask is really the only one needing special
> casing.  I guess all the others would just show as %d..
>

Sure.  That one makes sense as hex.  The others shouldn't matter.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to