<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - Iris driver fails ext_packed_depth_stencil-getteximage test"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=110305">110305</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>Iris driver fails ext_packed_depth_stencil-getteximage test
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Mesa
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>git
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>Other
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Drivers/Gallium/Iris
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>intel-3d-bugs@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>andrey.simiklit@gmail.com
          </td>
        </tr>

        <tr>
          <th>QA Contact</th>
          <td>intel-3d-bugs@lists.freedesktop.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>It fails on a FLOAT_32_UNSIGNED_INT_24_8_REV format
Stencil values which were recorded by a glTexImage2D are not
equal to the stencil values which were received by a glGetTexImage
<a href="https://gitlab.freedesktop.org/mesa/piglit/blob/master/tests/spec/ext_packed_depth_stencil/getteximage.c#L131">https://gitlab.freedesktop.org/mesa/piglit/blob/master/tests/spec/ext_packed_depth_stencil/getteximage.c#L131</a>

The result examples for a 8-bit stencil:
i965:
+--------------------+-----------+
|Expected pixel value|Pixel value|
+--------------------+-----------+
|     0x000000a3     | 0x000000a3|
|     0x000000a2     | 0x000000a2|
|     0x000000a1     | 0x000000a1|
|     0x000000a0     | 0x000000a0|
|     0x0000009f     | 0x0000009f|
|     0x0000009e     | 0x0000009e|
+--------------------+-----------+

iris:
+--------------------+-----------+
|Expected pixel value|Pixel value|
+--------------------+-----------+
|     0x000000a3     | 0x000055a3|
|     0x000000a2     | 0x000055a2|
|     0x000000a1     | 0x000000a1|
|     0x000000a0     | 0x000000a0|
|     0x0000009f     | 0x3ec2c29f|
|     0x0000009e     | 0x3ec6c69e|
+--------------------+-----------+

Note: gallium doesn't clean an unused space here (but I guess that it is an
expected behavior):
<a href="https://gitlab.freedesktop.org/mesa/mesa/blob/master/src/gallium/auxiliary/util/u_transfer_helper.c#L276-301">https://gitlab.freedesktop.org/mesa/mesa/blob/master/src/gallium/auxiliary/util/u_transfer_helper.c#L276-301</a>

Actually I guess that it is rather a piglit test issue because spec saying
about FLOAT_32_UNSIGNED_INT_24_8_REV the following:

+---------------+------------+---+
| 1st component |   Unused   |2nd|
+---------------+------------+---+
     32-bit        24-bit     8-bit

I actually guess that "unused" means that there is no guarantee that it
must be clean but I am not sure whether it enough for mesa or I should find
some more strict wording about it.

So possible piglit test fix is:
   -if (buf[i*2+1] != tex[i*2+1]) {
   +if ((buf[i*2+1] & 0xffu) != tex[i*2+1]) {</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
          <li>You are the QA Contact for the bug.</li>
      </ul>
    </body>
</html>