genxml: Fix decoder for groups with multiple fields.
authorKenneth Graunke <kenneth@whitecape.org>
Fri, 19 May 2017 22:25:21 +0000 (15:25 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Thu, 1 Jun 2017 18:49:45 +0000 (11:49 -0700)
commitd1b949282f6387e9dc4a9a43defc8aaa08749c0a
treed5734f491adfaa80a55d76cd0ae8638063e508ce
parentdf2d55ba57dec857e4fb36ba3d9ec86aa3a46cd5
genxml: Fix decoder for groups with multiple fields.

If you have something like:

    <group count="0" start="96" size="32">
      <field name="Entry_0" start="0" end="15" type="GATHER_CONSTANT_ENTRY"/>
      <field name="Entry_1" start="16" end="31" type="GATHER_CONSTANT_ENTRY"/>
    </group>

We would reset ctx->group_count to 0 after processing the first field,
so the second would not have a group count.

This is largely untested, as the only groups with multiple fields are
packets we don't emit in Mesa.  Found by inspection.

Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/intel/common/gen_decoder.c