[Mesa-dev] [PATCH 6/6] i965/miptree: Remove the width/height < 32768 restrictions

Jason Ekstrand jason at jlekstrand.net
Mon Oct 24 22:36:59 UTC 2016


Even though this patch series is from-scratch, Ben deserves most of the
credit for tracking this down.  He had a series some time ago to fix the
issue for the terrain tests but it never ended up landing for a variety of
reasons (many of which were stupid).  Ben, would you like me to credit you
somehow?  Maybe a Reported-by?

--Jason

On Mon, Oct 24, 2016 at 3:29 PM, Jason Ekstrand <jason at jlekstrand.net>
wrote:

> These restrictions existed because intel_miptree_blit couldn't handle
> surfaces bigger than 32k.  How that we're chopping blits up into chunks, it
> can handle any size we throw at it so we can get rid of this restriction.
> This improves the terrain tests in synmark by 25-30% on my Sky Lake gt3.
>
> Signed-off-by: Jason Ekstrand <jason at jlekstrand.net>
> ---
>  src/mesa/drivers/dri/i965/brw_tex_layout.c    | 3 +--
>  src/mesa/drivers/dri/i965/intel_mipmap_tree.c | 6 ------
>  2 files changed, 1 insertion(+), 8 deletions(-)
>
> diff --git a/src/mesa/drivers/dri/i965/brw_tex_layout.c
> b/src/mesa/drivers/dri/i965/brw_tex_layout.c
> index 4618bc0..768f8a8 100644
> --- a/src/mesa/drivers/dri/i965/brw_tex_layout.c
> +++ b/src/mesa/drivers/dri/i965/brw_tex_layout.c
> @@ -610,8 +610,7 @@ brw_miptree_choose_tiling(struct brw_context *brw,
>     if (minimum_pitch < 64)
>        return I915_TILING_NONE;
>
> -   if (ALIGN(minimum_pitch, 512) >= 32768 ||
> -       mt->total_width >= 32768 || mt->total_height >= 32768) {
> +   if (ALIGN(minimum_pitch, 512) >= 32768) {
>        perf_debug("%dx%d miptree too large to blit, falling back to
> untiled",
>                   mt->total_width, mt->total_height);
>        return I915_TILING_NONE;
> diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
> b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
> index 551df4d..551812a 100644
> --- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
> +++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
> @@ -2838,12 +2838,6 @@ static bool
>  can_blit_slice(struct intel_mipmap_tree *mt,
>                 unsigned int level, unsigned int slice)
>  {
> -   uint32_t image_x;
> -   uint32_t image_y;
> -   intel_miptree_get_image_offset(mt, level, slice, &image_x, &image_y);
> -   if (image_x >= 32768 || image_y >= 32768)
> -      return false;
> -
>     /* See intel_miptree_blit() for details on the 32k pitch limit. */
>     if (mt->pitch >= 32768)
>        return false;
> --
> 2.5.0.400.gff86faf
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20161024/16c26651/attachment-0001.html>


More information about the mesa-dev mailing list