iris: don't create staging resources larger than half the aperture
authorKenneth Graunke <kenneth@whitecape.org>
Wed, 27 Apr 2022 08:15:00 +0000 (01:15 -0700)
committerMarge Bot <emma+marge@anholt.net>
Wed, 31 Aug 2022 01:43:08 +0000 (01:43 +0000)
commita3dba0811566aba9f42e6e5b3a8e8691f972f4b5
tree3d5c335cf7aa9d2f13c1a8e448f1cdde3951fcee
parentfcad737cbae384f1eca2a7c499e884a1e5e045cc
iris: don't create staging resources larger than half the aperture

This is a port of crocus's f1c1fcfd (crocus: don't create staging
resources > half aperture).

I chose to use the whole aperture here rather than 3/4 of it, mostly
to avoid adding another legacy field for aperture stuff.  It's close
enough to work.

Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/2104
Reviewed-by: Dave Airlie <airlied@redhat.com>
Tested-by: Mark Janes markjanes@swizzler.org
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18311>
src/gallium/drivers/iris/iris_resource.c