<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEEDINFO "
   title="NEEDINFO - [SNB] INTEL_DEBUG=nohiz is likely broken for depth/stencil buffers"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=109985#c14">Comment # 14</a>
              on <a class="bz_bug_link 
          bz_status_NEEDINFO "
   title="NEEDINFO - [SNB] INTEL_DEBUG=nohiz is likely broken for depth/stencil buffers"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=109985">bug 109985</a>
              from <span class="vcard"><a class="email" href="mailto:nanleychery@gmail.com" title="Nanley Chery <nanleychery@gmail.com>"> <span class="fn">Nanley Chery</span></a>
</span></b>
        <pre>(In reply to Nanley Chery from <a href="show_bug.cgi?id=109985#c13">comment #13</a>)
<span class="quote">> (In reply to asimiklit from <a href="show_bug.cgi?id=109985#c12">comment #12</a>)
> > (In reply to Nanley Chery from <a href="show_bug.cgi?id=109985#c0">comment #0</a>)
> > > For SNB, INTEL_DEBUG=nohiz seems to be broken in two places:
> > > 
> > > 1. In miptree_create() in intel_mipmap_tree.c. Trying to create a
> > > depth/stencil buffer will cause a depth miptree to be created without
> > > stencil.
> > 
> > As far as found this code disallows us to create combined depth/stencil on
> > SNB:
> >    mesa_format mt_fmt = format;
> >    if (!_mesa_is_format_color_format(format) && devinfo->gen >= 6) {
> >       /* Fix up the Z miptree format for how we're splitting out separate
> >        * stencil. Gen7 expects there to be no stencil bits in its depth
> > buffer.
> >        */
> >       mt_fmt = intel_depth_format_for_depthstencil_format(format);
> >    }
> > 
> >    Note: This code just replaces MESA_FORMAT_Z24_UNORM_S8_UINT by
> > MESA_FORMAT_Z24_UNORM_X8_UINT
> >          but in this case 'mt_surf_usage' does not return a
> > ISL_SURF_USAGE_STENCIL_BIT and that leads to
> >          an assertion: assert(src_surf->surf->usage &
> > ISL_SURF_USAGE_STENCIL_BIT); in a blorp_blit function.
> >          PS: Actually I didn't check if this assertion actually matter.
> > 
> > But just avoiding of this code doesn't make us happy too (
> > Because we fail a choosing of a surf tiling method and
> > "isl_surf_choose_tiling" always returns false.
> > 
> > Now I am investigates a SNB PRM for the valid combinations of tiling methods
> > with combined depth/stencil.
> > 
> > Any advices or suggestions are welcome :)
> > 

> The cause of this problem is that we have two non-equivalent conditions for
> selecting the main miptree format and creating a separate stencil miptree:
> The condition you mentioned above and the call to needs_separate_stencil().
> One solution is to refactor and reuse needs_separate_stencil() for the
> format selection.
> </span >

Sorry, I only addressed the problem with avoiding the format selection code.

The tiling issue you've pointed out is a bug in isl_gen6_filter_tiling(). For
depth-stencil buffers on SNB, we have a Y-tiled surface with the elements laid
out as described in the "3D Depth Buffer Surfaces" section of the PRM.</pre>
        </div>
      </p>


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

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