[Mesa-dev] [PATCH] intel/blorp: Work around Sandy Bridge occlusion query issue

Samuel Iglesias Gonsálvez siglesias at igalia.com
Tue Jun 13 07:08:17 UTC 2017


Reviewed-by: Samuel Iglesias Gonsálvez <siglesias at igalia.com>

On Thu, 2017-06-08 at 10:45 -0700, Jason Ekstrand wrote:
> ---
>  src/intel/blorp/blorp_clear.c | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/src/intel/blorp/blorp_clear.c
> b/src/intel/blorp/blorp_clear.c
> index 3d5c41c..efacadf 100644
> --- a/src/intel/blorp/blorp_clear.c
> +++ b/src/intel/blorp/blorp_clear.c
> @@ -479,6 +479,16 @@ blorp_clear_depth_stencil(struct blorp_batch
> *batch,
>     params.x1 = x1;
>     params.y1 = y1;
>  
> +   if (ISL_DEV_GEN(batch->blorp->isl_dev) == 6) {
> +      /* For some reason, Sandy Bridge gets occlusion queries wrong
> if we
> +       * don't have a shader.  In particular, it records samples
> even though
> +       * we disable statistics in 3DSTATE_WM.  Give it the usual
> clear shader
> +       * to work around the issue.
> +       */
> +      if (!blorp_params_get_clear_kernel(batch->blorp, &params,
> false))
> +         return;
> +   }
> +
>     while (num_layers > 0) {
>        params.num_layers = num_layers;
>  
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20170613/e07bd82b/attachment.sig>


More information about the mesa-dev mailing list