i965/miptree: Remove the width/height < 32768 restrictions
authorJason Ekstrand <jason.ekstrand@intel.com>
Mon, 24 Oct 2016 22:02:41 +0000 (15:02 -0700)
committerJason Ekstrand <jason.ekstrand@intel.com>
Thu, 27 Oct 2016 21:44:59 +0000 (14:44 -0700)
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@jlekstrand.net>
Reported-by: Ben Widawsky <ben@bwidawsk.net>
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Anuj Phogat <anuj.phogat@gmail.com>
src/mesa/drivers/dri/i965/brw_tex_layout.c
src/mesa/drivers/dri/i965/intel_mipmap_tree.c

index 4618bc02fabb5c24fa5f33f6d02289b51366e925..768f8a8af18ac2119e501a23072349da778af31e 100644 (file)
@@ -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;
index da9a38a421fda23b1fa84f93130e0e5d64b0a3e7..94a8086c68d2aa7cb3f68017b5b23b97e3e46bbc 100644 (file)
@@ -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;