On Tue, Jan 17, 2017 at 1:24 AM, Juan A. Suarez Romero <[email protected]> wrote:
> Commit 42011be1e disabled HiZ when sharing depth buffer externally, > which free HiZ buffer. > > But in emit_depth_packets() we use that buffer, which generates a crash > in > "piglit.spec.egl_khr_gl_image.egl_khr_gl_renderbuffer_image- > clear-shared-image > gl_depth_component24" test when running in Skylake. > > This commit avoids using HiZ when the buffer was free. > --- > src/mesa/drivers/dri/i965/gen8_depth_state.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/src/mesa/drivers/dri/i965/gen8_depth_state.c > b/src/mesa/drivers/dri/i965/gen8_depth_state.c > index 14689f400f..5a4af0661f 100644 > --- a/src/mesa/drivers/dri/i965/gen8_depth_state.c > +++ b/src/mesa/drivers/dri/i965/gen8_depth_state.c > @@ -441,7 +441,7 @@ gen8_hiz_exec(struct brw_context *brw, struct > intel_mipmap_tree *mt, > BRW_SURFACE_2D, > true, /* depth writes */ > NULL, false, /* no stencil for now */ > - true, /* hiz */ > + mt->hiz_buf != NULL, /* hiz */ > I think this check is too deep. gen8_hiz_exec (and intel_hiz_exec) should never get called if we don't have HiZ. Instead, there's some check higher up that's failing to detect that we don't have HiZ. --Jason > surface_width, > surface_height, > mt->logical_depth0, > -- > 2.11.0 > > _______________________________________________ > mesa-dev mailing list > [email protected] > https://lists.freedesktop.org/mailman/listinfo/mesa-dev >
_______________________________________________ mesa-dev mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-dev
